Skip to content

Commit 19c66f4

Browse files
committed
feat: add Dart Sass initializer to silence Bootstrap deprecation warnings
1 parent 44576d5 commit 19c66f4

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

config/initializers/dartsass.rb

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# frozen_string_literal: true
2+
3+
# Configure Dart Sass to silence Bootstrap deprecation warnings
4+
# These warnings are from Bootstrap's internal implementation and will be
5+
# fixed when Bootstrap releases a Dart Sass 3.0 compatible version.
6+
#
7+
# Warnings silenced:
8+
# - import: Bootstrap still uses @import (will be removed in Bootstrap 6)
9+
# - global-builtin: Bootstrap uses global functions (type-of, unit, map-has-key)
10+
# - color-functions: Bootstrap uses deprecated color functions (red, green, blue)
11+
12+
Rails.application.config.sass.quiet_deps = true
13+
Rails.application.config.sass.silence_deprecations = %w[
14+
import
15+
global-builtin
16+
color-functions
17+
]
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# frozen_string_literal: true
2+
3+
# Configure Dart Sass to silence Bootstrap deprecation warnings
4+
# These warnings are from Bootstrap's internal implementation and will be
5+
# fixed when Bootstrap releases a Dart Sass 3.0 compatible version.
6+
#
7+
# Warnings silenced:
8+
# - import: Bootstrap still uses @import (will be removed in Bootstrap 6)
9+
# - global-builtin: Bootstrap uses global functions (type-of, unit, map-has-key)
10+
# - color-functions: Bootstrap uses deprecated color functions (red, green, blue)
11+
12+
Rails.application.config.sass.quiet_deps = true
13+
Rails.application.config.sass.silence_deprecations = %w[
14+
import
15+
global-builtin
16+
color-functions
17+
]

0 commit comments

Comments
 (0)