-
Notifications
You must be signed in to change notification settings - Fork 236
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
Improve the way macros are imported from GOV.UK Frontend #967
Comments
One stepping stone I'd thought the kit could do would be to move those imports to an include. So layout would just have a single line: This would also be easier for using in other layouts. Though my current approach is to have all my layouts branch off of the main |
I should also note that much of my layouts are imports for my own components that I store in |
I think we should consider moving all users to the solution @edwardhorsford suggested (import all macros) - for production and prototyping. That means it's simpler for everyone, and we can remove the |
A side advantage of a separate |
components are now all imported automatically via the GOV.UK Frontend Prototype Kit config file |
At the minute all of the the component macros are included as part of the default layout:
govuk-prototype-kit/app/views/layout.html
Lines 6 to 30 in 3b6870f
We do this so that users do not need to import the components themselves – despite the examples in the Design System always including the
import
, we tell them not to include it.This means that:
We should explore ways to auto-load the components in all of the provided layouts, possibly via the extensions framework.
The text was updated successfully, but these errors were encountered: