theodinproject
theodinproject copied to clipboard
Update Javascript handling the user settings page
Description
Some of the legacy Javascript can now be updated so we can eventually remove the depedency on jquery.
As part of this we need to update this file to use a Stimulus Controller.
Suggest reading to help you: https://stimulus.hotwired.dev/ and https://www.betterstimulus.com/
Acceptance Criteria:
- The Admin Flash operates as it currently does
- A stimulus controller is created to handle the interaction
Additional Information:
Stimulus controllers are all about finding the correct level of abstraction. The suggested reading for better stimulus covers this.
@CouchofTomato curious about why this issue was put on hold. If the situation has changed in regards to why this is on hold I can start working on this one.
I honestly can't remember mate. I should probably have made a note. I think it's because of a lot of other changes that were happening. I don't have an issue with it being worked on though.
Sweet. I'll start work on this one next then!
~~It would be worth researching a bit how others are doing this with Stimulus @linkonsat if you don't mind? It will be difficult and clunky adapting our existing form validation code to a Stimulus controller.~~
Sorry, I thought this was the form validations issue somehow 😆
But it would be worth holding off on the settings page JS. It's a perfect use case for Hotwire turbo frames. We're going to try getting that in the app during the tailwind move. There are a few areas that need it.
All good @KevinMulhern ! I'll pick it up eventually I'm sure if it's still around. I'll take a look at the other two stimulus issues. Actually it looks like the forms validations is the only one besides this one for the JS stimulus issues left. So I'll move onto that and do some research on it to see how's it's done. *Assuming the tailwind rework won't impact that issue.
Completed with: https://github.com/TheOdinProject/top-meta/issues/223