GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Migrate to Sass modules by mdo · Pull Request #41512 · twbs/bootstrap

Conversation

@mdo

@mdo mdo commented Jun 2, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

This is a WIP effort to pull out the Sass module changes from my v6 branch to see how minimal we can make an earlier release to get folks onto newer versions of Dart Sass, Sass modules, etc. TBD if we do this, but wanted to try over the weekend. Still a few more things to bring in here, but it's getting close. I think the _maps and _variables-dark are my current biggest problems.

Update: Original comment contents are below. I'm merging this as the main Sass modules migration for now, and will start in on the rest in v6-dev in separate efforts.


This branch aims to:

  1. Migrate to Dart Sass only, dropping the older and deprecated Node Sass.
  2. Replace all @import with @use and @forward, including in our documentation.
  3. Lightly reorganize the scss/ directory with additional subfolders.
  4. Colocate Sass variables, loops, and mixins within each stylesheet that relies on them.
  5. Minimally revamp our theme colors, functions, and some global configuration variables to avoid circular dependency imports with the move to Sass modules. More info coming here…
  6. Restore flex grid alongside CSS grid, update grid bundle

Optional changes that feel within reason of a more focused v6 release:

  • Dropping jQuery interfaces
  • Bumping browser support slightly
  • Embrace logical properties exclusively, thereby dropping our RTL bundles
  • Utilities: migrate aspect ratio helper to utility, some additional and more modern utilities

What's not coming that would be moved to a faster v7 release:

  • CSS layers
  • Revamping the utility API to allow multiple selector types, removing !important for layers, streamlining keys
  • Nearly all utilities and helpers changes
  • More extensive changes to theming, color modes, and colors
  • Dropping flexbox grid system for CSS Grid system

Probably some other things to pull out too, but wanted to spike this out.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

julien-deramond, CyrilKrylatov, jcoyne, ajiho, rafaeldev, JacobJoergensen, goldmont, MasihTak, Justintime50, piotaixr, and 13 more reacted with heart emoji ajiho, MasihTak, fadrian06, and balthild reacted with rocket emoji julien-deramond, ajiho, theodorejb, louismaximepiton, MasihTak, fadrian06, and Alanaktion reacted with eyes emoji
All reactions
  • ❤️ 23 reactions
  • 🚀 4 reactions
  • 👀 7 reactions
@ajiho

ajiho commented Jun 15, 2025

Copy link
Copy Markdown

I'm glad to have started considering this and look forward to updates

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@mdo
mdo force-pushed the sass-modules-only branch from 2d6dd7b to bdcdc68 Compare June 17, 2025 17:00
@richware

richware commented Jun 21, 2025

Copy link
Copy Markdown

I have just spent a week converting 5.3.3 to use namespace removing all @imports and using @use/@forward. I have created a 5.3.6 version (on my system) that I would be willing to share for those using the newest version of PhpStorm which advanced dart sass and deprecated @import.

This is a temporary fix until v6 is released and I would be willing to share.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

mdo
mdo commented Jun 21, 2025
View reviewed changes
Comment thread scss/layout/index.scss Resolved

Uh oh!

There was an error while loading. Please reload this page.

Comment thread scss/layout/_grid.scss Resolved

Uh oh!

There was an error while loading. Please reload this page.

@mdo
mdo force-pushed the sass-modules-only branch 2 times, most recently from 77b5a29 to a66964b Compare June 22, 2025 16:26
@ajiho

ajiho commented Jun 22, 2025

Copy link
Copy Markdown

@raajtram

I think @mdo will soon complete the migration in this area, and I am also waiting for it

  1. Replace all @import with @use and @forward, including in our documentation.

Just for this point, it seems like we don't need to release it in v6, right?
Could it be 5.4?

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@mdo

mdo commented Jun 22, 2025

Copy link
Copy Markdown
Member Author

Just for this point, it seems like we don't need to release it in v6, right?
Could it be 5.4?

Not the way we want to do it. It requires changing all our imports, and to allow the new Dart Sass customization methods, it feels like the right approach to refactor some things now.

It was suggested to us that we could double the number of files we have and so some custom forwarding (I think Core UI did this with their Bootstrap fork), but that pollutes the codebase and makes things much less approachable. Making the dependencies and modules super clear feels right at this time.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@julien-deramond
julien-deramond force-pushed the sass-modules-only branch 3 times, most recently from 03b0c2e to 3371816 Compare June 26, 2025 15:39
julien-deramond
julien-deramond reviewed Jun 26, 2025
View reviewed changes
Comment thread scss/helpers/_color-bg.scss
@use "../config" as *;
@use "../variables" as *;

