v0.14.2 #357
bitspittle
announced in
Announcements
v0.14.2
#357
Replies: 1 comment
-
Thank you @bitspittle. It has been a pleasure to work with you on my first commit for Kobweb. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This release includes a wide range of miscellaneous fixes, including a growing number of external contributions, which is really appreciated!
The SVG APIs have seen a significant expansion since the last release. For example, gradient support has been added:
But that's just one of many features. For a more detailed list of release notes, read on!
Frontend
defs
,symbol
, gradients,transform
, and a few others.FontVariant
modifiers.WordBreak
modifier.Silk
registerBaseStyle
has been deprecated and renamed toregisterStyleBase
.Backend
Markdown
Read more at our [privacy policy](../privacy-policy.md)
Gradle
Notes
Kobweb backend: Disposing resources
If you are initializing an unmanaged external resource in your server that you'd like to release when the server goes down, you can use a new
onDispose
event for this. A basic example looks like this:The event is passed a
DisposeEvent
parameter you can use if you'd like to check the source of the dispose request (e.g.ctx.events.onDispose { evt -> ... }
). The reason will either be due to a live reloading dev event, the server shutting down, or the JVM getting shut down (which can be caused if the server's process is interrupted externally).It's worth noting that Kobweb firing a dispose event is best effort. There is no guarantee it will be called in every situation -- for example, if the machine that your backend is running on loses power, or if the process is killed aggressively by the OS. Still, adding a dispose handler when appropriate can still often be useful, especially in development when live reloading events are very common.
SVG classes have moved
If you are a user who jumped into using SVGs early, note that all SVG methods have moved under a subpackage. If you get a compile error, please change your import from
com.varabyte.kobweb.compose.dom
tocom.varabyte.kobweb.compose.dom.svg
(that is, just add a.svg
to the end of the imports)We tried to support deprecating the old path instead of turning this into a compile error. However, this was not possible due to the large number of extension methods we have in this API.
We genuinely apologize for the inconvenience!
registerBaseStyle
toregisterStyleBase
While cleaning up code, we noticed that a very old method name was inconsistent with newer APIs, so we deprecated the old. This is possibly used in a lot of user's projects since it's part of the default app template.
Migrating should be trivial (it's just a rename), but we mention this here since it's likely so common.
New Contributors
We are always grateful for people who decide to brave our codebase and submit fixes. Thank you all!
Full Changelog: v0.14.1...v0.14.2
This discussion was created from the release v0.14.2.
Beta Was this translation helpful? Give feedback.
All reactions