ember-cli-rails 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +39 -15
- data/lib/ember-cli-rails.rb +1 -1
- data/lib/ember-cli/railtie.rb +1 -1
- data/lib/ember-cli/version.rb +1 -1
- 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: fd138b5cec9d03c0f000ee67ff10f619149621f2
|
4
|
+
data.tar.gz: 4ea97ed5ab28d9bfc8ef9cd7ccca5da187cbb67e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec01c1f6f77d4be06792d0a7e0e64cb0b635bf61e0dfb17439b506e69319fa808aed7816be0d2281a901b5dea28d5453a3563ad8aeb4b172a869b2d2f2d80367
|
7
|
+
data.tar.gz: 1255243bed0ad2743300013fe5908efecfd0d2cf42d3c2eb64aa492a79deb0c3c9c2224dffa809c84adeb41b55119040ff18daeb1d918308cb334deb8d320044
|
data/README.md
CHANGED
@@ -1,12 +1,25 @@
|
|
1
1
|
# EmberCLI Rails
|
2
2
|
|
3
|
-
EmberCLI Rails is an integration story between (surprise suprise) EmberCLI and
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
3
|
+
EmberCLI Rails is an integration story between (surprise suprise) EmberCLI and
|
4
|
+
Rails. It is designed to provide an easy way to organize your Rails backed
|
5
|
+
EmberCLI application with a specific focus on upgradeability. Rails and Ember
|
6
|
+
[slash EmberCLI] are maintained by different teams with different goals. As
|
7
|
+
such, we believe that it is important to ensure smooth upgrading of both
|
8
|
+
aspects of your application.
|
9
|
+
|
10
|
+
A large contingent of Ember developers use Rails. And Rails is awesome. With
|
11
|
+
the upcoming changes to Ember 2.0 and the Ember community's desire to unify
|
12
|
+
around EmberCLI it is now more important than ever to ensure that Rails and
|
13
|
+
EmberCLI can coexist and development still be fun!
|
14
|
+
|
15
|
+
To this end we have created a minimum set of features (which we will outline
|
16
|
+
below) to allow you keep your Rails workflow while minimizing the risk of
|
17
|
+
upgrade pain with your Ember build tools.
|
18
|
+
|
19
|
+
For example, end-to-end tests with frameworks like Cucumber should just work.
|
20
|
+
You should still be able leverage the asset pipeline, and all the conveniences
|
21
|
+
that Rails offers. And you should get all the new goodies like ES6 modules and
|
22
|
+
EmberCLI addons too! Without further ado, let's get in there!
|
10
23
|
|
11
24
|
## Installation
|
12
25
|
|
@@ -16,7 +29,8 @@ Firstly, you'll have to include the gem in your `Gemfile` and `bundle install`
|
|
16
29
|
gem "ember-cli-rails"
|
17
30
|
```
|
18
31
|
|
19
|
-
Then you'll want to configure your installation by adding an `ember.rb`
|
32
|
+
Then you'll want to configure your installation by adding an `ember.rb`
|
33
|
+
initializer. There is a generator to guide you, run:
|
20
34
|
|
21
35
|
```shell
|
22
36
|
rails generate ember_cli:init
|
@@ -32,9 +46,11 @@ end
|
|
32
46
|
|
33
47
|
##### options
|
34
48
|
|
35
|
-
- app - this represents the name of the ember cli application. The presumed
|
49
|
+
- app - this represents the name of the ember cli application. The presumed
|
50
|
+
path of which would be `Rails.root.join('app', <your-appname>)`
|
36
51
|
|
37
|
-
- path - used if you need to override the default path (mentioned above)
|
52
|
+
- path - used if you need to override the default path (mentioned above).
|
53
|
+
Example usage:
|
38
54
|
|
39
55
|
```ruby
|
40
56
|
EmberCLI.configure do |c|
|
@@ -42,7 +58,9 @@ EmberCLI.configure do |c|
|
|
42
58
|
end
|
43
59
|
```
|
44
60
|
|
45
|
-
Once you've updated your initializer to taste, you need to tell EmberCLI that
|
61
|
+
Once you've updated your initializer to taste, you need to tell EmberCLI that
|
62
|
+
you want the meta tag to be served in your javascript. Open up your
|
63
|
+
`Brocfile.js` inside your EmberCLI app and add `{storeConfigInMeta: false}`.
|
46
64
|
|
47
65
|
It should look something like this (if you've left it unchanged):
|
48
66
|
|
@@ -58,7 +76,8 @@ And that's it!
|
|
58
76
|
|
59
77
|
### Multiple EmberCLI apps
|
60
78
|
|
61
|
-
In the initializer you may specify multiple EmberCLI apps, each of which can be
|
79
|
+
In the initializer you may specify multiple EmberCLI apps, each of which can be
|
80
|
+
referenced with the view helper independently. You'd accomplish this like so:
|
62
81
|
|
63
82
|
```ruby
|
64
83
|
EmberCLI.configure do |c|
|
@@ -69,17 +88,22 @@ end
|
|
69
88
|
|
70
89
|
## Usage
|
71
90
|
|
72
|
-
In order to load your EmberCLI generated app you need only include the
|
91
|
+
In order to load your EmberCLI generated app you need only include the
|
92
|
+
javscript tags on the page you'd like the Ember app to appear:
|
73
93
|
|
74
94
|
```erb
|
75
|
-
<%=
|
95
|
+
<%= include_ember_script_tags :frontend %>
|
76
96
|
```
|
77
97
|
|
78
98
|
Your Ember application will be served now.
|
79
99
|
|
80
100
|
## Additional Information
|
81
101
|
|
82
|
-
EmberCLI Rails runs `ember build` with the `--output-path` and `--watch` flags
|
102
|
+
EmberCLI Rails runs `ember build` with the `--output-path` and `--watch` flags
|
103
|
+
on. The `--watch` flag sets tells EmberCLI to watch for file system events and
|
104
|
+
rebuild when an EmberCLI file is changed. The `--output-path` flag specifies
|
105
|
+
where the distribution files will be put. EmberCLI Rails does some fancy stuff
|
106
|
+
to get it into your asset path without polluting your git history.
|
83
107
|
|
84
108
|
## Contributing
|
85
109
|
|
data/lib/ember-cli-rails.rb
CHANGED
data/lib/ember-cli/railtie.rb
CHANGED
data/lib/ember-cli/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ember-cli-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pavel Pravosud
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-12-
|
12
|
+
date: 2014-12-04 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: railties
|