vite_ruby 1.2.4 → 1.2.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/lib/vite_ruby/manifest.rb +15 -0
- data/lib/vite_ruby/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4cf73b3471127a2ca30bb94a9db5eadde2674289194dbe605ae01c3dc9bee817
|
4
|
+
data.tar.gz: 93312a90a04807cb3f683f9435fddd399ffdfeda7dff31b9316c9977fb1b7a22
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 789ff6d9d918b741f1430e802ea7fed4404ae3e216748d26b48f48c6a3d41976197f00a7e2ed3878b88d819fb2b812bef14099f753d884e02c6f0ea8acc5b315
|
7
|
+
data.tar.gz: 58044eba7336765db7a63bfa871f0c7ede9b28ef8ebf66708eb9c8c669abb7ca24f9855878af55fe02afd3e5d5126e1f49e5ef7e4feeaf8229984f59445c38d1
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,12 @@
|
|
1
|
+
## [1.2.5](https://github.com/ElMassimo/vite_ruby/compare/vite_ruby@1.2.4...vite_ruby@1.2.5) (2021-04-21)
|
2
|
+
|
3
|
+
|
4
|
+
### Features
|
5
|
+
|
6
|
+
* Add helpers to enable HMR when using @vitejs/plugin-react-refresh ([a80f286](https://github.com/ElMassimo/vite_ruby/commit/a80f286d4305bbae29ea7cea42a4329a530f43fa))
|
7
|
+
|
8
|
+
|
9
|
+
|
1
10
|
## [1.2.4](https://github.com/ElMassimo/vite_ruby/compare/vite_ruby@1.2.3...vite_ruby@1.2.4) (2021-04-21)
|
2
11
|
|
3
12
|
|
data/lib/vite_ruby/manifest.rb
CHANGED
@@ -46,6 +46,21 @@ class ViteRuby::Manifest
|
|
46
46
|
prefix_vite_asset('@vite/client') if dev_server_running?
|
47
47
|
end
|
48
48
|
|
49
|
+
# Public: The content of the preamble needed by the React Refresh plugin.
|
50
|
+
def react_refresh_preamble
|
51
|
+
if dev_server_running?
|
52
|
+
<<~REACT_REFRESH
|
53
|
+
<script type="module">
|
54
|
+
import RefreshRuntime from '#{ prefix_vite_asset('@react-refresh') }'
|
55
|
+
RefreshRuntime.injectIntoGlobalHook(window)
|
56
|
+
window.$RefreshReg$ = () => {}
|
57
|
+
window.$RefreshSig$ = () => (type) => type
|
58
|
+
window.__vite_plugin_react_preamble_installed__ = true
|
59
|
+
</script>
|
60
|
+
REACT_REFRESH
|
61
|
+
end
|
62
|
+
end
|
63
|
+
|
49
64
|
protected
|
50
65
|
|
51
66
|
# Internal: Strict version of lookup.
|
data/lib/vite_ruby/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vite_ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Máximo Mussini
|
@@ -237,8 +237,8 @@ homepage: https://github.com/ElMassimo/vite_ruby
|
|
237
237
|
licenses:
|
238
238
|
- MIT
|
239
239
|
metadata:
|
240
|
-
source_code_uri: https://github.com/ElMassimo/vite_ruby/tree/vite_ruby@1.2.
|
241
|
-
changelog_uri: https://github.com/ElMassimo/vite_ruby/blob/vite_ruby@1.2.
|
240
|
+
source_code_uri: https://github.com/ElMassimo/vite_ruby/tree/vite_ruby@1.2.5/vite_ruby
|
241
|
+
changelog_uri: https://github.com/ElMassimo/vite_ruby/blob/vite_ruby@1.2.5/vite_ruby/CHANGELOG.md
|
242
242
|
post_install_message:
|
243
243
|
rdoc_options: []
|
244
244
|
require_paths:
|