Avoid setState in componentDidMount
Synchronous state updates during mount trigger an extra render before the browser paints the initial tree.
#Metadata
#Why it matters
Initial state belongs in the constructor or class field initializers so the first render already reflects the mounted view.
#Remediation
Move the initial value into state initialization or derive it from props with a guarded update strategy.
#Repository path
The generated metadata points to critiq-rules/libs/rules/catalog/rules/typescript/ts.react.no-set-state-in-component-did-mount.rule.yaml.