
Security News
Risky Biz Podcast: Making Reachability Analysis Work in Real-World Codebases
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
@felix_berlin/sass-butler
Advanced tools
A collection of useful SCSS/SASS: mixins, functions and helpers.
Stands by your side with plenty of features and mixins.
SASS Butler is a big collection of SASS mixins and functions.
Mixins and functions are unit tested via Jest and True. Unfortunately, it is not yet possible to create a coverage report.
Visit https://sass-butler.kasimir.dev for full documentation.
pnpm add @felix_berlin/sass-butler
npm i @felix_berlin/sass-butler
yarn add @felix_berlin/sass-butler
If you haven't already, install Sass.
pnpm add -D sass
npm i -D sass
yarn add -D sass
This project uses the "new" Sass Module system. Therefore your build tool or taskrunner have to support Dart Sass 1.79.0 or above.
Sass Compiler | Support |
---|---|
Dart Sass | ✅ |
Lib Sass | ❌ |
Ruby Sass | ⚰️ |
Your Dart Sass Version must be: >= 1.33.0
Single import of the used functionalities.
@use './node_modules/sass-butler/functions/first-of-list' as fol;
import all functions at once:
@use './node_modules/sass-butler/functions' as fn;
@use './node_modules/sass-butler/mixis/breakpoint' as breakpoint;
With sass-loader
:
@use '~sass-butler/mixis/breakpoint' as breakpoint;
With webpack mix
:
.sass('resources/assets/styles/app.scss', 'styles', {
sassOptions: {
includePaths: ['./node_modules'],
},
})
@use 'sass-butler/mixis/breakpoint' as breakpoint;
Some of the module comes with "global" config vars and maps (breakpoint mixin). This may be a problem since you can only overwrite once with with()
.
Here is an example how you can deal with it.
Example how to use the breakpoint mixin with own default config:
Create a new file and load the breakpoint mixin from the node_modules
with the @forward
function. Similar to the @use
function you can overwrite predefined vars with with()
.
// _custom-breakpoints.scss
@forward 'sass-butler/mixins/breakpoint' with (
// Add your own breakpoints map
$breakpoints: (
'xxs': 375px,
'xs': 568px,
'sm': 768px,
'md': 1024px,
'lg': 1260px,
'xlg': 1440px,
'fhd': 1920px,
'uhd': 2560px
)
);
In the rest of your project you don't add the module via node_modules
anymore but load the customized module _external.scss
with @use
.
// _my-module.scss
@use 'custom-breakpoints' as break;
.my-selector {
@include break.breakpoint(lg) {
padding: 12px 0 1rem 0;
}
}
:warning: Pay attention to the loading order when using redefined and package function/mixins!
:x: Can't be compiled because the (package) breakpoint mixin is already loaded in mixins.scss
.
@use 'sass-butler/mixins' as mx;
@use 'custom-breakpoints' as break;
:white_check_mark: This will work. Make sure to load the redefined module first.
@use 'custom-breakpoints' as break;
@use 'sass-butler/mixins' as mx;
You can find the documentation at: https://sass-butler.kasimir.dev
The documentation is updated automatically with each commit on the master branch.
Run following command:
npm run sassDoc
FAQs
A collection of useful SCSS/SASS: mixins, functions and helpers.
The npm package @felix_berlin/sass-butler receives a total of 30 weekly downloads. As such, @felix_berlin/sass-butler popularity was classified as not popular.
We found that @felix_berlin/sass-butler demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.
Security News
CISA’s 2025 draft SBOM guidance adds new fields like hashes, licenses, and tool metadata to make software inventories more actionable.