-
Notifications
You must be signed in to change notification settings - Fork 20
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
Migrate to Dart Sass from LibSass #3908
Conversation
68b3671
to
28833a4
Compare
28833a4
to
0f989df
Compare
0f989df
to
338d739
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work @jon-kirwan. I've tested locally using live data and integration and everything builds correctly / app runs as normal. Looks like the linter has failed, however it is an easy fix.
Also noted the deprecation warnings (Using / for division outside of calc()
), however I understand that we cant fix them without breaking the LibSass implementation in the components Gem. Hopefully we (GOV.UK) can migrate to Dart Sass fully before 2.0 is released and squash the warnings.
Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
- Create `dartsass.builds` initializer and add all Sass files to be compiled. See https://github.com/rails/dartsass-rails#configuring-builds - Create .keep - Update manifest file to use /builds directory - Ignore /builds Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
Replace instances with CSS url() function. See rails/dartsass-rails#18. Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
Also, turn digests off in development Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
Co-Authored-By: Martin Jones <28779939+MartinJJones@users.noreply.github.com>
338d739
to
d56a877
Compare
Thanks @1pretz1. I've resolved the linter error, and all CI checks are now passing. Currently, the linter warnings are from GOV.UK Publishing Components, and I've opened an issue to investigate. We also had warnings from the Design System, but have silenced those with this change: frontend/config/initializers/dartsass.rb Line 22 in d56a877
|
What
Migrate to Dart Sass from LibSass.
Why
Visual Changes
None.
How can I test these changes?
yarn jasmine:prepare
(or runbundle exec rake app:assets:clobber app:assets:precompile
)/builds
folder:app/assets/builds
should now be populated with CSS files. Note, the/public
directorydartsass-rails
is bundled and any Dart Sass warnings encountered during the compilation process are reported)Anything else
Once the PR gets the green light, any temporary commits and references to local gems e.g.
gem "govuk_publishing_components", path: "../govuk_publishing_components"
will be removed.See: