![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
postcss-parent-selector
Advanced tools
PostCSS plugin for adding a parent selector to all rules in a css file.
PostCSS plugin for adding a parent selector to all rules in a CSS file.
Options:
{selector: '.parent'}
Input CSS:
.foo {
/* Input example */
}
.foo .bar,
div.foo .bar {
/* Input example */
}
Output CSS:
.parent .foo {
/* Input example */
}
.parent .foo .bar,
.parent div.foo .bar {
/* Input example */
}
The selector
option takes a string value that should be placed at the beginning of each selector, including selector lists separated by commas.
// class
{selector: '.parent-class'}
// id
{selector: '#parent-id'}
// element
{selector: 'div.parent-class'}
postcss([ require('postcss-parent-selector') ])
See PostCSS docs for examples for your environment.
import gulp from 'gulp';
import plumber from 'gulp-plumber';
import sass from 'gulp-sass';
import postcss from 'gulp-postcss';
import parentSelector from 'postcss-parent-selector';
gulp.task('styles', () => {
// array containing postcss plugins
var processors = [
parentSelector({selector: '.parent'})
];
// source compiled css or scss files
return gulp.src('./path/to/*.scss')
.pipe(plumber())
// scss compiling
.pipe(sass.sync({
outputStyle: 'expanded',
precision: 10,
includePaths: ['.']
}).on('error', sass.logError))
// postcss processes the compiled css
.pipe(postcss(processors))
.pipe(gulp.dest('./path/to/dest'))
.pipe(reload({ stream: true }));
});
[1.0.0] - 2016-12-03
@keyframes
FAQs
PostCSS plugin for adding a parent selector to all rules in a css file.
The npm package postcss-parent-selector receives a total of 6,112 weekly downloads. As such, postcss-parent-selector popularity was classified as popular.
We found that postcss-parent-selector 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
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.