homura-runtime 0.3.19 → 0.3.21
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/CHANGELOG.md +11 -0
- data/lib/erb/opal_compat.rb +2 -3
- data/lib/homura/runtime/build_support.rb +7 -0
- data/lib/homura/runtime/version.rb +1 -1
- data/lib/phlex/opal_compat.rb +17 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c727de4d506e1d4f3f850fcf02a24471670bb003451910db9d5043c88f481df6
|
|
4
|
+
data.tar.gz: 89e23c95e901eb6232687e9da34d0a4aa402c03418617a1828b933a6eb840499
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: '096b5e42136d862cbd3d66a8c16a194e26df0d54e508b06072753563558f63bd2e1c85a3c16bca23407ae4d3479776199e8d122b1af6d86adce85abe32b26fe1'
|
|
7
|
+
data.tar.gz: dff29ea05788f0e8b7bcf3d4a9ba92594d43dc5deb2dc5318a2699045d268e08c94b0e16e409237b179092a9545956539f97ac52b83a5acf9d4ca2c6cd4e6799
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.3.21 (2026-06-25)
|
|
4
|
+
|
|
5
|
+
- Preload Phlex's FIFO dependency before Phlex root setup and explicitly load
|
|
6
|
+
the SGML/HTML/SVG files in the Opal compatibility layer. This replaces the
|
|
7
|
+
Zeitwerk autoload work that cannot run against a filesystem inside Workers.
|
|
8
|
+
|
|
9
|
+
## 0.3.20 (2026-06-25)
|
|
10
|
+
|
|
11
|
+
- Define the Opal `ERB::Escape` shim under `class ERB`, matching Opal and
|
|
12
|
+
Ruby's ERB constant shape.
|
|
13
|
+
|
|
3
14
|
## 0.3.19 (2026-06-25)
|
|
4
15
|
|
|
5
16
|
- Add an Opal `ERB::Escape.html_escape` shim before loading Phlex. Ruby 3.4
|
data/lib/erb/opal_compat.rb
CHANGED
|
@@ -13,6 +13,9 @@ module HomuraRuntime
|
|
|
13
13
|
"phlex" => "phlex/opal_compat",
|
|
14
14
|
"literal" => "literal/opal_compat"
|
|
15
15
|
}.freeze
|
|
16
|
+
OPAL_ENTRY_PRELOAD_REQUIRES = {
|
|
17
|
+
"phlex" => %w[monitor json phlex/fifo]
|
|
18
|
+
}.freeze
|
|
16
19
|
|
|
17
20
|
class << self
|
|
18
21
|
def loaded_spec(name, loaded_specs: Gem.loaded_specs)
|
|
@@ -263,6 +266,10 @@ module HomuraRuntime
|
|
|
263
266
|
root_file = lib.join("#{spec.name}.rb")
|
|
264
267
|
next unless root_file.file?
|
|
265
268
|
|
|
269
|
+
OPAL_ENTRY_PRELOAD_REQUIRES.fetch(spec.name, []).each do |require_path|
|
|
270
|
+
lines << "require #{require_path.inspect}"
|
|
271
|
+
end
|
|
272
|
+
|
|
266
273
|
lines << "Zeitwerk.__homura_next_gem_root = #{root_file.to_s.inspect}"
|
|
267
274
|
lines << "require #{("#{spec.name}.rb").inspect}"
|
|
268
275
|
lines << "`Opal.loaded([#{spec.name.inspect}])`"
|
data/lib/phlex/opal_compat.rb
CHANGED
|
@@ -3,6 +3,23 @@
|
|
|
3
3
|
require "corelib/pattern_matching"
|
|
4
4
|
require "zeitwerk/opal_compat"
|
|
5
5
|
require "phlex" unless defined?(Phlex)
|
|
6
|
+
require "phlex/error"
|
|
7
|
+
require "phlex/errors/argument_error"
|
|
8
|
+
require "phlex/errors/double_render_error"
|
|
9
|
+
require "phlex/errors/name_error"
|
|
10
|
+
require "phlex/errors/runtime_error"
|
|
11
|
+
require "phlex/helpers"
|
|
12
|
+
require "phlex/sgml/safe_object"
|
|
13
|
+
require "phlex/sgml/safe_value"
|
|
14
|
+
require "phlex/sgml/state"
|
|
15
|
+
require "phlex/sgml/attributes"
|
|
16
|
+
require "phlex/sgml/elements"
|
|
17
|
+
require "phlex/sgml"
|
|
18
|
+
require "phlex/html/void_elements"
|
|
19
|
+
require "phlex/html/standard_elements"
|
|
20
|
+
require "phlex/html"
|
|
21
|
+
require "phlex/svg/standard_elements"
|
|
22
|
+
require "phlex/svg"
|
|
6
23
|
|
|
7
24
|
Phlex::SGML
|
|
8
25
|
Phlex::SGML::State
|