Skip to content

Instantly share code, notes, and snippets.

@rririanto
Created March 5, 2021 18:13
Show Gist options
  • Save rririanto/8b1eb827573a88c7b13381436f570bee to your computer and use it in GitHub Desktop.
Save rririanto/8b1eb827573a88c7b13381436f570bee to your computer and use it in GitHub Desktop.
Grunt File multiple tasks
module.exports = function (grunt) {
grunt.initConfig({
uncss: {
home: {
files: [{
nonull: true,
src: ['http://localhost:8000/'],
dest: 'apps/static/css/portal.css'
}]
},
startup: {
files: [{
nonull: true,
src: ['http://localhost:8000/startups'],
dest: 'apps/static/css/startups.css'
}]
},
tags: {
files: [{
nonull: true,
src: ['http://localhost:8000/tags'],
dest: 'apps/static/css/tags.css'
}]
},
job_detail: {
files: [{
nonull: true,
src: ['http://localhost:8000/job/cong-ty-tnhh-dau-tu-va-cham-soc-suc-khoe-chau-a-thai-binh-duong/huan-luyen-vien-kickfit/'],
dest: 'apps/static/css/job_detail.css'
}]
},
options: {
ignoreSheets : [/fonts.googleapis/, /cdn.jsdelivr.net/],
stylesheets: ['/static/styles/styles.css'],
report: 'gzip'
}
}
});
// Load the plugins
grunt.loadNpmTasks('grunt-uncss');
// Default tasks.
grunt.registerTask('default', ['uncss']);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment