Skip to content

Commit

Permalink
Move template styles from core to objects layer
Browse files Browse the repository at this point in the history
  • Loading branch information
Vanita Barrett committed Dec 7, 2021
1 parent 873cc06 commit e23299f
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,14 @@ To fix the error, import `node_modules/govuk-frontend/govuk/base` first. For exa

This change was introduced in [pull request #2455: Remove 'base' import from files in `core` and `overrides` layers](https://github.com/alphagov/govuk-frontend/pull/2455).

#### Import "template" Sass file from the `objects` layer instead of the `core` layer

If you import the "template" Sass file from the `core` layer, you might see the error `File to import not found or unreadable: template` when compiling your Sass.

To fix this error, replace any imports of `node_modules/govuk-frontend/govuk/core/template` with `node_modules/govuk-frontend/govuk/objects/template`.

This change was introduced in [pull request #22463: Move template styles from `core` to `objects` layer](https://github.com/alphagov/govuk-frontend/pull/2463).

### Optional changes

We've recently made some other changes to GOV.UK Frontend. While these are not breaking changes, implementing them will make your service work better.
Expand Down
1 change: 0 additions & 1 deletion src/govuk/core/_all.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
@import "links";
@import "lists";
@import "template";
@import "typography";
@import "section-break";
@import "global-styles";
1 change: 1 addition & 0 deletions src/govuk/objects/_all.scss
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
@import "form-group";
@import "grid";
@import "main-wrapper";
@import "template";
@import "width-container";
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
@include govuk-exports("govuk/core/template") {
@import "../base";

@include govuk-exports("govuk/objects/template") {

// Applied to the <html> element
.govuk-template {
Expand Down

0 comments on commit e23299f

Please sign in to comment.