All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning
- Queue can discard a callback by reference to the callback
- Queue will stop calling further callbacks ona trigger if true is returned from a callback.
1.1.0 - 2020-02-14
- isPromise, enforcePromise, methodPromise
- assert
1.0.6 - 2020-01-15
- Updated dependencies
1.0.5 - 2019-12-26
- Updated dependencies
1.0.4 - 2019-12-08
- Updated dependencies
1.0.3 - 2019-12-08
- Updated dependencies
1.0.2 - 2019-12-06
- Updated dependencies
1.0.0 - 2019-12-04
- isSymbol, enforceSymbol, methodSymbol
- isMap, enforceMap, methodMap
- isWeakMap, enforceWeakMap, methodWeakMap
- isSet, enforceSet, methodSet
- isWeakSet, enforceWeakSet, methodWeakSet
- enforceInstance is now enforceInstanceOf and methodInstance is methodInstanceOf
- Various performance improvements
- privateProp
- Moved CssSize, DockPoint, Thickness, and Element classes and functions to new type-enforcer-ui
- Moved Point and Vector classes and functions to new type-enforcer-math
- Queue no longer stores extra data with a callback
0.6.4 - 2019-10-22
- Updated dependencies
0.6.3 - 2019-10-21
- Updated dependencies
0.6.2 - 2019-10-09
- Don't use .apply in Queue.trigger if no context is provided
0.6.1 - 2019-10-09
- methodFunction won't throw if attempting to set to something other than a function
0.6.0 - 2019-10-08
- preferring .bind over .call and .apply. Methods should be much faster now.
- Added bindTo method to Queue for setting a context to bind all callbacks to
- methodFunction and methodQueue now bind callbacks to "this"
- option "bind" can turn this off, defaults to true
0.5.8 - 2019-10-01
- methods now store values in a WeakMap
0.5.7 - 2019-08-28
- Updated dependencies
0.5.6 - 2019-08-15
- enforceArray and enforceObject now coerce values properly
0.5.5 - 2019-07-29
- Updated dependencies
0.5.4 - 2019-07-27
0.5.3 - 2019-07-19
- methodQueue shouldn't throw an error if called after .remove() is called
0.5.2 - 2019-07-16
- Fixing build config
0.5.1 - 2019-07-13
###Changed
- methods use privateProp to store values
0.5.0 - 2019-07-04
0.4.4 - 2019-06-06
- Updated dependencies
0.4.3 - 2019-03-27
- DockPoint added read-only property 'opposite'
0.4.2 - 2019-03-27
- castArray returns an empty array when given undefined, and converts array-like objects into arrays.
- isNumber returns false for NaN
0.4.1 - 2019-03-11
- Fixed bug in methods where the init value could get modified.
0.4.0 - 2019-03-11
- Float type (check, enforcer, and method)
- Integer coercion is now more strict
- Switching dependencies back to object-agent
0.3.3 - 2019-02-15
- Switching dependencies to deep-equal instead of object-agent
0.3.2 - 2019-02-14
- Replaced dependencies on clone and deepEqual with object-agent
- Added id and callback args to the methodQueue set option
0.3.1 - 2019-02-10
0.3.0 - 2019-02-03
- Removed Dependency on Lodash
0.2.4 - 2019-01-31
0.2.3 - 2019-01-30
- Exporting the check functions as an object
- Exporting individual enforcers and methods
0.2.2 - 2019-01-24
- Removed dependencies on babel plugin proposals.
- Improved docs.
0.2.1 - 2019-01-24
- Changed isBool to isBoolean, enforce.bool to enforce.boolean, and method.bool to method.boolean
- Changed isFunc to isFunction, enforce.func to enforce.function, and method.func to method.function
- Changed isInt to isInteger, enforce.int to enforce.integer, and method.int to method.integer
0.2.0 - 2019-01-18
- 99.9% test-coverage
- testing in chrome and firefox
- This CHANGELOG
- checks
- moved all type checks into new functions (isArray, isBool, etc.)
- most checks can also check if a value can be coerced
- isInstanceOf fixes issues with primitives and instanceof
- isJson function to check if a value can be parsed as JSON
- enforce
- most enforce functions can now coerce values
- added enforce.regExp
- method
- added method.regExp
- added "deep" option to method.object and method.array
- added "coerce" option to methods of types that can be coerced
###Changed
- Date functions only accept native Dates now. Removes dependency on Moment.js.
- DockPoint
- default value is now DockPoint.POINTS.NONE
- added methods "isSame" and "toString"
- bug fix: setting primary or secondary now updates the value
- Enum
- added method "key"
- Queue
- method "getTotalCallbacks" is now read only property "length"
- method "isBusy" is now read only property "isBusy"
- enforce
- Custom type functions no longer coerce values by default
###Removed
- Removed static method "isInstance" from custom data types in favor of new checks function.
- Queue
- removed method "getCallbacks"
0.1.6 - 2019-01-02
- Snyk.io badge for security checks
- enforce.instance
- Enum.each
- Changed CallbackQueue to Queue.
0.1.5 - 2018-12-30
- .babelrc became babel.config.js so the babel plugins are handled properly when using this library as an npm package
0.1.4 - 2018-12-30
- Moved necessary Babel plugins to dependencies in package.json
0.1.3 - 2018-12-29
- Documentation
0.1.2 - 2018-12-29
- Documentation
0.1.1 - 2018-12-29
- Documentation
- Initial enforcers, methods, and documentation