Security News
Supply Chain Attack Detected in Solana's web3.js Library
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
postcss-only-one-root
Advanced tools
A PostCSS plugin to remove all instances of “:root” but one from a stylesheet.
This plugin is very basic. It removes all instances of :root
except for the first it encounters from a processed stylesheet (if present). I built this as I used automatical localised imports for my Webpack scss files, which occured in duplicate references to the :root selector variables.
Otherwise, you probably have no use for this plugin. You should run this plugin after running [postcss-custom-properties]
npm install --save postcss-only-one-root
:root {
--color-blue: blue;
}
@import "./variables";
.something-1 {
color: var(--color-blue);
}
@import "./variables";
.something-2 {
color: var(--color-blue);
}
:root {
color-blue: blue
}
.something-1 {
color: blue;
color: var(--color-blue);
}
.something-2 {
color:blue;
color: var(--color-blue);
}
See the PostCSS documentation for examples on how to use this plugin in different environments. This plugin takes no options.
FAQs
Removes all but one instance of :root
The npm package postcss-only-one-root receives a total of 1 weekly downloads. As such, postcss-only-one-root popularity was classified as not popular.
We found that postcss-only-one-root demonstrated a not healthy version release cadence and project activity because the last version was released 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
A supply chain attack has been detected in versions 1.95.6 and 1.95.7 of the popular @solana/web3.js library.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.