ember-cli-assets 0.0.15 → 0.0.16
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ember/cli/assets/version.rb +1 -1
- data/lib/ember/cli/resolver.rb +1 -1
- data/vendor/assets/ember/resolver.js +19 -9
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0ace9f80463a9cdadad58921de5b2fd494cf3138
|
4
|
+
data.tar.gz: ad57f2ea5ba67faca424b9a77f9d0b6c96ab18b9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bc26f7b57ac9d29a30e3f0fd9fb39171ee52a2359245c4a4d74f471459f26b1660d426546e816c170f1ab690bc56ee8967afeb03e7baf5857d3d2ad82cca6a5d
|
7
|
+
data.tar.gz: a92a1776db105971fe1921dc9a0795b8327bbb4098e4c59217981773d2fd59d0e5dda8a4eafe0c289b7e3043c0c4685ce93a354f0996a276786ddae8b9b94b32
|
data/lib/ember/cli/resolver.rb
CHANGED
@@ -371,19 +371,29 @@ define("ember/resolver",
|
|
371
371
|
|
372
372
|
translateToContainerFullname: function(type, moduleName) {
|
373
373
|
var prefix = this.prefix({ type: type });
|
374
|
-
var pluralizedType = this.pluralize(type);
|
375
|
-
var nonPodRegExp = new RegExp('^' + prefix + '/' + pluralizedType + '/(.+)$');
|
376
|
-
var podRegExp = new RegExp('^' + prefix + '/(.+)/' + type + '$');
|
377
|
-
var matches;
|
378
|
-
|
379
374
|
|
380
|
-
|
381
|
-
|
375
|
+
// Note: using string manipulation here rather than regexes for better performance.
|
376
|
+
// pod modules
|
377
|
+
// '^' + prefix + '/(.+)/' + type + '$'
|
378
|
+
var podPrefix = prefix + '/';
|
379
|
+
var podSuffix = '/' + type;
|
380
|
+
var start = moduleName.indexOf(podPrefix);
|
381
|
+
var end = moduleName.indexOf(podSuffix);
|
382
|
+
|
383
|
+
if (start === 0 && end === (moduleName.length - podSuffix.length) &&
|
384
|
+
moduleName.length > (podPrefix.length + podSuffix.length)) {
|
385
|
+
return type + ':' + moduleName.slice(start + podPrefix.length, end);
|
382
386
|
}
|
383
387
|
|
384
|
-
|
385
|
-
|
388
|
+
// non-pod modules
|
389
|
+
// '^' + prefix + '/' + pluralizedType + '/(.+)$'
|
390
|
+
var pluralizedType = this.pluralize(type);
|
391
|
+
var nonPodPrefix = prefix + '/' + pluralizedType + '/';
|
392
|
+
|
393
|
+
if (moduleName.indexOf(nonPodPrefix) === 0 && moduleName.length > nonPodPrefix.length) {
|
394
|
+
return type + ':' + moduleName.slice(nonPodPrefix.length);
|
386
395
|
}
|
396
|
+
|
387
397
|
},
|
388
398
|
|
389
399
|
_extractDefaultExport: function(normalizedModuleName) {
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ember-cli-assets
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.16
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ryunosuke SATO
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-09-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|