backbars 0.0.3 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +45 -3
- data/app/assets/javascripts/backbone.js +1608 -0
- data/app/assets/javascripts/underscore.js +1343 -0
- data/lib/backbars/version.rb +1 -1
- data/lib/backbars.rb +2 -1
- data/lib/generators/backbars/backbars_generator.rb +0 -3
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2611ad0142aa7eb762388555e036d34fac449d44
|
4
|
+
data.tar.gz: 05cc789713cbf6895e858ffa8596a8950bc4d095
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 89be908e997f212d9887852acc928991151ad86eb10fe01d8429d4b2b0c4fa9a1644bc931a6e97080d99620cd62ccd57eefba8ba32ef8095ed5fdbbfaff215f1
|
7
|
+
data.tar.gz: a80ec58469bef751e6dc91a51d65b467575861a4607cb027a2be99e81c97bfdf937d10aa64a8de13f150136c14b8af9161589e843e40a4cbf595785e3807640b
|
data/README.md
CHANGED
@@ -1,6 +1,41 @@
|
|
1
1
|
# Backbars
|
2
2
|
|
3
|
-
|
3
|
+
[![Gem Version](https://badge.fury.io/rb/backbars.svg)](http://badge.fury.io/rb/backbars)
|
4
|
+
|
5
|
+
Backbars is a gem to generate a boilerplate setup for using Backbone with Rails. The gem will include __Backbone.js__ (with dependencies) and __Handlebars.js__ for templating. [handlebars_assets](https://github.com/leshill/handlebars_assets) is included for compiling Handlebars templates and to make use of the Asset Pipeline to help keep your templates nice and organized. It also builds a simple directory structure to help organize your Backbone files and templates.
|
6
|
+
|
7
|
+
```
|
8
|
+
app
|
9
|
+
|_assets
|
10
|
+
|_javascripts
|
11
|
+
|_application.js
|
12
|
+
|_backbone
|
13
|
+
| |_routers
|
14
|
+
| |_models
|
15
|
+
| |_collections
|
16
|
+
| |_views
|
17
|
+
|
|
18
|
+
|_templates
|
19
|
+
```
|
20
|
+
|
21
|
+
The following is inserted into your application.js file:
|
22
|
+
```
|
23
|
+
//= require underscore
|
24
|
+
//= require backbone
|
25
|
+
//= require handlebars
|
26
|
+
//= require_tree ./backbone/routers
|
27
|
+
//= require_tree ./backbone/models
|
28
|
+
//= require_tree ./backbone/collections
|
29
|
+
//= require_tree ./backbone/views
|
30
|
+
//= require_tree ./templates
|
31
|
+
//= require_tree .
|
32
|
+
```
|
33
|
+
|
34
|
+
#### JavaScript Library Versions
|
35
|
+
- Underscore.js (v1.6.0)
|
36
|
+
- Backbone.js (v1.1.2)
|
37
|
+
- Handlebars.js (v1.3.0)
|
38
|
+
|
4
39
|
|
5
40
|
## Installation
|
6
41
|
|
@@ -8,17 +43,24 @@ Add this line to your application's Gemfile:
|
|
8
43
|
|
9
44
|
gem 'backbars'
|
10
45
|
|
11
|
-
|
46
|
+
Then execute:
|
12
47
|
|
13
48
|
$ bundle
|
14
49
|
|
50
|
+
And then execute:
|
51
|
+
|
52
|
+
$ rails generate backbars
|
53
|
+
|
54
|
+
_If you have an issue with the generator stalling you should run the following command, then re-run the generator_
|
55
|
+
|
56
|
+
$ spring stop
|
57
|
+
|
15
58
|
Or install it yourself as:
|
16
59
|
|
17
60
|
$ gem install backbars
|
18
61
|
|
19
62
|
## Usage
|
20
63
|
|
21
|
-
TODO: Write usage instructions here
|
22
64
|
|
23
65
|
## Contributing
|
24
66
|
|