Skip to content

Commit

Permalink
Merge pull request #1136 from alphagov/switch-to-modern-sass-api
Browse files Browse the repository at this point in the history
Switch to modern Sass API
  • Loading branch information
DavidBiddle authored Jan 16, 2025
2 parents c7f9328 + 757202b commit 5bc1bc4
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
1 change: 1 addition & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -455,6 +455,7 @@ PLATFORMS
arm64-darwin-21
arm64-darwin-22
arm64-darwin-23
arm64-darwin-24
x86_64-darwin-20
x86_64-darwin-21
x86_64-darwin-22
Expand Down
7 changes: 3 additions & 4 deletions app/frontend/entrypoints/application.scss
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
$govuk-images-path: "@govuk/assets/images/";
$govuk-fonts-path: "@govuk/assets/fonts/";
$govuk-assets-path: "@govuk/assets/";
$govuk-global-styles: true;

@import "@govuk/all";
@import "dfe-autocomplete/src/dfe-autocomplete";
@import "pkg:govuk-frontend";
@import "pkg:dfe-autocomplete/src/dfe-autocomplete";
@import "../../components/form_header_component/";
@import "../styles/app-panel";
4 changes: 3 additions & 1 deletion vite.config.js
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
import { defineConfig } from 'vite'
import RubyPlugin from 'vite-plugin-ruby'
import * as path from 'node:path'
import { NodePackageImporter } from 'sass'

export default defineConfig({
plugins: [RubyPlugin()],
build: { emptyOutDir: true },
css: {
preprocessorOptions: {
scss: {
includePaths: ['./node_modules/govuk-frontend/'],
api: 'modern',
importers: [new NodePackageImporter()],
quietDeps: true
},
devSourcemaps: true
Expand Down

0 comments on commit 5bc1bc4

Please sign in to comment.