sprockets-dotjs 3.0.1 → 3.0.2

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Compile doT.JS templates (`jst.djs` extension) into rails `JST` env variable
4
4
 
5
- Supports doT.JS partial feature by using Sprocket's `depend_on` directive
5
+ Supports doT.JS partial feature by using Sprocket's `depend_on_asset` directive (support recursive partial dependency in `3.0`)
6
6
 
7
7
  ## Installation
8
8
 
@@ -16,7 +16,7 @@ And then execute:
16
16
 
17
17
  ## Usage
18
18
 
19
- Put doT.js template files inside the `assets/javascript` directory and generate them by calling `JST["#{file_path}"]()`
19
+ Put doT.js template files inside the `assets/javascript` directory and use them by calling `JST["#{file_path}"](context)`
20
20
 
21
21
  ## Contributing
22
22
 
@@ -2,7 +2,7 @@ function encodeHTMLSource() {
2
2
  var encodeHTMLRules = { "&": "&#38;", "<": "&#60;", ">": "&#62;", '"': '&#34;', "'": '&#39;', "/": '&#47;'},
3
3
  matchHTML = /&(?!#?\w+;)|<|>|"|'|\//g;
4
4
  return function() {
5
- return this ? this.replace(matchHTML, function(m) {return encodeHTMLRules[m] || m; }).replace(/\n/,'<br>') : this;
5
+ return this ? this.replace(matchHTML, function(m) {return encodeHTMLRules[m] || m; }) : this;
6
6
  };
7
7
  }
8
- String.prototype.encodeHTML = encodeHTMLSource();
8
+ String.prototype.encodeHTML = encodeHTMLSource();
@@ -1,5 +1,5 @@
1
1
  module Sprockets
2
2
  module Dotjs
3
- VERSION = "3.0.1"
3
+ VERSION = "3.0.2"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sprockets-dotjs
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1
4
+ version: 3.0.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-04-09 00:00:00.000000000 Z
12
+ date: 2013-04-10 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: sprockets