ruby-ejs 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/ruby/ejs/assets/ejs.js +9 -0
  3. metadata +2 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b4cdfc1984dfe0f7075d095ff8db803283877f7a81c3ab63f80f1d0148293bc1
4
- data.tar.gz: 588d1484185dc5a8f0106fed729b4e2c0a740f44313edeccd9206aded072675e
3
+ metadata.gz: 232f0b535162a8e22d9af9531aad70ec430854b1bfbbdf09748cac64169307c8
4
+ data.tar.gz: 6e7a19b04327933e6c56961233cef0635b7c8d8def2d04a845a7b1697862ce07
5
5
  SHA512:
6
- metadata.gz: 937490d4c14a05dff25f1862defa7f62726887cac90d98776a17f205c9b347724003bf1a2be09b66276de2d6f577409f83be3d53e68dab7193db741a214ecc6c
7
- data.tar.gz: 41834e5dddde678ebfd4073658e8e90807362e1b6588b140b74dc54349013265afa687fe3d9f861de08d6bb61487a4f1f139cf59505f30b6265e14af06ed0e6e
6
+ metadata.gz: 29c23c1b84a8ce4383753b7f6ec562fad487c40f3111fb0180a5db51bb0b9a6910dd65fea44b646225042f2f7865758dfc08bdda8737d16f29507380568620e8
7
+ data.tar.gz: 1758fe11dd541ea571a9c6a4a6e804dc06a698cebcebc589b13d42be2ab7dfe6f22d37fa57c47c76f1a0d1c98089a14936efefc548fccc7a5286d6cbf56ce630
@@ -0,0 +1,9 @@
1
+ export function escape(string) {
2
+ if (string !== undefined && string != null) {
3
+ return String(string).replace(/[&<>'"\\/]/g, function (c) {
4
+ return '&#' + c.codePointAt(0) + ';';
5
+ });
6
+ } else {
7
+ return '';
8
+ }
9
+ }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-ejs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Bracy
@@ -91,6 +91,7 @@ files:
91
91
  - README.md
92
92
  - lib/ejs.rb
93
93
  - lib/ruby/ejs.rb
94
+ - lib/ruby/ejs/assets/ejs.js
94
95
  homepage: https://github.com/malomalo/ruby-ejs
95
96
  licenses:
96
97
  - MIT