8
0

gruntfile.js 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. /* jshint node: true, esnext: true, varstmt: true */
  2. 'use strict';
  3. module.exports = ( grunt ) => {
  4. // First register the "default" task, so it can be analyzed by other tasks.
  5. grunt.registerTask( 'default', [ 'jshint:git', 'jscs:git' ] );
  6. // Files that will be ignored by the "jscs" and "jshint" tasks.
  7. const ignoreFiles = [
  8. 'src/lib/**',
  9. // Automatically loaded from .gitignore. Add more if necessary.
  10. ];
  11. // Basic configuration which will be overloaded by the tasks.
  12. grunt.initConfig( {
  13. pkg: grunt.file.readJSON( 'package.json' ),
  14. lodash: {
  15. build: {
  16. dest: 'src/lib/lodash',
  17. options: {
  18. modifier: 'modern',
  19. modularize: true,
  20. exports: 'es',
  21. flags: [
  22. 'development'
  23. ],
  24. include: [
  25. 'clone',
  26. 'extend',
  27. 'isPlainObject',
  28. 'isObject',
  29. 'isArray',
  30. 'last',
  31. 'isEqual'
  32. ]
  33. }
  34. }
  35. },
  36. jshint: {
  37. options: {
  38. ignores: ignoreFiles
  39. }
  40. },
  41. jscs: {
  42. options: {
  43. excludeFiles: ignoreFiles
  44. }
  45. }
  46. } );
  47. // Finally load the tasks.
  48. grunt.loadTasks( 'dev/tasks' );
  49. };