How to include scripts automatically in a yeoman/grunt project?

I used grunt-include-source Install it: npm install grunt-include-source –save-dev In Gruntfile: Load it before initConfig: module.exports = function (grunt) { … grunt.loadNpmTasks(‘grunt-include-source’); Configure includeSource itself in initConfig: grunt.initConfig({ …, includeSource: { options: { basePath: ‘app’, baseUrl: “https://stackoverflow.com/”, }, server: { files: { ‘.tmp/index.html’: ‘<%= yeoman.app %>/index.html’ } }, dist: { files: { ‘<%= yeoman.dist %>/index.html’: … Read more