Skip to content

Commit

Permalink
sets default addon support to false
Browse files Browse the repository at this point in the history
  • Loading branch information
Travis Peterson committed Mar 19, 2016
1 parent f5eb6ec commit cee0130
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ Emberate exports a function with the following signature: `emberate(path, option
- resolverPath - require path for a custom Resolver. Defaults to the most current version of [ember-cli's resolver](https://github.com/ember-cli/ember-resolver) - *advanced option, only override if needed*
- debugAdapterPath - require path for a custom debug Adapter, defaults to the current version included with [ember-cli's resolver](https://github.com/ember-cli/ember-resolver).
- addonPath - `emberate-addons` by default, the path that ember addons will be installed into.
- addonSupport - `true` by default, set to false to disable addon support
- addonSupport - `false` by default, set to true to enable addon support
* __callback__ - optional, returns once done writing, if used _outPath_ option above.

The callback is only fired if you specify `outPath` in the options hash, e.g.
Expand Down
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module.exports = function (rootPath, userOptions, templatePath) {
appName: 'App',
templatePath: defaultPath,
addonPath: 'emberate-addons',
addonSupport: true,
addonSupport: false,
modulePrefix: 'app',
debug: true,
debugAdapterPath: 'emberate/vendor/container-debug-adapter.js',
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "emberate",
"description": "helper for using emberjs with commonjs modules",
"version": "3.1.1",
"version": "3.2.0",
"license": "MIT",
"main": "./lib",
"homepage": "https://github.com/AppGeo/emberate",
Expand Down
7 changes: 4 additions & 3 deletions test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var podsCustomStructure = path.join(__dirname, 'structures', 'pods-custom');
test('creates expected output', function (t) {
var generatedFile = path.join(__dirname, 'structures', 'all', '.index.js');
var expectedFile = path.join(__dirname, 'structures', 'all-structures.js');
var instance = emberate(allStructure).pipe(fs.createWriteStream(generatedFile));
var instance = emberate(allStructure, {addonSupport: true}).pipe(fs.createWriteStream(generatedFile));

instance.on('finish', function () {
fs.readFile(generatedFile, function (err, data) {
Expand All @@ -28,7 +28,8 @@ test('creates expected output with callback', function (t) {
var generatedFile = path.join(__dirname, 'structures', 'all', '.index.js');
var expectedFile = path.join(__dirname, 'structures', 'all-structures.js');
var instance = emberate(allStructure, {
outPath: generatedFile
outPath: generatedFile,
addonSupport: true
}, function () {
fs.readFile(generatedFile, function (err, data) {
fs.readFile(expectedFile, function (err, expected){
Expand Down Expand Up @@ -114,7 +115,7 @@ var testFiles = [

test('transpiles broken addon import statements', function(t) {
var generatedFile = path.resolve('emberate-addons/ember-named-yields/addon/components/block-for/component.js');
var instance = emberate(allStructure);
var instance = emberate(allStructure, {addonSupport: true});
var parseOpts = {
ecmaVersion: 6,
sourceType: "module"
Expand Down

0 comments on commit cee0130

Please sign in to comment.