Transformed a small subset of samples to functional components#1056
Draft
Transformed a small subset of samples to functional components#1056
Conversation
…ples + README Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/9067d825-3ea4-4e58-aa6d-cf16c15d0b5c Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…s 8-12) Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/a777979d-98e9-46cf-adc5-3df39b356ec9 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
… high-frequency chart Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/a777979d-98e9-46cf-adc5-3df39b356ec9 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…t reference Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/df3771c8-f6ca-47e7-a6ec-b1428ba0242f Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…ration Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/5ed51bd4-5435-4755-b3f0-09ea0d6397d0 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…op redundant onChartRef callback Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/56ffbced-7d25-4fde-8bb7-07304c135c93 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…eInput} Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/180e7a5d-be86-4e70-8bef-b8de2f3d7af8 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
…ad of useEffect Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/79511d0c-da8c-43dc-82e0-9b9e6d592903 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
Copilot created this pull request from a session on behalf of
gedinakova
April 14, 2026 14:25
View session
gedinakova
reviewed
Apr 15, 2026
| // useMemo creates these once – equivalent to the lazy backing-field getters in the class | ||
| const energyGlobalDemand = useMemo(() => new EnergyGlobalDemand(), []); | ||
|
|
||
| const renderer = useMemo(() => { |
Contributor
There was a problem hiding this comment.
This renderer is not used anywhere. Check if it's an omission or it should be deleted. @copilot
Contributor
Author
There was a problem hiding this comment.
The renderer was unused (not referenced in JSX or anywhere else in the component), so it was deleted along with the now-dead imports (ComponentRenderer, PropertyEditorPanelDescriptionModule, DataPieChartDescriptionModule, ItemLegendDescriptionModule) and the unused useRef import. Fixed in 9e9a075.
…tLegendFunctional Agent-Logs-Url: https://github.com/IgniteUI/igniteui-react-examples/sessions/b356e70c-f4f0-461e-82f4-8b63fdcb6254 Co-authored-by: gedinakova <16817847+gedinakova@users.noreply.github.com>
Refine comment to clarify useState purpose.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Following the refactor of
LinearStepperFunctional.tsx(which replaceduseEffect+addEventListenerwithonInputon native<form>elements), the corresponding rule in the generation guide was still documenting the old pattern.Changes —
FUNCTIONAL_COMPONENT_GENERATION_GUIDE.md§15useEffectblock; replaced with auseCallbackhandler at component scope andonInput={handleInput}on each<form>element.onInput/onChangeprops (Ignite UI web components bubble standard DOM events through the shadow DOM, so a parent<form>catches them); kept a fallback note for cases whereuseEffect+addEventListeneris still warranted (elements outside the React tree, non-standard event names).