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

@briebug/ngrx-auto-entity

Package Overview
Dependencies
Maintainers
6
Versions
69
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@briebug/ngrx-auto-entity - npm Package Versions

1
7

0.5.0-alpha.1

Diff

jrista
published 0.4.2 •

Changelog

Source

0.4.2 Beta (2020-02-13)

Introduces entity data transformation feature to enable fromServer and toServer data transformations via the transform property on the @Entity decorator. Each transformation may optionally implement fromServer and/or toServer. When a transformation is implemented for a given direction, it will be applied to data flowing in that direction. If transformations are present, they will be applied in the order specified.

Data transformations may be used to convert things such as dates from UTC strings on the server, to actual Date objects in the client during loads, and back again during saves. Transform implementations are type-free, allowing any form of data to be handled as input, and any form of data to be returned as output. This allows transformations to be highly composable if necessary.

The IAutoEntityService interface has been enhanced to include, as a final parameter for modification methods, an additional originalEntity property. This is the entity before transformation, in the event that the original data is required by an entity service implementation.

Transforms must be configured for each entity. No global transformations are supported at the current time.

Resolves #59

Features

  • actions: Includes transform in IEntityInfo attached to every auto-entity action
  • service: Refactored to handle transformation of all data, to and from server, for all entities, if configured via @Entity
  • service: Extended IAutoEntityService interface to include support for originalEntity (pre-transformation)
  • decorators: Add new, optional transform property that accepts an array of IEntityTransformation implementations

<a name="0.4.1"></a>

jrista
published 0.4.1 •

Changelog

Source

0.4.1 Beta (2020-02-09)

Introduces the ability to delete entities just by their key, or many entities by their keys. This allows the deletion of entities without actually having the entity objects on hand.

Also resolves an issue with clearing state, which would also clear custom developer-defined extra state included alongside auto-entity managed state.

Features

  • actions:** Add DeleteByKey, DeleteManyByKeys and related result actions (#85)
  • service: Add support for deleteByKey and deleteManyByKeys methods in entity services (#85)
  • reducer: Handles new delete by keys result actions to rmeove deleted entities and update deleting flags/timestamps (#85)
  • decorators: Add support for new delete by keys actions in effect exclusion of @Entity decorator (#85)
  • facades: Add deleteByKey and deleteManyByKeys methods to generated facades (#85)
  • effects: Add operators and effects to handle delete by keys actions (#85)

Bug Fix

  • reducer: No longer removes custom state when clearing auto-entity managed state with Clear action (#86)
  • util: Fix buildState and buildFeatureState and related types to support custom properties in extra state under TS 3.x (#88)

<a name="0.4.0"></a>

jrista
published 0.4.0 •

Changelog

Source

0.4.0 Beta (2020-01-13)

Introducing the @Entity decorator for model classes. This decorator provides custom naming capabilities, the ability to filter which auto-entity pre-fab effects handle each model, as well as define a default comparer for sorting entities retrieved with a new .sorted$ stream on pre-fab facades.

Features

  • decorators: Add @Entity decorator for models with modelName, pluralName, uriName properties (#70)
  • decorators: Add excludeEffects functionality to @Entity decorator for filtering which effects handle entity
  • decorators: Add comparer property to @Entity decorator to support selecting sorted entities (#58)
  • selectors: Add selectAllSorted selector that uses entity comparer to sort on selection (#58)
  • facades: Add sorted$ stream to return all entities in sorted order from selectAllSorted selector (#58)

Internal

  • decorators: Moved all decorators into internal /lib/decorators directory (will break direct imports, use public api!)

Bug Fix

  • selectors: Added additional falsy checks to all selectors to limit frequency of hard failures (#81)
  • decorators: Added modelName to @Entity decorator to allow explicit definition of model name immune to mangling by code minifiers (#81)

<a name="0.3.1"></a>

jrista
published 0.3.1 •

Changelog

Source

0.3.1 Beta (2020-01-07)

Bug fix release! We apologize for any inconvenience the v0.3.0 release may have caused. We introduced a correlation Id into our actions, and relied on uuidv4 to handle their generation. Turned out, uuidv4 just recently went through a breaking change, and the default import was removed. This caused problems, dependent upon which version of uuidv4 was used by the application using ngrx-ae.

We have replaced uuidv4 with internal code. Fast, small uuid function acquired from the following gist:

https://gist.github.com/LeverOne/1308368

Bug Fix

  • uuidv4: Removed in favor of small, fast built in function

<a name="0.3.0"></a>

jrista
published 0.3.0 •

Changelog

Source

0.3.0 Beta (2019-11-26)

This release adds the correlationId property (defaulting to uuid()) to EntityAction which should help in tracking correlated actions. Correlated actions are usually sets of request/success/failure actions, such as Create, CreateSuccess, and CreateFailure.

Features

  • correlated actions: Add correlationId property to EntityAction for tracking correlated actions. (#75)

Package

  • dependencies: Add peer dependency on uuidv4

Breaking Changes !!

  • uuidv4 will need to be added to your package.json as a dependency

Security Updates

<a name="0.2.8"></a>

jrista
published 0.2.8 •

Changelog

Source

0.2.8 Beta (2019-11-19)

This release restores a missing action to the library public interface index.

Bug Fixes

  • actions: Add clear action to exported actions of public interface

<a name="0.2.7"></a>

jrista
published 0.2.7 •

Changelog

Source

0.2.7 Beta (2019-10-13)

This release restores a missing selector and adds a new factory function for use with custom effects creation.

Features

  • actions: Add fromEntityTypes factory function for multi-entity multi-action effects filtering (#66)

Bug Fixes

  • selectors: Add createdAt facade getter and corresponding selectors (#65)

<a name="0.2.6"></a>

jrista
published 0.2.6 •

Changelog

Source

0.2.6 Beta (2019-09-05)

This release resolves two issues with multiple-entity deselections due to bugs in the reduction of deselectMany and deselectAll.

Features

  • actions: Add input validation checks and exception throwing to selection related actions
  • reducer: Fix issue with potential undefined in selection related reductions #62
  • reducer: Fix issue with calls to Array.prototype.some on certain arrays being implemented incorrectly #60

<a name="0.2.5"></a>

jrista
published 0.2.5 •

Changelog

Source

0.2.5 Beta (2019-08-12)

This release add new actions (and related effects, reducers, selectors & facade features) for edit and change tracking as well as adding more entities to the current set selection.

Features

  • edit: Add new Edit, Change, EndEdit actions and related functionality
  • selection: Added new selectMore and selectMoreByKeys actions and related functionality

<a name="0.2.2"></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