-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
196 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,26 @@ | ||
var EnactFrameworkRefPlugin = require('./util/EnactFrameworkRefPlugin') | ||
var | ||
fs = require('fs'), | ||
exists = require('path-exists').sync, | ||
EnactFrameworkRefPlugin = require('./util/EnactFrameworkRefPlugin'); | ||
|
||
module.exports = function(config, opts) { | ||
var resBundle = './resources/ilibmanifest.json'; | ||
if(!exists(resBundle)) { | ||
if(!exists('./resources')) { | ||
fs.mkdirSync('./resources'); | ||
} | ||
fs.writeFileSync(resBundle, JSON.stringify({files:[]}, null, '\t'), {encoding:'utf8'}); | ||
} | ||
config.entry.main.splice(config.entry.main.length-1, 0, resBundle); | ||
|
||
// Add the reference plugin so the app uses the external framework | ||
config.plugins.push(new EnactFrameworkRefPlugin({ | ||
name: 'enact_framework', | ||
libraries: ['@enact', 'react', 'react-dom'], | ||
external: { | ||
path: opts.externals, | ||
inject: opts['externals-inject'] || opts.inject | ||
inject: opts['externals-inject'] || opts.inject, | ||
snapshot: opts.snapshot | ||
} | ||
})); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.