error_page_assets 0.2 → 0.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c94f48a67e85f4d220fc08f05f865f51acde686c
4
- data.tar.gz: 0e48288914c588abadc2a62f6060a021e3635724
3
+ metadata.gz: 124bf32583398dfd8afad86645d228d7e5552961
4
+ data.tar.gz: e55014a4b7db6f5e65c7ca0da1d0ba090b170544
5
5
  SHA512:
6
- metadata.gz: 9bf39fb7184d1c9eebbc15cbf965439a0088a05f064cb0b1a00e51570ae65a008b771048f7a30b8a4f8d3928bc83a616e6ce02e7867171045bb729bb8daaea46
7
- data.tar.gz: b953fe9850e031dace399c59129b40ab4bab79fc17ea801e53ff34f50ff0a211bad268077f173c432fe9e768f941319e1f0b01ee5d7bfb470ea7c85b6096558a
6
+ metadata.gz: 231d1e42ff25a46877b9474502b8e72767461af1468e902bac02dd04540547d1070c467d714b373d221f2437d108dff823615326c5a6ba800b85460b2608d248
7
+ data.tar.gz: 3da2cc64341c6062ef7d13fd7f0fd8792198cc0cf8240395ba3f9756278b7641ce544bc653afa44a0774e91e1154e5761b4b5713d40b2dd4580796c9b1f69dcd
data/README.md CHANGED
@@ -1,14 +1,14 @@
1
1
  # Error Page Assets
2
2
 
3
- Let the asset pipeline generate your static error pages.
3
+ Generate your static error pages with the asset pipeline.
4
4
 
5
- This gem lets you include Sprockets-generated CSS and JS files,
6
- complete with cache-busting digests, in `public/404.html` and friends.
5
+ This gem lets you include Sprockets-generated CSS and JS files --
6
+ complete with cache-busting digests -- in `public/404.html` and friends.
7
7
  You can even use layouts.
8
+ No monkeypatching, no Rails engines, no routing, just idiomatic asset pipeline code.
8
9
 
9
- No monkeypatching, no Rails engines, no routing, just idiomatic code.
10
- The asset pipeline will generate static files so your
11
- web server shows your custom error pages even when your app is down hard.
10
+ `rake assets:precompile` generates static files so your webserver will respond
11
+ even when your application is down hard.
12
12
 
13
13
 
14
14
  ## Installation
@@ -34,6 +34,8 @@ In `config/application.rb`:
34
34
  config.assets.precompile += %w[404.html 422.html 500.html]
35
35
  ```
36
36
 
37
+ That's it!
38
+
37
39
 
38
40
  ## Usage
39
41
 
@@ -41,17 +43,13 @@ Whenever assets are precompiled (i.e. during each deploy),
41
43
  your error pages will be generated and saved in `/public`.
42
44
 
43
45
  ```sh
44
- # (public/404.html doesn't exist)
45
- rails assets:precompile
46
- # (public/404.html is your newest code)
46
+ $ rails assets:precompile
47
+ copy public/assets/404-1c763a81450.html to public/404.html
47
48
  ```
48
49
 
49
- Your error pages are automatically generated along with the
50
- rest of your assets each time you deploy.
51
-
52
50
  ### Rails Helpers
53
51
 
54
- Now you can update your error pages to use Rails helpers:
52
+ Here's an example of using Rails helpers:
55
53
 
56
54
  ```erb
57
55
  old:
@@ -76,6 +74,7 @@ static error pages to use layouts too, use the
76
74
  * Do we still need to use digest:true?
77
75
  * Use an initializer to automatically add error pages to the sprockets config?
78
76
  * Rails generator to move your error pages?
77
+ * I haven't bothered with `I18n.available_locales`/`404.es.html`. If you'd like localization, please file an issue.
79
78
 
80
79
 
81
80
  ## Alternatives
@@ -92,8 +91,5 @@ Pain-free MIT.
92
91
 
93
92
  ## Contributing
94
93
 
95
- My app isn't localized so I haven't bothered with `I18n.available_locales`.
96
- If you want localization, please file an issue.
97
-
98
94
  To make this gem less imperfect, please submit your issues and patches on
99
95
  [GitHub](https://github.com/bronson/error_page_assets/).
@@ -1,4 +1,4 @@
1
- require 'error_page_Assets'
1
+ require 'error_page_assets'
2
2
  require 'rails'
3
3
 
4
4
  module ErrorPageAssets
@@ -1,3 +1,3 @@
1
1
  module ErrorPageAssets
2
- VERSION = "0.2"
2
+ VERSION = "0.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: error_page_assets
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.2'
4
+ version: '0.3'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott Bronson