feat: Better example app #795
lint-typescript.yml
on: pull_request
Compile TypeScript (tsc)
22s
Lint TypeScript (eslint, prettier)
41s
Annotations
2 warnings
Lint TypeScript (eslint, prettier):
example/src/App.tsx#L26
Do not define components during render. React will see a new component type on every render and destroy the entire subtree’s DOM nodes and state (https://reactjs.org/docs/reconciliation.html#elements-of-different-types). Instead, move this component definition out of the parent component “App” and pass data as props. If you want to allow component creation in props, set allowAsProps option to true.
|
Lint TypeScript (eslint, prettier):
example/src/App.tsx#L27
Inline style: { width: 40, height: 40, backgroundColor: 'red' }
|