phlex-hanami 0.2.0.pre.alpha.3 → 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/CHANGELOG.md +37 -1
- 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: 94b5188b274ac90980037b58873c197a1ce6fc343d184e9302b41082426fc57b
|
|
4
|
+
data.tar.gz: 8cdb0e7203df09112ec77a082e6c727520746e25cd3345071c873722c1588af0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4ba875c6722dc031fd2911c5e479295b31cc5919b3f881b5f969c32cbcd3797e3b9e87145315aff2289d07fef2d8bcdf04b5dfdce020eeac1e10b914c2bd4211
|
|
7
|
+
data.tar.gz: 14f5c3441510387fee8927a7eed2722997fc4a6cb3bf81d3e803075d0083dbdf6747c1e670ac5eac069cb9c0fc2fea6e3f8c6960bcfcc10594e08f8fe46586a0
|
data/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,41 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [v0.2.0] - 2026-09-10
|
|
11
|
+
|
|
12
|
+
First stable release by the new maintainer. It shares no code with 0.1.0, so treat an upgrade from 0.1.0 as a move
|
|
13
|
+
to a new gem and start from the [usage docs](https://github.com/aaronmallen/phlex-hanami/tree/main/docs/usage). The
|
|
14
|
+
alpha sections below record each change as it landed. This section gathers them in one place.
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- `Phlex::Hanami::View` and `Phlex::Hanami::Layout`, the base classes for a view and a layout, and
|
|
19
|
+
`Phlex::Hanami::Renderable` for a `Phlex::HTML` base class you already have.
|
|
20
|
+
- Auto render. An action renders the Phlex view whose container key matches its own, so
|
|
21
|
+
`MyApp::Actions::Posts::Index` renders `MyApp::Views::Posts::Index` with no `response.render` call and no
|
|
22
|
+
configuration. An action with no matching view renders nothing, so a slice can move to Phlex one action at a time.
|
|
23
|
+
- A view receives the exposures and params its `initialize` asks for and drops the rest, so a stray query param does
|
|
24
|
+
not raise. An initializer that takes `**` receives all of it.
|
|
25
|
+
- A layout convention: `Views::Layout` in a slice wraps that slice's views. `layout` sets a different one, and
|
|
26
|
+
`layout nil` opts out. The view renders before its layout, so a `content_for` set in the view shows up in the
|
|
27
|
+
layout's `head`.
|
|
28
|
+
- The view context in every view and every component under it: `path`, `url`, `asset_url`, `content_for`,
|
|
29
|
+
`csrf_token`, `flash`, `session`, `request` and more. A view reads the same whether or not hanami-view is bundled.
|
|
30
|
+
- `t`, which resolves a relative key against the view's container key, so `t(".title")` in
|
|
31
|
+
`MyApp::Views::Posts::Index` looks up `posts.index.title`.
|
|
32
|
+
- `Phlex::Hanami::Helpers`, an opt in for Hanami's helper library, such as `form_for` and `format_number`. It needs
|
|
33
|
+
hanami-view. Their output renders as markup rather than escaped twice, and Phlex keeps its own `raw` and `tag`.
|
|
34
|
+
- `Phlex::Hanami::Component` for everything below a view, `Phlex::Hanami::Contextual` for a component base class you
|
|
35
|
+
already have, and support for [Phlex kits](https://www.phlex.fun/components/kits.html).
|
|
36
|
+
- Phlex views for [hanami-mailer](https://github.com/hanami/mailer), through `Phlex::Hanami::Mailer::View` and
|
|
37
|
+
`Phlex::Hanami::Mailer::Layout`. A mailer renders the view whose container key matches its own, and the gem builds
|
|
38
|
+
the plain text part from the HTML unless the view defines `text_body`.
|
|
39
|
+
- `Phlex::Hanami::Testing::ViewHelpers`, for testing a view or a component without a request, and
|
|
40
|
+
`require "phlex/hanami/rspec"` to include them in every example group tagged `type: :view`.
|
|
41
|
+
- RBS signatures for the public API, shipped in `sig`.
|
|
42
|
+
- Usage docs for every part of the gem, including how it hooks into Hanami and why code reloading needs no extra
|
|
43
|
+
work.
|
|
44
|
+
|
|
10
45
|
## [v0.2.0-alpha.3] - 2026-09-06
|
|
11
46
|
|
|
12
47
|
### Added
|
|
@@ -66,7 +101,8 @@ Initial alpha release by the new maintainer [@aaronmallen](https://github.com/aa
|
|
|
66
101
|
|
|
67
102
|
Initial release, by the previous maintainer [@stephannv](https://github.com/stephannv).
|
|
68
103
|
|
|
69
|
-
[Unreleased]: https://github.com/aaronmallen/phlex-hanami/compare/0.2.0
|
|
104
|
+
[Unreleased]: https://github.com/aaronmallen/phlex-hanami/compare/0.2.0...HEAD
|
|
105
|
+
[v0.2.0]: https://github.com/aaronmallen/phlex-hanami/compare/0.2.0-alpha.3...0.2.0
|
|
70
106
|
[v0.2.0-alpha.3]: https://github.com/aaronmallen/phlex-hanami/compare/0.2.0-alpha.2...0.2.0-alpha.3
|
|
71
107
|
[v0.2.0-alpha.2]: https://github.com/aaronmallen/phlex-hanami/compare/0.2.0-alpha.1...0.2.0-alpha.2
|
|
72
108
|
[v0.2.0-alpha.1]: https://github.com/aaronmallen/phlex-hanami/releases/tag/0.2.0-alpha.1
|