Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MOJ Frontend issues #1823

Open
joelanman opened this issue Nov 30, 2022 · 3 comments
Open

MOJ Frontend issues #1823

joelanman opened this issue Nov 30, 2022 · 3 comments

Comments

@joelanman
Copy link
Contributor

joelanman commented Nov 30, 2022

https://design-patterns.service.justice.gov.uk/get-started/prototyping/

  1. These instructions are slightly wrong:

add window.MOJFrontend.initAll() to app/assets/javascripts/application.js below the line doing the same for GOVUKFrontend

(there is no line for GOVUKFrontend)

  1. It requires jQuery

npm install jquery

  1. It would be better as a plugin - and this would avoid having to do the instructions in number 1 at all

I wonder if we can work with them to improve?

@gregtyler
Copy link

Thanks Joe, we'll take a look into how we can integrate with the latest version of the kit better. Sounds like we probably need to extend our plugin config file a bit :)

@joelanman
Copy link
Contributor Author

joelanman commented Nov 30, 2022

oh sorry if you have a config then it is a plugin already, I didn't realise. It might need an update to avoid the init but I'll check with the rest of the team. Otherwise you just need to tell people to install jquery - its no longer in the kit by default in v13. You can just run npm install jquery and we do the rest.

@gregtyler
Copy link

We believe this should be fixed in v1.6.6 of the MOJ Pattern Library where we're now using a packaged file that includes its own jQuery distro, and also an init.js script to automatically initialise the components.

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

No branches or pull requests

3 participants