Skip to content

v0.1.1

Choose a tag to compare

@tristendillon tristendillon released this 18 Nov 03:33
· 658 commits to main since this release
e7a015b

The first patch. It moves the Solid adapter to the stable Solid 2 release and fixes the bugs people hit first.

Install

npm install @lunarhue/forms-react    # React 16.8 and later
npm install @lunarhue/forms-solid    # Solid 2

Changes

  • @lunarhue/forms-solid, @lunarhue/forms-bind: the adapter and the Solid binding now ask for the stable Solid 2 release. The solid-js and @solidjs/web peer ranges start at 2.0.0, so the 2.0 release candidates no longer satisfy them. (#147)
  • @lunarhue/forms-solid: an input shows the form's value after hydration even when the browser filled it back in first. Firefox restores typed text on a reload, and on Solid 2.0.0 the input kept that text while the form held something else. (#161)
  • @lunarhue/forms-core: define accepts a value type that refers to itself, such as a tree node with a children array of tree nodes. Before, TypeScript rejected these with TS2615. (#152)
  • @lunarhue/forms-core: you can write a value you read from a field straight back. setValue, push, insert and the rebase plugin take the readonly values that peek() and field objects return, so tags.setValue(tags.peek().value) compiles without a spread or a cast. (#154)
  • @lunarhue/forms-core: in a form without a schema, onSubmit gets a copy of the form value that it may change. Sorting or pushing to an array in onSubmit no longer throws in development. (#150)
  • @lunarhue/forms-core: a plugin can write from the cleanup its onActive returns. Before, that write waited for the next write to the store, which might never come. (#148)
  • @lunarhue/forms-bind: the zustand binding is built and tested against zustand 5.1. The peer range is still ^5.0.0. (#113)

Docs

  • The READMEs said Solid 1.8 works through @lunarhue/forms-solid/v1. That entry only re-exports core for now, so they now say the adapter needs Solid 2. #124 tracks the Solid 1 adapter. (#149)
  • docs/plugins.md explains the TS2353 error define gives inside a function that is generic over the schema type, and shows the helper that works. (#153)

Known issue

  • On Solid in Safari, moving an array row takes focus off the row's input. (#157)

All five packages share one version. Each has its own CHANGELOG.md.