ember-useful-decorators
v0.0.2
Published
The default blueprint for ember-cli addons.
Downloads
1
Readme
ember-useful-decorators
A collection of useful decorators concerning functionality that is specific to Ember.
Compatibility
- Ember.js v4.8 or above
- Ember CLI v4.8 or above
- Node.js v18 or above
Installation
ember install ember-useful-decorators
Usage
Each decorator is described below:
Runloop functions
@once
Invoke the decorated function with once
@scheduleOnce(queue)
Invoke the decorated function with scheduleOnce, against the given queue queue
.
@next
Invoke the decorated function with next
@run
Invoke the decorated function with run
Caching
@memoizeByOutput(equalityFunc?: (a: any, b: any) => boolean)
Cache output values to avoid excessive dirtying of complex return values (e.g. objects). equalityFunc
defaults to a shallow object comparison function if not provided.
Contributing
See the Contributing guide for details.
License
This project is licensed under the MIT License.