Hi Tim, thanks to use our "How-to" documentation and give us your feedback.
We identified that some things described in the documentation are a bit outdated compared to our new generator. We have changed the documentation because of your valuable feedback and we'll publish these changes soon. In the meantime, you can use these changes to finish the how-to:
Item 3.3
- Step 5
Add ReactNode to the "react" imports
import { Component, ReactNode, createElement } from "react";
- Step 6
Replace
declare function require(name: string): string;
// tslint:disable-next-line class-name
export class preview extends Component<TextBoxWebModelerProps> {
render(): JSX.Element {
return <TextInput value={this.props.textAttribute} />;
}
}
with
import { TextInput } from "./components/TextInput";
declare function require(name: string): string;
// eslint-disable-next-line @typescript-eslint/class-name-casing
export class preview extends Component<TextBoxPreviewProps> {
render(): JSX.Element {
return <TextInput value={this.props.textAttribute} />;
}
}
Item 3.5
Step 1:
Add
<systemProperty key="Label" />
inside <propertyGroup>
**Important, if your IDE is complaining about classNames, just replace this import:
import * as classNames from "classNames";
with
import classNames from "classNames";