sprockets-es6 0.7.0 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 07886b86c7623766f35b878a37f92cdb4ef8dea0
4
- data.tar.gz: 6172967581b7b5f245917a91fbefc6c30edd6967
3
+ metadata.gz: 42458dfa4286b86baff1c89837c0318ee5a91f17
4
+ data.tar.gz: 4ec723cb6581c949afdc1016d63e8c22e9bda9d6
5
5
  SHA512:
6
- metadata.gz: cb351b46501d9860d6a85243644498d582abe041f578282ad50de1327db1c583dfb982c9c9f684147163054ca3e0f44d22e06b4544ab933f3201f09596481258
7
- data.tar.gz: 64973184a53d8100ad2150d21a5e0bb4aef011c142fbbd3e68834958eda94d030270e4410a522da6ff4f3bf54736cd9e8c911cb234b943f36c7bf1d7697058eb
6
+ metadata.gz: 27044a4f9818b0728683b4ace7a493ae01508cf5a209f4c16154dbf4431be7d8585e499c03669a686eb189e87f6b85e65deb39b0a943c061efa865b90284ef70
7
+ data.tar.gz: de3718b7a62fe259ca89e68b13879d95292fa68dc7e2e225e3cdfc2a332341e13b56f01cd64362ece05858be8b919bef7e0b98b82cf2a19cc6e7e5d4eb483da2
data/README.md CHANGED
@@ -20,7 +20,7 @@ require 'sprockets/es6'
20
20
  ``` js
21
21
  // app.es6
22
22
 
23
- square = (x) => x * x
23
+ let square = (x) => x * x
24
24
 
25
25
  class Animal {
26
26
  constructor(name) {
@@ -27,14 +27,16 @@ module Sprockets
27
27
  def call(input)
28
28
  data = input[:data]
29
29
  result = input[:cache].fetch(@cache_key + [data]) do
30
- opts = @options.merge(
30
+ opts = {
31
31
  'sourceRoot' => input[:load_path],
32
- 'moduleRoot' => '',
32
+ 'moduleRoot' => nil,
33
33
  'filename' => input[:filename],
34
34
  'filenameRelative' => input[:environment].split_subpath(input[:load_path], input[:filename])
35
- )
35
+ }.merge(@options)
36
36
 
37
- if opts['moduleIds']
37
+ if opts['moduleIds'] && opts['moduleRoot']
38
+ opts['moduleId'] ||= File.join(opts['moduleRoot'], input[:name])
39
+ elsif opts['moduleIds']
38
40
  opts['moduleId'] ||= input[:name]
39
41
  end
40
42
 
@@ -1,5 +1,5 @@
1
1
  module Sprockets
2
2
  class ES6
3
- VERSION = '0.7.0'
3
+ VERSION = '0.8.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sprockets-es6
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.0
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joshua Peek
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-07-14 00:00:00.000000000 Z
11
+ date: 2015-09-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: babel-transpiler
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: babel-source
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 5.8.11
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 5.8.11
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: sprockets
29
43
  requirement: !ruby/object:Gem::Requirement