Skip to content

Commit

Permalink
Merge branch 'configure-loader' of https://github.com/Jenselme/cli in…
Browse files Browse the repository at this point in the history
…to Jenselme-configure-loader
  • Loading branch information
EisenbergEffect committed Sep 16, 2016
2 parents d21f81b + ce9c78f commit 8e27d77
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,23 @@ Sometimes you can't get a library to work with the module loading system. That's
}
```

#### Configuring the loader

You can configure the loader by adding a `config` key to `build.loader` with the options you want to add. For instance, if you want to increase the timeout for requirejs, you would do this:

```
"build": {
"loader": {
"type": "require",
"configTarget": "vendor-bundle.js",
"includeBundleMetadataInConfig": "auto",
"config": {
"waitSeconds": 60
}
}
}
```

## Styling your Application

There are many ways to style components in Aurelia. The CLI sets up your project to only process styles inside your application's `src` folder. Those styles can then be imported into a view using Aurelia's `require` element.
Expand Down
1 change: 1 addition & 0 deletions lib/build/bundler.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ exports.Bundler = class {
stubModules: [],
shim: {}
};
Object.assign(this.loaderConfig, this.project.build.loader.config);

this.loaderOptions.plugins = (this.loaderOptions.plugins || []).map(x => {
let plugin = new LoaderPlugin(this, x);
Expand Down

0 comments on commit 8e27d77

Please sign in to comment.