简体   繁体   中英

grunt livereload globally for all files

livereload: {
    files: ['*.html', '*.php', 'js/**/*.{js,json}', 'css/*.css', 'img/**/*.{png,jpg,jpeg,gif,webp,svg}'],
    options: {
        livereload: true
    }
}

above is my partial code of gruntfile.js, it work for my index.html which located in the same level with the gruntfile.js. What if I have many folders? How to avoid declare many example/*.php ? It's tedious every time u need to declare something just to use grunt.

livereload: {
    files: ['**/*'],
    options: {
        livereload: true
    }
}

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM