Skip to content

ENH Convert to functional components#182

Draft
emteknetnz wants to merge 1 commit intosilverstripe:6.0from
creative-commoners:pulls/6.0/js-deps
Draft

ENH Convert to functional components#182
emteknetnz wants to merge 1 commit intosilverstripe:6.0from
creative-commoners:pulls/6.0/js-deps

Conversation

@emteknetnz
Copy link
Copy Markdown
Member

@emteknetnz emteknetnz commented Jan 8, 2025

Issue silverstripe/.github#336

Also updated the qrcode.react dep to the latest version. Because the latest version of that dep wasn't compatible with class components, all components in totp + mfa modules were upgarde to functional components.

Incompatibility was seen with a console error Warning: Invalid hook call. Hooks can only be called inside of the body of a function component. and the component was unable to render

Update: This PR is not complete, though I'll leave open in a draft state if we wish to swap to functional components in the future. You'll also want the corresponding mfa PR

@emteknetnz emteknetnz marked this pull request as draft January 8, 2025 22:11
@emteknetnz emteknetnz changed the title ENH Convert Register to functional component ENH Convert to functional components Jan 8, 2025
@emteknetnz emteknetnz force-pushed the pulls/6.0/js-deps branch 2 times, most recently from dd415d0 to 84e844a Compare January 12, 2025 22:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant