Skip to content

Releases: effector/patronum

v1.8.3

09 Jun 07:25
85972a3
Compare
Choose a tag to compare

🐛 Bug Fixes

  • fix condition method calling else branch when then branch changes predicate #204 (@sergeysova)

📚 Documentation

🚀 Experimental

  • Added experimental operators and, or, not, either, equals

They're allow us to write logical conditions easily without much combines and maps:

// without logical operators

const $userExists = $user.map(user => user !== null);
const $isAttemptsMaximum = $numberOfAttempts.map(attempts => attempts >= ATTEMPTS_MAXIMUM);
sample({
  clock,
  source,
  filter: combine(
    $isAttemptsMaximum,
    $cardActivated,
    $restricted,
    $userExists,
    (isAttemptsMaximumx, activated, restricted, userExists) => !isAttemptsMaximum && activated && !restricted && userExists,
  ),
  target,
})
// with these logical operators

const $isAttemptsMaximum = $numberOfAttempts.map(attempts => attempts >= ATTEMPTS_MAXIMUM)
sample({
  clock,
  source,
  filter: and(
    not($isAttemptsMaximum),
    $cardActivated,
    not(equals($user, null)),
    not($restricted),
  ),
  target,
})

It is experimental! Use on your own risk. Each method create a new store and calls combine under the hood.

v1.8.2

17 Feb 08:30
605b80d
Compare
Choose a tag to compare

🐛 Bug Fixes

v1.8.1

15 Feb 09:18
374b3a8
Compare
Choose a tag to compare

🐛 Bug Fixes

v1.8.0

07 Feb 11:48
4d4f0e3
Compare
Choose a tag to compare

🚀 Features

  • Allow pass $store as predicate for method some, add shorthand form #195 (@Laiff)

📘 Documentation

  • Improved installation guide and debug guide

v1.7.0 🦋 petilia

03 Feb 15:57
3de2894
Compare
Choose a tag to compare

🚀 Features

  • Add initial support for babel-macro. It is useful for CRA support
import { splitMap } from 'patronum/macro';

🐛 Bug Fixes

📚 Documentation

v1.7.0-next.0

23 Dec 11:58
5b5b62a
Compare
Choose a tag to compare
v1.7.0-next.0 Pre-release
Pre-release

🚀 Features

🐛 Bug Fixes

🧰 Maintenance

v1.6.0-next.0

15 Nov 09:21
e8a7110
Compare
Choose a tag to compare
v1.6.0-next.0 Pre-release
Pre-release

v1.5.0-next.0

14 Nov 18:31
53e660a
Compare
Choose a tag to compare
v1.5.0-next.0 Pre-release
Pre-release

🚀 Features

v1.4.0-next.1

14 Nov 18:15
Compare
Choose a tag to compare
v1.4.0-next.1 Pre-release
Pre-release
  • Fix interval method in babel plugin list

v1.4.0-next.0

14 Nov 10:52
4a7c516
Compare
Choose a tag to compare
v1.4.0-next.0 Pre-release
Pre-release

🚀 Features