Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve AMD module discovery. Better support for Engines and Addons. #37

Merged
merged 7 commits into from
Feb 22, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## [1.1.0]
- Improved thw way AMD modules are discovered. Build time should be fatser.
- Support for Engines and Addons.
- amdModulePaths is not necessary anymore as the AMD modules are dicovered on the built code.

## [1.0.0]
- Based on Ember 2.18
- Changed the way we find and replace the conflicting Ember require and define function/references. Instead of using a regex and replacing string occurences, we are now using esprima to replace Identifiers and Literals.
Expand Down
16 changes: 6 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
# Ember-cli-amd

The Ember loader is conflicting with the AMD loader. The Ember loader is not async and doesn't comply with the RequireJS or AMD specs.

This addon will:
* update the code generated by Ember to avoid conflicts with the AMD loader
* load any pure AMD modules found in the code first
* load the Ember code as an AMD module
* reference the true AMD modules inside the Ember loader
* Update the code generated by Ember to avoid conflicts with the AMD loader
* Update the index.html:
* load any pure AMD modules found in the code first using the AMD loader
* load the Ember code as AMD modules (app and vendor)
* reference the AMD modules inside the Ember loader

[View it live](http://esri.github.io/ember-cli-amd/) using the [ArcGIS API for JavaScript](https://developers.arcgis.com/javascript/).

Expand All @@ -15,7 +17,6 @@ This addon will:
* Uses the [RequireJS Optimizer](http://requirejs.org/docs/optimization.html) for fast builds while coding.

## Installation

* `git clone` this repository
* `npm install`

Expand Down Expand Up @@ -55,11 +56,6 @@ var app = new EmberApp({
locale: 'en-us',
// Optional: Will create a dependencies.txt that will list all the AMD dependencies in the application, default is false
outputDependencyList: true,
// Optional: Causes the findAMDModules method to search these paths in addition to 'app'
// All paths are relative to the project root.
// If using this in an addon, you can use 'addon'
// If you need amd modules discovered from an ember addon dependency, you can use 'node_modules/addon-name/addon'
amdModulePaths: [],
// Optional, defaults to true. If `true` the amd-start and amd-config scripts will be inlined into index.html.
// This saves xhrs during application boot, so unless you are generating your index.html file on the fly (i.e. from node or rails)
// you should likely enable this.
Expand Down