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

Move from libsass -> dart-sass #1253

Merged
merged 1 commit into from
Jan 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,7 @@ config/zendesk.yml
# Yarn
node_modules
yarn-error.log

# dartsass-rails
/app/assets/builds/*
!/app/assets/builds/.keep
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ gem "rails", "7.1.3"
gem "bootsnap", require: false
gem "bootstrap-kaminari-views"
gem "cancancan"
gem "dartsass-rails"
gem "fog-aws"
gem "gds-api-adapters"
gem "gds-sso"
Expand All @@ -17,7 +18,6 @@ gem "jquery-ui-rails", github: "jquery-ui-rails/jquery-ui-rails", tag: "v7.0.0"
gem "kaminari"
gem "plek"
gem "redis"
gem "sassc-rails"
gem "select2-rails"
gem "sentry-sidekiq"
gem "sprockets-rails"
Expand Down
24 changes: 10 additions & 14 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@ GEM
crack (0.4.5)
rexml
crass (1.0.6)
dartsass-rails (0.5.0)
railties (>= 6.0.0)
sass-embedded (~> 1.63)
date (3.3.4)
diff-lcs (1.5.0)
docile (1.4.0)
Expand Down Expand Up @@ -174,7 +177,6 @@ GEM
zendesk_api (>= 1.37, < 4.0)
globalid (1.2.1)
activesupport (>= 6.1)
google-protobuf (3.25.1)
google-protobuf (3.25.1-aarch64-linux)
google-protobuf (3.25.1-arm64-darwin)
google-protobuf (3.25.1-x86_64-linux)
Expand Down Expand Up @@ -263,7 +265,6 @@ GEM
mime-types-data (~> 3.2015)
mime-types-data (3.2023.1205)
mini_mime (1.1.5)
mini_portile2 (2.8.5)
minitest (5.21.1)
msgpack (1.7.2)
multi_json (1.15.0)
Expand All @@ -283,9 +284,6 @@ GEM
net-protocol
netrc (0.11.0)
nio4r (2.7.0)
nokogiri (1.16.0)
mini_portile2 (~> 2.8.2)
racc (~> 1.4)
nokogiri (1.16.0-aarch64-linux)
racc (~> 1.4)
nokogiri (1.16.0-arm64-darwin)
Expand Down Expand Up @@ -648,14 +646,14 @@ GEM
ruby-progressbar (1.13.0)
ruby2_keywords (0.0.5)
rubyzip (2.3.2)
sass-embedded (1.70.0-aarch64-linux-gnu)
google-protobuf (~> 3.25)
sass-embedded (1.70.0-arm64-darwin)
google-protobuf (~> 3.25)
sass-embedded (1.70.0-x86_64-linux-gnu)
google-protobuf (~> 3.25)
sassc (2.4.0)
ffi (~> 1.9)
sassc-rails (2.1.2)
railties (>= 4.0.0)
sassc (>= 2.0)
sprockets (> 3.0)
sprockets-rails
tilt
select2-rails (4.0.13)
selenium-webdriver (4.16.0)
rexml (~> 3.2, >= 3.2.5)
Expand Down Expand Up @@ -699,7 +697,6 @@ GEM
statsd-ruby (1.5.0)
stringio (3.1.0)
thor (1.3.0)
tilt (2.0.10)
timecop (0.9.8)
timeliness (0.4.5)
timeout (0.4.1)
Expand Down Expand Up @@ -745,13 +742,13 @@ GEM
PLATFORMS
aarch64-linux
arm64-darwin
ruby
x86_64-linux

DEPENDENCIES
bootsnap
bootstrap-kaminari-views
cancancan
dartsass-rails
factory_bot_rails
fog-aws
gds-api-adapters
Expand All @@ -774,7 +771,6 @@ DEPENDENCIES
rspec-its
rspec-rails
rubocop-govuk
sassc-rails
select2-rails
sentry-sidekiq
shoulda
Expand Down
2 changes: 2 additions & 0 deletions Procfile.dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
web: bin/rails server -p 3000
css: bin/rails dartsass:watch
Empty file added app/assets/builds/.keep
Empty file.
2 changes: 1 addition & 1 deletion app/assets/config/manifest.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
//= link_tree ../images
//= link_directory ../javascripts .js
//= link_directory ../stylesheets .css
//= link_tree ../builds
6 changes: 6 additions & 0 deletions bin/dev
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env sh
if ! gem list foreman -i --silent; then
echo "Installing foreman..."
gem install foreman
fi
exec foreman start -f Procfile.dev "$@"
4 changes: 4 additions & 0 deletions config/environments/development.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,10 @@
# Suppress logger output for asset requests.
config.assets.quiet = true

# Disable digest to see the latest stylesheet changes when running Sass in watch mode
# See https://guides.rubyonrails.org/v7.1.3/asset_pipeline.html#turning-digests-off
config.assets.digest = false

# Raises error for missing translations.
# config.i18n.raise_on_missing_translations = true

Expand Down
1 change: 1 addition & 0 deletions config/initializers/dartsass.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Rails.application.config.dartsass.build_options << " --quiet-deps"
Loading