Grunt watch kompiliert meine LESS-Datei, aber erzeugt keine CSS-Datei. Ich weiß nicht, was das Problem ist. Kann jemand da draußen helfen?grunt watch kompiliert weniger, aber nicht generieren css
Hier ist mein Grunzen Code:
module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-less');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
less: {
options: {
paths: 'less',
yuicompress: true
},
files: {
'styles.css': 'less/button.less'
}
},
watch: {
less: {
files: 'less/*.less',
tasks: 'less'
}
}
});
}
Und hier ist mein package.json Code:
{
"name": "project-name",
"version": "1.0.0",
"description": "Awesome project",
"devDependencies": {
"grunt-contrib-less": "^1.4.1",
"grunt-contrib-watch": "^1.0.0"
}
}
unter meine Ordnerstruktur Siehe:
Grunt Uhr funktioniert gut: