benchmark_to_js 0.1.0 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +5 -3
- data/lib/benchmark_to_js/configuration.rb +2 -2
- data/lib/benchmark_to_js/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8b341053fc099c0d918520b916f88513ca8e0e62
|
4
|
+
data.tar.gz: 8e282f9a88caa39d22fb0ea772e15a0e1f4cb227
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 09792bcdad9795450fca1f7491bc79288ef6f138186daba87576c6df14146b8b567ea706bfbc87b76d5f780ce309ba9c714ab162859ea95ecedf64ef521443fa
|
7
|
+
data.tar.gz: 6a54c86e03e5249fb40db4969577f6ff2bcf2e76314559f053046fa45a4097118ed68c75df51fa4504bf18c01eeb6e6f67e7d2ecf71b6a926a2ea57066ddb6c2
|
data/README.md
CHANGED
@@ -32,8 +32,8 @@ BenchmarkToJs.configure do |config|
|
|
32
32
|
|
33
33
|
# the following only apply if pretty if set to true
|
34
34
|
# minimum milliseconds before time is highlighted in respective colour
|
35
|
-
config.red_threshold = 1000 # default
|
36
|
-
config.orange_threshold = 200 # default
|
35
|
+
config.red_threshold = 1000 # default 500
|
36
|
+
config.orange_threshold = 200 # default 100
|
37
37
|
end
|
38
38
|
```
|
39
39
|
|
@@ -63,9 +63,11 @@ To use, just wrap a section of a view in a `benchmark_to_js(name)` block, like s
|
|
63
63
|
Both methods will render the content as if it wasn't in the block, and a line will be logged to the Javascript console: `'my content' ran in 123.456ms`.
|
64
64
|
|
65
65
|
If pretty formatting is enabled (it is by default) then your output will look something like this:
|
66
|
+
|
66
67
|

|
67
68
|
|
68
69
|
and if it isn't, well then it will look bland, like this:
|
70
|
+
|
69
71
|

|
70
72
|
|
71
73
|
That's all there is to it!
|
@@ -76,7 +78,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
76
78
|
|
77
79
|
## Contributing
|
78
80
|
|
79
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
81
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/daveallie/benchmark_to_js. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
80
82
|
|
81
83
|
## License
|
82
84
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: benchmark_to_js
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dave Allie
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -81,7 +81,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
81
81
|
version: '0'
|
82
82
|
requirements: []
|
83
83
|
rubyforge_project:
|
84
|
-
rubygems_version: 2.5.1
|
84
|
+
rubygems_version: 2.4.5.1
|
85
85
|
signing_key:
|
86
86
|
specification_version: 4
|
87
87
|
summary: Benchmarks content in views and logs times to JS console.
|