Socket
Socket
Sign inDemoInstall

postcss-less-parser

Package Overview
Dependencies
0
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    postcss-less-parser

PostCSS plugin for integrating the popular Less CSS pre-processor into your PostCSS workflow


Version published
Weekly downloads
3
decreased by-40%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

Less for PostCSS Build Status

PostCSS plugin for integrating the popular Less CSS pre-processor into your PostCSS workflow.

WIP - If anyone wants to help me get this working (especially tests, which haven't worked yet because of the async flow), that would be great. Pull requests welcome.

Usage

Follow these simple steps to use [postcss-less].

Add [postcss-less] to your build tool:

npm install postcss-less --save-dev
Node
var less = require('postcss-less');
less({ /* options */ }).process(YOUR_CSS, { parser: less });

Load [postcss-less] as a PostCSS plugin:

var less = require('postcss-less');
postcss([
    less({ /* options */ })
]).process(YOUR_CSS, { parser: less }).then(function (result) {
	// do something with result.css
});
Gulp

Add [Gulp PostCSS] to your build tool:

npm install gulp-postcss --save-dev

Enable [postcss-less] within your Gulpfile:

var postcss = require('gulp-postcss');

gulp.task('less', function () {
    return gulp.src('./css/src/style.less').pipe(
        postcss([
            require('postcss-less')({ /* options */ })
        ])
    ).pipe(
        gulp.dest('./css')
    );
});
Grunt

Add [Grunt PostCSS] to your build tool:

npm install postcss-less --save-dev

Enable [postcss-less] within your Gruntfile:

grunt.loadNpmTasks('grunt-postcss');

grunt.initConfig({
	postcss: {
		options: {
			parser: require('postcss-less'),
			processors: [
				require('postcss-less')({ /* options */ })
			]
		},
		dist: {
			src: 'css/*.css'
		}
	}
});

Keywords

FAQs

Last updated on 11 May 2016

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc