Skip to content

Commit

Permalink
Merge pull request #14853 from Turbo87/handlebars
Browse files Browse the repository at this point in the history
Update "handlebars" to v4.0.6
  • Loading branch information
stefanpenner authored Feb 25, 2017
2 parents 1c4bbba + 41a7e72 commit 0cda591
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
9 changes: 6 additions & 3 deletions ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -274,13 +274,16 @@ function qunit() {
}

function handlebarsFix() {
var HANDLEBARS_UTIL = /\/utils.js$/;
var HANDLEBARS_PARSER = /\/parser.js$/;
return {
load: function(id) {
if (HANDLEBARS_UTIL.test(id)) {
if (HANDLEBARS_PARSER.test(id)) {
var code = fs.readFileSync(id, 'utf8');
return {
code: code.replace(/export var isFunction/, 'export { isFunction }'),
code: code
.replace('exports.__esModule = true;', '')
.replace('exports[\'default\'] = handlebars;', 'export default handlebars;'),

map: { mappings: null }
};
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
"ember-cli-test-info": "^1.0.0",
"ember-cli-valid-component-name": "^1.0.0",
"ember-cli-version-checker": "^1.1.7",
"handlebars": "~3",
"handlebars": "^4.0.6",
"jquery": "^3.1.1",
"resolve": "^1.1.7",
"rsvp": "^3.3.3",
Expand Down
4 changes: 2 additions & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2865,7 +2865,7 @@ growly@^1.2.0:
version "1.3.0"
resolved "https://registry.yarnpkg.com/growly/-/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081"

handlebars@^3.0.1, handlebars@^3.0.3, handlebars@~3:
handlebars@^3.0.1, handlebars@^3.0.3:
version "3.0.3"
resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-3.0.3.tgz#0e09651a2f0fb3c949160583710d551f92e6d2ad"
dependencies:
Expand All @@ -2874,7 +2874,7 @@ handlebars@^3.0.1, handlebars@^3.0.3, handlebars@~3:
optionalDependencies:
uglify-js "~2.3"

handlebars@^4.0.4:
handlebars@^4.0.4, handlebars@^4.0.6:
version "4.0.6"
resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.0.6.tgz#2ce4484850537f9c97a8026d5399b935c4ed4ed7"
dependencies:
Expand Down

0 comments on commit 0cda591

Please sign in to comment.