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

Updating the kit - issues with component imports #795

Closed
edwardhorsford opened this issue Aug 28, 2019 · 5 comments
Closed

Updating the kit - issues with component imports #795

edwardhorsford opened this issue Aug 28, 2019 · 5 comments
Labels
🕔 Hours A well understood issue which we expect to take less than a day to resolve.

Comments

@edwardhorsford
Copy link
Contributor

On the cross gov slack @marthaboggins raised an issue where the charcterCount wasn't working - it looks like this was a combination of updating to the latest frontend, but the kit referencing the old component at old path. The docs also didn't make clear what things were using what versions and only worked for certain versions.

I see a few issues which wouldn't be too hard to fix:

  • The kit update docs don't tell you you need to update layout.html to reference the new location.
  • If you’ve got your own changes in layout.html (not unlikely), you'd have to merge those with the new components as they’re manually added.

Suggestion:

We've long had the aim that stuff in app should be user specific - but in this case the components need to be manually added. Copying the app folder from an old prototype to a new one won't work.

I'd suggest that the individual macro imports for all gov.uk components should be done via separate include file. That way if the kit gets updated and macros are added, that include file can be automatically updated rather than manually adding the items in layout.html.

@edwardhorsford
Copy link
Contributor Author

Suggesting something like this, where we reference the macros, but don't actually define them in layout.html

Screenshot 2019-08-28 at 13 40 47

@NickColley
Copy link
Contributor

This spike is somewhat related: alphagov/govuk-frontend#1436

@kellylee-gds kellylee-gds added 🕔 Hours A well understood issue which we expect to take less than a day to resolve. Priority: low and removed awaiting-triage labels Aug 28, 2019
@edwardhorsford
Copy link
Contributor Author

@NickColley yeah, that seems similar.

Presumably less risky / easier to do if just for the kit? Essentially just abstracting out the other macro includes to a file outside of /app

@NickColley
Copy link
Contributor

Yes it should be done in the kit first, just posting for reference.

@joelanman
Copy link
Contributor

closing in favour of #967

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🕔 Hours A well understood issue which we expect to take less than a day to resolve.
Projects
None yet
Development

No branches or pull requests

5 participants