How can I tell Brunch not to concatenate javascrip

2019-06-01 07:09发布

问题:

Does anyone know how to configure Brunch not to concatenate javascript files in the local build?

I want the javascript files copied straight over so that I do not have one large javascript file when debugging.

Here's my current brunch-config.coffee file:

exports.config =
  conventions: ignored: /.+\.spec\.js/
  files:
    javascripts:
      joinTo:
        'js/app.js': /^app/
        'js/vendor.js': /^(vendor|bower_components)/
    stylesheets:
      joinTo: 
        'css/common.css': /^app/
    templates:
      joinTo:
        'js/templates.js': /^app/

回答1:

  1. Place your javascript files into app/assets
  2. Remove javascripts and templates from your brunch config.

That should just copy them over as-is.



回答2:

Per Paul's comment, it is not possible yet to not combine js files when building locally. Thanks Paul



标签: brunch