// All-caps `RGBA()` function used because of this Sass bug: https://github.com/sass/node-sass/issues/2251

@julien-deramond julien-deramond Jun 26, 2025 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

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.

Just to remember checking it, maybe we can switch to rgba() or color-mix() in this file and _colored-links.scss.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

mdo reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
julien-deramond
julien-deramond reviewed Jun 26, 2025
View reviewed changes
Comment thread site/src/content/docs/components/alerts.mdx Outdated
@@ -140,7 +140,7 @@ As part of Bootstrap’s evolving CSS variables approach, alerts now use local C

<DeprecatedIn version="5.3.0" />

@julien-deramond julien-deramond Jun 26, 2025

Copy link
Copy Markdown
Member

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.

Since it's going to be a major version, we'll need to get rid (and probably document in the migration guide) all the things that were deprecated in v5.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

mdo reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@julien-deramond julien-deramond mentioned this pull request Jul 2, 2025
Docs: fix scss autorecompile in dev mode #41574
Merged
4 of 7 tasks
@mrholek

mrholek commented Jul 3, 2025

Copy link
Copy Markdown
Contributor

Just for this point, it seems like we don't need to release it in v6, right?
Could it be 5.4?

Not the way we want to do it. It requires changing all our imports, and to allow the new Dart Sass customization methods, it feels like the right approach to refactor some things now.

It was suggested to us that we could double the number of files we have and so some custom forwarding (I think Core UI did this with their Bootstrap fork), but that pollutes the codebase and makes things much less approachable. Making the dependencies and modules super clear feels right at this time.

@ajiho, as @mdo mentioned, the only way to maintain backward compatibility is to double the number of files by adding a *.import.scss scss file, which is not an elegant solution.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@julien-deramond julien-deramond mentioned this pull request Jul 5, 2025
Drop node-sass support #41112
Closed
9 of 22 tasks
@julien-deramond
julien-deramond force-pushed the sass-modules-only branch from 1388120 to b93b4c4 Compare July 5, 2025 11:03
@mdo
mdo force-pushed the sass-modules-only branch from b93b4c4 to 0174c06 Compare July 16, 2025 17:27
theodorejb
theodorejb reviewed Jul 17, 2025
View reviewed changes
Comment thread scss/_functions.scss
}

// Shade a color: mix a color with black
// // Shade a color: mix a color with black

@theodorejb theodorejb Jul 17, 2025

Copy link
Copy Markdown

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.

Why are extra slashes added to three of these comments?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@mdo mdo Jul 17, 2025

Copy link
Copy Markdown
Member Author

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.

Just to make sure it's really really commented out. Kidding aside, it's because I commented out large sections of code and then restored sub-sections one at a time. It'll get cleaned up eventually.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

theodorejb and rafawashere reacted with thumbs up emoji
All reactions
  • 👍 2 reactions
