Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ngrx-forms

Package Overview
Dependencies
Maintainers
1
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ngrx-forms - npm Package Versions

1
6

3.0.4

Diff

Changelog

Source

3.0.4

Bugfixes
  • allow setting null and undefined values with curried version of setValue (fe92a23), thanks @chrissena for reporting this bug, closes #116

<a name="3.0.3"></a>

mrwolfz
published 3.0.3 •

Changelog

Source

3.0.3

Bugfixes
  • check if platform is browser in default view adapter to prevent error during server-side rendering (0646fb7), thanks @scott-wyatt for his contribution in #111), closes #110

<a name="3.0.2"></a>

mrwolfz
published 3.0.2 •

Changelog

Source

3.0.2

Bugfixes
  • do not treat null control values as boxed values (ae6a618), closes #94

<a name="3.0.1"></a>

mrwolfz
published 3.0.1 •

Changelog

Source

3.0.1

Bugfixes
  • remove module augmentations for requiredTrue and requiredFalse validation errors since they conflict with the required module augmentation and are already covered by it (1ab557f), closes #92

<a name="3.0.0"></a>

mrwolfz
published 3.0.0 •

Changelog

Source

3.0.0

This release requires TypeScript >=2.8.0 for the conditional type support. It also requires Angular >= 6.1.0 for compatibility with that TypeScript version.

Breaking Changes
  • remove cast utility function since it is obsolete due to proper control type inference
  • change order of parameters for many update functions to more be consistent
    • addArrayControl: move state parameter to first position for uncurried overload (ab094b8)
    • removeArrayControl: move state parameter to first position for uncurried overload (5a5aa17)
    • addGroupControl: move state parameter to first position for uncurried overload (b6da5ee)
    • removeGroupControl: move state parameter to first position for uncurried overload (a9035ce)
    • setErrors: rework to support different parameter combinations for errors (i.e. single error object, array of error objects, and rest parameters) and move state parameter to first position for uncurried overload (15ea555)
    • setUserDefinedProperty: move state parameter to first position for uncurried overload (520c384)
    • setValue: move state parameter to first position for uncurried overload (1a69795)
    • validate: move state parameter to first position for uncurried overload and add rest param overloads
  • due to rework of updateArray, updateGroup, and updateRecursive update functions it is now invalid to call any of these functions without parameters (which made no sense anyway) but it is still possible to call the functions with an empty array as parameter (which is useful in dynamic situations)
  • remove payload property from all actions and move corresponding properties into action itself (6f955e9)
  • replace createFormGroupReducerWithUpdate with createFormStateReducerWithUpdate (which takes any kind of form state, it also behaves differently in that it only applies the update if the form state changes as part of reducing the action, see the user guide for more details) (1b6114c)
  • mark all state properties as readonly to make it more clear the state is not meant to be modified directly (291e0da)
  • change form arrays and groups to preserve the values of isDirty, isEnabled, isTouched, and isSubmitted when the state is changed instead of always recomputing the values of these properties based on the state's child states (e.g. the state is not automatically disabled when all its child states are disabled, it is not automatically marked as pristine if it was dirty and all its child states are marked as pristine or all children are removed, etc.) (9202d1e), closes #68
  • mark arrays and groups as dirty when adding or removing controls (9202d1e)
Features
  • use conditional types to infer the type of child controls (see the documentation for more details)
  • add support for using arrays and objects as control values via boxing (see the documentation for more details) (315ae4c)
  • add formStateReducer function, a reducer which can reduce any kind of form state and is correctly typed due to conditional type inference (48eaaeb)
  • rework updateArray to support different parameter combinations for update functions (i.e. single function, array of functions, and rest parameters) (f82abf8)
  • rework updateGroup to support different parameter combinations for update function objects (i.e. single object, array of objects, and rest parameters) which reduces the probability of false type inference results (0bb1ca7)
  • rework updateRecursive to support different parameter combinations for update function objects (i.e. single object, array of objects, and rest parameters) (96121c3)
  • add updateArrayWithFilter update function which works the same as updateArray except that it also takes a filter function that is applied to each array element to determine whether the update function should be applied (0b66a6f)
  • add notEqualTo validation function (851a1ed)
  • enhance all form state reducers to match type signature for ActionReducer (they will still throw an error if the state is undefined) (f3b5fea)
  • add support for undefined values for all validation functions (6cce8d0, thanks @romankhrystynych for his contribution in #65), closes #64
  • improve typing of errors property on form states by using module augmentation inside of validation module to add well defined error properties to ValidationErrors interface (e202e65)
  • move documentation to Read the Docs
  • add FAQ
  • add some reducer tests for example application to showcase how ngrx-forms can be tested (5098f02), closes #58
Bugfixes
  • do not set the id attribute for input[type=radio] form elements (cbfd654), closes #63

<a name="2.3.6"></a>

mrwolfz
published 2.3.6 •

Changelog

Source

2.3.6

Bugfixes
  • do not automatically set id of form elements to state's ID for elements that already have an id set (3c8eabc), closes #86

<a name="2.3.5"></a>

mrwolfz
published 2.3.5 •

Changelog

Source

2.3.5

Bugfixes
  • fix typing of action type and TYPE properties to properly use literal string type (0cd07b6), closes #75, thanks @bufke for helping me find this

<a name="2.3.4"></a>

mrwolfz
published 2.3.4 •

Changelog

Source

2.3.4

Bugfixes
  • recursively update nested controls IDs when adding controls to arrays (7b1de7c), closes #72 (thanks @solnat for this fix)

<a name="2.3.3"></a>

mrwolfz
published 2.3.3 •

Changelog

Source

2.3.3

Bugfixes
  • ensure the value attribute of option elements is properly set via [value] bindings when there is no associated form view adapter (bfaa388) (closes #67, thanks @kmiskiewicz for helping me find this)

<a name="2.3.2"></a>

mrwolfz
published 2.3.2 •

Changelog

Source

2.3.2

Bugfixes
  • do not focus or blur form elements initially or on state changes when focus tracking is not enabled (f6a10d5) (thanks @bufke for helping me find this)
  • make implicit browser platform dependency optional and disallow focus tracking on non-browser platforms (e7760bc) (thanks @bufke for helping me find this)

<a name="2.3.1"></a>

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc