css - Output multiple LESS source maps with Grunt? -
i have grunt file compile less file css file, , create css.map
file well. great.
i have more 1 less file want though can't figure out syntax both.
i have theme.less
, main.less
need - compiled - put right folder - , map file generated each.
right have this:
//less less: { development: { options: { compress: true, yuicompress: true, optimization: 2, sourcemap: true, sourcemapfilename: "<%= yeoman.app %>/live_preview/b/css/theme.css.map" }, files: { // target.css file: source.less file // "<%= yeoman.app %>/live_preview/b/css/main.css": "<%= yeoman.app %>/less/main.less", "<%= yeoman.app %>/live_preview/b/css/theme.css": "<%= yeoman.app %>/less/theme.less" } } }
as can see commented out main.less
. theme.less
compiles , map file created, i'd both...
the crummy brute-force method define second build process , make sure build processes call both less.development1
, less.development2
:
less: { "development1": { options: { compress: true, yuicompress: true, optimization: 2, sourcemap: true, sourcemapfilename: "<%= yeoman.app %>/live_preview/b/css/theme.css.map" }, files: { // target.css file: source.less file "<%= yeoman.app %>/live_preview/b/css/theme.css": "<%= yeoman.app %>/less/theme.less" } }, "development2": { options: { compress: true, yuicompress: true, optimization: 2, sourcemap: true, sourcemapfilename: "<%= yeoman.app %>/live_preview/b/css/main.css.map" }, files: { // target.css file: source.less file "<%= yeoman.app %>/live_preview/b/css/main.css": "<%= yeoman.app %>/less/main.less" } } }
Comments
Post a Comment