@XanderVertegaal XanderVertegaal mentioned this pull request Jul 21, 2025
fix: importing the project using modern CSS loaders UtrechtUniversity/UU-Bootstrap#22
Open
@mdo
mdo force-pushed the sass-modules-only branch from 0174c06 to 740e53c Compare August 10, 2025 18:57
@mdo mdo changed the title v6: Sass modules only Migrate to Sass modules Aug 26, 2025
@mdo
mdo force-pushed the sass-modules-only branch from 740e53c to 81dc426 Compare August 26, 2025 23:47
@mdo
mdo changed the base branch from main to v6-dev August 26, 2025 23:48
@mdo
mdo force-pushed the v6-dev branch from ef5ea87 to 25aa8cc Compare August 27, 2025 04:09
@mdo
mdo force-pushed the sass-modules-only branch 2 times, most recently from 0d09ba6 to d445cdc Compare August 28, 2025 03:56
@mdo
mdo marked this pull request as ready for review August 28, 2025 04:00
@mdo
mdo requested review from a team as code owners August 28, 2025 04:00
mdo and others added 7 commits August 27, 2025 21:01
@mdo
Fix docs colors
9f53660
@julien-deramond @mdo
Revert typo
e44daa2
@julien-deramond @mdo
Reintroduce css-lint-vars npm script
12e7720
@mdo
Bump to Sass v1.90.x
cfbc1f6
@mdo
Fixes
d4dc9c6
@mdo
more
1678a76
@mdo
Remove
dea3775
@mdo
mdo force-pushed the sass-modules-only branch from 661ba12 to dea3775 Compare August 28, 2025 04:01
@mdo
mdo merged commit 5e5ea15 into v6-dev Aug 28, 2025
@mdo
mdo deleted the sass-modules-only branch August 28, 2025 04:15
@mdo mdo added css Sass sources or compiled CSS v6 v6, the main branch labels Aug 28, 2025
@mdo mdo added this to v6.0.0 Aug 28, 2025
@github-project-automation github-project-automation Bot moved this to Inbox in v6.0.0 Aug 28, 2025
mdo added a commit that referenced this pull request Sep 10, 2025
@mdo @julien-deramond
Migrate to Sass modules (#41512)
ba12f19
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
mdo added a commit that referenced this pull request Sep 16, 2025
@mdo @julien-deramond
Migrate to Sass modules (#41512)
a2f94c4
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
mdo added a commit that referenced this pull request Sep 21, 2025
@mdo @julien-deramond
Migrate to Sass modules (#41512)
062e742
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
@chalin chalin mentioned this pull request Oct 5, 2025
Drop libsass, use dart sass instead docsy/docsy#2279
Closed
mdo added a commit that referenced this pull request Oct 10, 2025
@mdo @julien-deramond
Migrate to Sass modules (#41512)
009d985
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
mdo added a commit that referenced this pull request Nov 14, 2025
@mdo @julien-deramond
Migrate to Sass modules (#41512)
9699052
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
rhydianroberts referenced this pull request in SymfonyCasts/sass-bundle Dec 3, 2025
@cedriclombardot @bocharsky-bw
DEPRECATION WARNING [import]: Sass @import rules are deprecated and w… (
3472f20
#85)

* DEPRECATION WARNING [import]: Sass @import rules are deprecated and will be removed in Dart Sass 3.0.0.

* Replace import with use in fixtures

---------

Co-authored-by: Victor Bocharsky <[email protected]>
mdo added a commit that referenced this pull request Jan 9, 2026
@mdo @julien-deramond
Migrate to Sass modules (#41512)
72e3d57
* Reorganize scss folder

* Migrate to Sass modules

* Migrate docs to Sass modules, comment out docs grid CSS

* Give helpers folder an index.scss, migrate ratio helper to aspect-ratio utility

* Delete node sass Action

* Modify Sass tests to pass for new Sass modules implementation

* Don't disallow calc()

* Move heading classes back to Reboot to prevent a dependency

* Utilities, some helpers, and theme colors

* Temporary fix of docs compilation

* Temporary Bundlewatch fix

* docs fix import to use

* Restyle docs callouts

* Fix docs colors

* Revert typo

* Reintroduce `css-lint-vars` npm script

* Bump to Sass v1.90.x

* Fixes

* more

* Remove

---------

Co-authored-by: Julien Déramond <[email protected]>
@DoodlesEpic DoodlesEpic mentioned this pull request Jan 9, 2026
dart-sass 1.80.0+ throwing a lot of deprecations #40962
Closed
3 tasks done
@JamesVanWaza JamesVanWaza mentioned this pull request Feb 21, 2026
AISD-Todolist JamesVanWaza/algolia-instantsearch-demo#3
Open
26 of 38 tasks
@carylwyatt carylwyatt mentioned this pull request Apr 15, 2026
Page turner dependency updates hathitrust/babel#201
Merged
@dwvisser dwvisser mentioned this pull request Jul 1, 2026
Upgrade to Boostrap v6 when available dwvisser/knoxccl#81
Open
@mrholek mrholek mentioned this pull request Sep 6, 2026
fix(scss): let $container-max-widths hold a width across breakpoints coreui/coreui-pro#1187
Closed
@carylwyatt carylwyatt mentioned this pull request Sep 15, 2026
Dependency updates sept 2026 hathitrust/firebird-common#156
Merged
@julien-deramond julien-deramond mentioned this pull request Sep 28, 2026
bootstrap-grid.css lost box-sizing: border-box on columns, so they wrap without reboot julien-deramond/bootstrap-test-playground#238
Closed
@julien-deramond julien-deramond mentioned this pull request Oct 17, 2026
Fix luminance with non-integer Sass color channels #42453
Closed
5 of 10 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@julien-deramond julien-deramond julien-deramond left review comments
+1 more reviewer
@theodorejb theodorejb theodorejb left review comments
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

css Sass sources or compiled CSS v6 v6, the main branch

Projects

v6.0.0
Status: Inbox

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

6 participants

@mdo @ajiho @richware @mrholek @theodorejb @julien-deramond
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.