turbostreamer 1.9.0 → 1.10.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5560f65eafd9983a08cc6cd0745101c0909d923dbca5cb012b9f5b884446de37
4
- data.tar.gz: 14697af3049c50e3504e46e66a0209cf694c450ba95ac84fa4b723038126460d
3
+ metadata.gz: 63f1e21caf6c87b095cbd4528226ebbc0489dc7f58ef6de192ed222b1920863e
4
+ data.tar.gz: d7e9e7237f6fe49b46c114a39da1b6983db8cdc758a4b0d10cb9ce97d65a7ad4
5
5
  SHA512:
6
- metadata.gz: 894d614c59b3b002130c00519a5b687cc0814c4bd5358c033858f590f3a5e6082dec8b220cba91b59114eb1236129f1f166f27eb276c4ddbfab7bd796e81bacf
7
- data.tar.gz: f0d5a68cf0e48ce0e73f50b879d69dc21fcdd6ed35110b4d8498255eeb33f35fb1b1326ff13619dee729adaca4a79ed787ced23f471931112bef5cf2657c1c03
6
+ metadata.gz: 69a4204a0598eb92fae7a08c1385241b0f648998eb5f6762c42bd61c8ded3689078ed1930b06e15383fc5ab744f5e1f8b85b6efd2eda58cbc125831683a8ca30
7
+ data.tar.gz: e8002ae1e4369b59071dff8a74f3f57d2e51d63c242c86023e174c6fb00b74b9777defa68e5e1241ace35bbf24e4a92d6dd275870155b18e4438d732e5807896
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # TurboStreamer [![Build Status](https://api.travis-ci.org/malomalo/turbostreamer.svg)](https://travis-ci.org/malomalo/turbostreamer)
1
+ # TurboStreamer
2
2
 
3
3
  TurboStreamer gives you a simple DSL for generating JSON that beats massaging giant
4
4
  hash structures. This is particularly helpful when the generation process is
@@ -299,7 +299,8 @@ TurboStreamer.encode(encoder: TurboStreamer::WankelEncoder)
299
299
  TurboStreamer.encode(encoder: MyEncoder)
300
300
  ```
301
301
 
302
- # Setting the default encoder and options
302
+ Setting the default encoder and options
303
+ ---------------------------------------
303
304
  If you need explicitly set the default:
304
305
 
305
306
  ```ruby
@@ -339,6 +340,20 @@ All backends must have the following functions:
339
340
  - `inject(string)` Inject a (usually cached) string into the output; instering any delimiters as needed.
340
341
  - `capture(&block)` Capture the output of the block (w/o any delimiters)
341
342
 
343
+ Benchmark
344
+ ---------
345
+ `gnuplot` is required to run benchmark, to install:
346
+ - `brew install gnuplot` (MacOS)
347
+
348
+ `yajl` is required to install a development dependency [`wankel`](https://github.com/malomalo/wankel), to install:
349
+ - `brew install yajl` (MacOS)
350
+
351
+ To run benchmark: `bundle exec rake performance`
352
+
353
+ This will produce 2 graph images on in folders
354
+ - `performance/dirk`
355
+ - `performance/rolftimmermans`
356
+
342
357
  Special Thanks & Contributors
343
358
  -----------------------------
344
359
 
@@ -215,7 +215,7 @@ class TurboStreamer::Template < TurboStreamer
215
215
  if @context.respond_to?(:cache_fragment_name)
216
216
  # Current compatibility, fragment_name_with_digest is private again and cache_fragment_name
217
217
  # should be used instead.
218
- @context.cache_fragment_name(key, options)
218
+ @context.cache_fragment_name(key, **options)
219
219
  elsif @context.respond_to?(:fragment_name_with_digest)
220
220
  # Backwards compatibility for period of time when fragment_name_with_digest was made public.
221
221
  @context.fragment_name_with_digest(key)
@@ -1,3 +1,3 @@
1
1
  class TurboStreamer
2
- VERSION = '1.9.0'
2
+ VERSION = '1.10.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: turbostreamer
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.0
4
+ version: 1.10.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jon Bracy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-24 00:00:00.000000000 Z
11
+ date: 2022-09-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -192,6 +192,20 @@ dependencies:
192
192
  - - ">="
193
193
  - !ruby/object:Gem::Version
194
194
  version: '0'
195
+ - !ruby/object:Gem::Dependency
196
+ name: multi_json
197
+ requirement: !ruby/object:Gem::Requirement
198
+ requirements:
199
+ - - ">="
200
+ - !ruby/object:Gem::Version
201
+ version: '0'
202
+ type: :development
203
+ prerelease: false
204
+ version_requirements: !ruby/object:Gem::Requirement
205
+ requirements:
206
+ - - ">="
207
+ - !ruby/object:Gem::Version
208
+ version: '0'
195
209
  description:
196
210
  email:
197
211
  - jonbracy@gmail.com
@@ -234,7 +248,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
234
248
  - !ruby/object:Gem::Version
235
249
  version: '0'
236
250
  requirements: []
237
- rubygems_version: 3.1.2
251
+ rubygems_version: 3.2.22
238
252
  signing_key:
239
253
  specification_version: 4
240
254
  summary: Stream JSON via a Builder-style DSL