不知道這是否是我的錯誤或錯誤配置,但使用grunt觀看一些sass文件時,它絕對會觀看文件,但只能編譯sass和更新我退出觀察者時的目標文件。grunt watch - 編譯sass,但只能在手錶結束後
這裏是我的手錶節點:
watch: {
sass : {
files: [sassPath.scss],
tasks: ['sass']
}
}
例如,這在什麼是目前發生的事情:
1. I do `grunt watch` on the command line
2. Start editing sass files
3. Command line notifies me that the change has been detected and it runs the sass task successfully
4. I manually look at the destination css file - no changes
5. ctrl + c to close the watcher while looking in the destination css file - i can see it updated as soon as the watch closes
我真的想目標css文件儘快青菜編譯
更新
我沒有看到你的'咕嚕表:sass'任務有什麼問題。你有沒有試過自己運行它?對於'watch'任務來說這不是一種常見的行爲,但我必須仔細看看你的'Gruntfile.js'來看看是否有其他問題。嘗試更新你的本地'grunt'和相關的依賴項('watch'和'sass')。 –