🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

grunt-w20

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

grunt-w20

Produce an optimized build of a w20 application

latest
Source
npmnpm
Version
0.1.1
Version published
Maintainers
1
Created
Source

grunt-w20

Grunt plugin providing tasks for W20-based applications.

Optimization

Optimization (concatenation and minification of js/css files) is done with r.js.

Install the plugin

npm install -g grunt-w20

Load it in your gruntfile.js

grunt.loadNpmTasks('grunt-w20');

Configure the task

grunt.initConfig({
    w20: {
        optimize: {}
    }
}

The above should be sufficient for a default app structure.

Options

w20: {
    optimize: {
        options: {
           basePath: "the application base path, default to '.'"
           applicationManifest: "name of the application manifest, default to 'w20.app.json')"
           componentsPath: "path to the component folder, default to 'bower_components')"
            buildConfig: {
                // r.js configuration, sensible defaults are applied, override only for specific need
                optimize: 'closure', // if you want to use closure as the optimizer, default to uglify2
                out: 'my/dist/optimized.test.min.js',
                ...
            }
        }
    }
}

Keywords

gruntplugin

FAQs

Package last updated on 06 Jun 2016

Did you know?

Socket

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