11

How can I use grunt-contrib-requirejs config OR even r.js Config to not minify specific files.

I can disable minification for all files with optimize: 'none' option. But I don't know how to disable it for a single file.

  options: {                                        
      // Do not minify these files: 
      // 'jquery'
      optimize: 'none', // disables minification for all files
    }

I still want the file to be included in the final merged file (unlike empty: http://requirejs.org/docs/optimization.html#empty ), just not passed into uglify.js

basarat
  • 261,912
  • 58
  • 460
  • 511

1 Answers1

1

In the absence of a configuration option to disable minification, I have the file excluded from the merged file generated by requirejs and then manually concatenated.

basarat
  • 261,912
  • 58
  • 460
  • 511