Releases: dmjio/miso
1.9.0
🍜 1.9.0
See the haddocks, miso repo and org for more information.
✨ Highlights
The major feature added in 1.9 is React-style components (VComp). Isolated Component can now be created and communicate with each other via message-passing. The original DSL has been extended to support this feature using an existential encoding (shown below). This feature allows type-safe embedding of Component in View. See the +> combinator to nest Component (this combinator unifies Component along the parent-child relationship, creating a typesafe Component hierarchy).
The JavaScript runtime has been extended to handle recursive mounting during diffing (FFI mounting calls recursively between Haskell and JS to mount Component). Delegation and hydration have also been extended to support Components.
-- 'VComp' case added to the View DSL
data View model action
= VNode Namespace Tag [Attribute action] [View model action]
| VText (Maybe Key) MisoString
| VComp (Maybe Key) (SomeComponent model) -- new-- Existential to create isolated 'Component'
data SomeComponent parent
= forall model action . Eq model
=> SomeComponent (Component parent model action) -- 'App' is now a synonym for 'Component'
type App model action = Component ROOT model action
-- 'Component' is now parameterized by 'parent' and recursive on 'View' via 'view'
data Component parent model action
= Component
{ model :: model
, view :: model -> View model action
, ...
}🎁 Features added (non-exhaustive)
misois now recursive,Componentcan now be embedded in otherComponentusing the mount (+>) combinator- We have a GitHub org now that features many examples.
- We've added a scheduler (like React) to process all events for all components in FIFO order, and to facilitate Component communication.
- Preliminary documentation has been added here
- Support for Web Assembly and GHC WASM browser mode
- 0 dependency (only rely on boot packages, no more
jsaddle), necessary for MicroHs integration. inline-js, a QuasiQuoter for JavaScript. See Miso.FFI.QQAppis now a synonym forComponent ROOT- Event delegation now virtualizes both the capture and bubble phases
- All JS has been ported to TypeScript, and is on npm
Componentcommunication has been added (e.g.broadcast)- Experimental support for reactivity through data bindings (see reactivity)
Transitionis nowEffectand has become the default interface for updating state, introducing effects.- We've added a
Miso.Stylemodule with our own style DSL. - Playwright integration tests (200+) were added and run in CI for both JS and WASM.
- Copious unit tests added along with increased code coverage. See coverage.
- Serverless (dropped NixOps).
- Added flake.nix
- 2D / 3D Canvas support has been added. See canvas-2d.
- Subscriptions, WebSockets, SSE have all been upgraded
- Miso.Fetch has replaced XHR.
- Replaced
aesonw/ Miso.JSON (for performance reasons due toJSString). - Miso.Html.Render has replaced
lucid(we render our own HTML). - Custom renderers were added, this allows experimental support for mobile phones as seen in miso-lynx
- Added our own lens library Miso.Lens
- Experimental hot reload support in Miso.Reload
- Support for the audio / video media APIs in Miso.Media
- Exported our own lexer and parser in Miso.Util.Parser
- Added new effect primitives for perform
IO(io/withSink/sync). - Added a new router in Miso.Router
- Component lifecycle hooks
mount/unmount - Node lifecycle hooks
onCreated,onDestroyed
🚀 2.0.0 plans
- MicroHs support.
- Dual thread support for miso-lynx.
- Additional documentation, testing, etc.
💝 Special thanks
A special thank you to everyone involved in this release.
- @TerrorJack for adding synchronous callbacks to the WASM backend, enabling the
Componentmounting feature in1.9. - @colinaaa for encouraging the miso-lynx integration.
- @Huxpro for the mention at ReactSummit, and the entire Lynx family for LynxJS.
- @juliendehos for three.hs, canvas games, flake support, docker integration, mdbook, etc. other improvements too numerous to mention.
- @ners for GraphQL, implementing the JSON spec., and much more.
- @hunvreus for Basecoat CSS.
- @Zer0- for extending and testing hydration support, HTML escaping and adding SSR, etc.
- @fanshi1028 for testing out every single new feature.
- @georgefst for general API and DX improvements, lens / reactivity support.
- @amesgen for
servant-clientsupport andtemplate-haskellsplices to load miso's JS in the WASM backend 💐 - @brakubraku for encouraging the implementation of React-style components.
- @jhrcek for documentation.
- @fizruk for lens API design.
- @augustss for making MicroHs.
- @Reijix for help w/ async. / sync. callbacks across WASM / JS backends and Drag n' Drop.
- @Deku-nattsu for Lynx support
- @maybetonyfu for general support
What's Changed
- Move to matrix.org by @dmjio in #762
- Remove duplicate model param. by @dmjio in #764
- Bump jsaddle and ghcjs-dom by @dmjio in #765
- Removes ios flag and CPP pragma, removes jsaddle flag by @dmjio in #767
- Initial commit of WASM support by @dmjio in #768
- Fix type application parse error on GHC 9+ by @georgefst in #769
- Add more CI build targets by @dmjio in #771
- Use
JSaddle.Warp.debugwhen run from GHCI by @georgefst in #770 - Add wasm overlay, put hello-world-wasm-web under ci. by @dmjio in #772
- Haskell miso updates by @dmjio in #773
- Add tagged releases to CI by @dmjio in #776
- Use environment variable for runner port by @georgefst in #774
- Refactor NixOS modules, and NixOS test runner. by @dmjio in #777
- Add Wasm and better
jsaddle-warpsupport to sample apps by @georgefst in #778 - Fix broken source link on haskell-miso.org by @ashwinmathi in #780
- Add CSS links to todo-mvc by @hasufell in #782
- Initial commit of Components by @dmjio in #766
- Add misoComponent function by @dmjio in #783
- Upgrade nixpkgs to version with fixed ghcjs by @tysonzero in #706
- Componentize SSE example by @dmjio in #786
- Adjust CPP for wasm ci build. by @dmjio in #787
- Use nix-channel --update in CI by @dmjio in #789
- Remove redundant imports and name shadowing in .Internal by @dmjio in #788
- Try increasing memorySize for NixOS tests QEMU. by @dmjio in #790
- Add virtual DOM integrity check to DebugPrerender by @dmjio in #785
- Mount component during syncChildren worst case. by @dmjio in #791
- Adds normalization when checking href property by @dmjio in #792
- Use language and links more inclusive of the WASM backend by @dmjio in #794
- Add upper bounds to miso.cabal file. by @dmjio in #793
- Ensure that target exists before delegation. by @dmjio in #795
- Update CI badge, test matrix -> Miso CI. by @dmjio in #797
- Cleanup Subs by @dmjio in #798
- Mount startComponent to body by @dmjio in #800
- Split out events. by @dmjio in #799
- Use a different HasLink instance for View. by @dmjio in #802
- Mention components, link to WASM FFI docs. by @dmjio in #803
- Add Miso.Render, render our own HTML. by @dmjio in #801
- Normalize URI, drop prefix slash when parsing window.location.href by @dmjio in https...
1.8.7
1.8.6
- Hides the implicit
showexport fromData.TextinMiso.String - Merges new syntax for GHC JS, preserving GHCJS backwards compatibility
What's Changed
- Fix build with
text2.1.2 by @georgefst in #752 - Add robots.txt to haskell-miso.org by @dmjio in #753
- Add Internals.md documentation. by @dmjio in #755
- Hide
showre-exports on text > 2.1.2 in Miso.String by @dmjio in #756 - New syntax support, backwards compat cpp for ghcjs by @dmjio in #757
- Bump to 1.8.6 by @dmjio in #758
New Contributors
- @georgefst made their first contribution in #752
Full Changelog: 1.8.5...1.8.6
1.8.5
1.8.4
1.8.3
- Implemented workaround for GHC bug in 9.0.2 where hidden functions are still colliding with
Preludefunctions (e.g.elem) - Added Haskell favicon to https://haskell-miso.org
- Indentation adjustments in JS files.
- Async version bump in JS tests.
- Support
text-1.2.5
1.8.2
1.8.1
1.8
- Added
rawHtmlcombinator. Useful for converting raw HTML into virtual DOM. - Backend and frontend fully merged (@tysonzero)
styleInlinecombinator (@developandplay)- Pixel Card Wars (@smelc)
- Delegate uses synchronous instead of asynchronous (@parthshah31)
- Nix refactoring
- GitHub CI
- Hosted examples via
nixops.