hyperloop-config 0.9.2 → 0.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +9 -10
- data/hyperloop-config.gemspec +2 -1
- data/lib/hyperloop-config.rb +1 -0
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2bdd914b93f5363a48176e7f3bff4bc595c8f4c9
|
4
|
+
data.tar.gz: ba3f7e86fe4cf8ad2262c45e9fe73a71b07d3592
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7c59ea750f2be46a2b593a80510bff1c17c676843b6c67f1447dc1ba4a4eabbdeb9cd6323ed7a4e232245adb0a6c9ccc8a2be02c77abb246cd03d699a7535b00
|
7
|
+
data.tar.gz: d2916d97f7f215a836ce5752427ad913d948d7cdb3c14b1fd98d3c5b120f4a3a14e1b13dd9a068928fa20c8f8ef08543cca22e8d2dfd953ce1b3b7ef4125c240
|
data/README.md
CHANGED
@@ -6,20 +6,19 @@ To indicate gems to be autoloaded on client side:
|
|
6
6
|
|
7
7
|
```ruby
|
8
8
|
require 'hyperloop-config'
|
9
|
-
Hyperloop.
|
10
|
-
Hyperloop.
|
11
|
-
Hyperloop.
|
12
|
-
Hyperloop.
|
13
|
-
Hyperloop.
|
14
|
-
Hyperloop.
|
9
|
+
Hyperloop.import 'my-gem-name'
|
10
|
+
Hyperloop.imports 'my-gem-name' # same as above
|
11
|
+
Hyperloop.import 'my-gem-name', server_only: true
|
12
|
+
Hyperloop.import 'my-gem-name', client_only: true
|
13
|
+
Hyperloop.import 'path', tree: true # same as saying require_tree 'path' in a manifest file
|
14
|
+
Hyperloop.import_tree 'path' # same as above
|
15
|
+
Hyperloop.import 'asset_name' # same as saying require 'asset_name' in a manifest file
|
15
16
|
```
|
16
17
|
|
17
|
-
|
18
|
-
|
19
|
-
Once a gem file spec does a `Hyperloop.require_gem` the listed gem will be automatically added to the `hyperloop-loader` manifest. This means all you do is add a gem
|
18
|
+
Once a gem file spec does a `Hyperloop.import` the listed gem will be automatically added to the `hyperloop-loader` manifest. This means all you do is add a gem
|
20
19
|
to rails, and it will get sent on to the client (plus any other dependencies you care to require.)
|
21
20
|
|
22
|
-
The require method can be used in the hyperloop initializer as well to add code to the manifest (i.e. add a gem to that is not using Hyperloop.
|
21
|
+
The require method can be used in the hyperloop initializer as well to add code to the manifest (i.e. add a gem to that is not using Hyperloop.import)
|
23
22
|
|
24
23
|
To define an initializer:
|
25
24
|
|
data/hyperloop-config.gemspec
CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = "hyperloop-config"
|
7
|
-
spec.version = "0.9.
|
7
|
+
spec.version = "0.9.3"
|
8
8
|
spec.authors = ["catmando"]
|
9
9
|
spec.email = ["mitch@catprint.com"]
|
10
10
|
|
@@ -18,6 +18,7 @@ Gem::Specification.new do |spec|
|
|
18
18
|
spec.require_paths = ["lib"]
|
19
19
|
|
20
20
|
spec.add_dependency 'opal'
|
21
|
+
spec.add_dependency 'opal-browser'
|
21
22
|
|
22
23
|
spec.add_development_dependency "bundler", "~> 1.12"
|
23
24
|
spec.add_development_dependency "rake", "~> 10.0"
|
data/lib/hyperloop-config.rb
CHANGED
@@ -9,6 +9,7 @@ else
|
|
9
9
|
require 'hyperloop/on_client'
|
10
10
|
require 'hyperloop/rail_tie' if defined? Rails
|
11
11
|
Hyperloop.import 'opal', gem: true
|
12
|
+
Hyperloop.import 'browser', client_only: true
|
12
13
|
Hyperloop.import 'hyperloop-config', gem: true
|
13
14
|
Opal.append_path(File.expand_path('../', __FILE__).untaint)
|
14
15
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hyperloop-config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- catmando
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03-
|
11
|
+
date: 2017-03-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: opal
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: opal-browser
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: bundler
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|