ember-cli-htmlbars
Advanced tools
Comparing version 4.4.0 to 4.4.1
@@ -0,1 +1,9 @@ | ||
## v4.4.1 (2021-02-05) | ||
#### :rocket: Enhancement | ||
* [#598](https://github.com/ember-cli/ember-cli-htmlbars/pull/657) Make `cacheKey` calculation lazy ([@krisselden](https://github.com/krisselden)) | ||
#### Committers: 1 | ||
- Kris Selden ([@krisselden](https://github.com/krisselden)) | ||
## v4.4.0 (2020-08-11) | ||
@@ -2,0 +10,0 @@ |
@@ -62,8 +62,16 @@ 'use strict'; | ||
// parallelBabelInfo will not be used in the cache unless it is explicitly included | ||
let cacheKey = makeCacheKey(templateCompilerPath, pluginInfo, JSON.stringify(parallelBabelInfo)); | ||
let cacheKey; | ||
return { | ||
_parallelBabel: parallelBabelInfo, | ||
baseDir: () => __dirname, | ||
cacheKey: () => cacheKey, | ||
cacheKey: () => { | ||
if (cacheKey === undefined) { | ||
cacheKey = makeCacheKey( | ||
templateCompilerPath, | ||
pluginInfo, | ||
JSON.stringify(parallelBabelInfo) | ||
); | ||
} | ||
return cacheKey; | ||
}, | ||
}; | ||
@@ -192,4 +200,2 @@ } | ||
let cacheKey = makeCacheKey(templateCompilerPath, pluginInfo); | ||
registerPlugins(templateCompiler, { | ||
@@ -201,4 +207,11 @@ ast: pluginInfo.plugins, | ||
precompile.baseDir = () => path.resolve(__dirname, '..'); | ||
precompile.cacheKey = () => cacheKey; | ||
let cacheKey; | ||
precompile.cacheKey = () => { | ||
if (cacheKey === undefined) { | ||
cacheKey = makeCacheKey(templateCompilerPath, pluginInfo); | ||
} | ||
cacheKey; | ||
}; | ||
let plugin = [ | ||
@@ -205,0 +218,0 @@ require.resolve('babel-plugin-htmlbars-inline-precompile'), |
{ | ||
"name": "ember-cli-htmlbars", | ||
"version": "4.4.0", | ||
"version": "4.4.1", | ||
"description": "A library for adding htmlbars to ember CLI", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
55385
964