Skip to content

A systemjs/builder plugin to load/render LESS in browser on the fly and bundle rendered CSS during build time.

Notifications You must be signed in to change notification settings

jack4it/system-less

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

system-less?

A systemjs/builder plugin to load/render LESS in browser on the fly and bundle rendered CSS during build time.

Usage

Install system-less like this:

jspm install github:jack4it/system-less

Also install LESS (this step will create the right map entry that the plugin expects for LESS):

jspm install npm:less

In order to make systemjs builder bundle work, also install less and clean-css via npm:

npm install less clean-css

Configuration

To load less files in browser on the fly during development time, create meta for your less files in jspm/systemjs config.js file:

packages: {
  "example": {
    "meta": {
      "./*.less": {
        "loader": "jack4it/system-less"
      }
    }
  }
}

To minify/optimize the generated CSS in the bundle file, add these options when calling bundle method of systemjs builder:

builder.bundle('example/app.js', 'example/app-bundle.js', { minify: true, cssOptimize: true })

Example

example.html: An example of how to load LESS in browser on the fly during development time

example-bundle.js: An example of how to generate css from LESS in node during build time for production

License

MIT

About

A systemjs/builder plugin to load/render LESS in browser on the fly and bundle rendered CSS during build time.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published