tasks/build.js
function transpile() {
        return rollup.rollup({
            entry: path.join(dirs.source, files.main)
        }).then(function (bundle) {
            return bundle.write({
                // output format - 'amd', 'cjs', 'es6', 'iife', 'umd'
                format: 'umd',
                dest: path.join(dirs.build, files.main),
                sourceMap: false,
                banner: grunt.config('banner'),
                intro: 'mx.version = \'' + grunt.config('pkg').version + '\';\n',
                footer: '\n',
                moduleName: 'mx'
            });
        });
    }
function transpile() {
        return rollup.rollup({
            entry: path.join(dirs.source, files.main)
        }).then(function (bundle) {
            return bundle.write({
                // output format - 'amd', 'cjs', 'es6', 'iife', 'umd'
                format: 'umd',
                dest: path.join(dirs.build, files.main),
                sourceMap: false,
                banner: grunt.config('banner'),
                intro: 'mx.version = \'' + grunt.config('pkg').version + '\';\n',
                footer: '\n',
                moduleName: 'mx'
            });
        });
    }
function transpile ( ) { return rollup . rollup ( { entry : path . join ( dirs . source , files . main ) } ) . then ( function ( bundle ) { return bundle . write ( { // output format - 'amd', 'cjs', 'es6', 'iife', 'umd' format : 'umd' , dest : path . join ( dirs . build , files . main ) , sourceMap : false , banner : grunt . config ( 'banner' ) , intro : 'mx.version = \'' + grunt . config ( 'pkg' ) . version + '\';\n' , footer : '\n' , moduleName : 'mx' } ) ; } ) ; }
transpile es6 modules
transpile es6 modules