Releases: Jashepp/customElements-mixinPropertiesAttributes
Releases · Jashepp/customElements-mixinPropertiesAttributes
v1.11.0
Notable Changes:
- Shorthand functions
()=>{}
can now be used onobserver
and other configurable places.element
will be passed as the last argument since they don't havethis
. 629122a- If the observer's function does not exist on the element, it will no longer error.
notify
can now be specified as a string for a custom event name. a948c1c- Internal
.props
on elementProperty class is now.config
. 6e334da
See README for documentation.
Commits
- Update .github workflows bba5572
- Add package.json keywords 50dc2b0
- Update devDeps 2d19701
- Minor improvements 6e334da
- Update copyright year 2ba10a7
- Optimised constructor & other code 7ef34e0
- Improve notify to be specified as a string, for custom event names a948c1c
- Improve callback execution, and allow shorthand functions 629122a
v1.10.2
Notable Changes:
- (Potential breaking change) Fix reflectValueToAttribute to remove null attribute when no transform. d578aef
Commits
v1.10.1
v1.10.0
Notable Changes:
- Add support for applying the mixin after class-declaration. a878163 097baee
- Attribute/Property config
type
can now be a 'string' with the name of a built-in propType. 7de7a58
- Attribute/Property config
- Fix
reflectToAttribute
to run even when internal value is the same. 84528e3
See README for documentation.
Commits
- Update github actions 14f3d17
- Cypress v12.1 f76c7a9
- Update npm scripts fb7c735
- Improve wording in README f9624c9
- Update README 223525a
- Add more type tests 63cf911
- reflectValueToAttribute regardless of propStore & value states 84528e3
- Merge constructor options from main mixin function 097baee
- Add config.type as String alias for propTypes 7de7a58
- Remove config.type as function 050b8b7
- Update README 6066f8f
- Add after-class-declaration docs, example & test a878163
- Update README 63ff2ed
v1.9.0
Notable Changes:
- Fix
reflectFromAttribute
to not run onsetAttribute
trigger. f498c24 - Implement
reflectFromProperty
&propTypes
. f498c24- This includes new types that can be set on a property/attribute configuration. Old types still exist, and can still be referred to with
String
andNumber
.
- This includes new types that can be set on a property/attribute configuration. Old types still exist, and can still be referred to with
See README for documentation.
Breaking Changes:
- If you relied on
reflectFromAttribute
from asetAttribute
change, it will no longer run, as it was not the intended behaviour. f498c24
Commits
v1.8.0
Notable Changes:
- New
attribute
property config option, to use a different attribute name than the property name. Also newprotectedAttributes
mixin config option. - Improve web component upgrade process, to handle existing attributes & properties before custom element upgrade/definition.
- Improve default value handling.
- Prevent loop of
setAttribute
-> attribute-changed -> handle change. Edit: almost. see issue below. - Fix
reflectToAttribute
+reflectFromAttribute
behaviour to act how it's expected to. Edit: almost. see issue below.
See README for documentation.
Breaking Changes:
- If properties existed on the element before definition, they may now be handled. 2b422a1
- If you relied on
reflectFromAttribute
from a property change, it will no longer run, as the value is handled then the following attribute-change is ignored if it's the same handled value. e9281ec - If you relied on the internal
Symbol
property to access the internal property config, it has now been renamed, and now uses the attribute as the key. 0910f88
Issue:
setAttribute
is still causingreflectFromAttribute
to run and change the attribute. Fixed in next release.
Commits
- Update .gitignore and .npmignore d4566c0
- Add examples to tests b7b1c77
- Prevent loop of setAttribute -> attribute-changed -> handle change & Fix reflectToAttribute + reflectFromAttribute behaviour e9281ec
- Improve default value handling 9e9576c
- Improve web component upgrade, README & misc code 2b422a1
- Update github actions push workflow & Add old chrome+firefox to workflow bb654d2
- Fix README mistake 89d82e8
- Add directory with examples & Edit README to only have one example 983945b
- Implement alternate attribute names & Improve README 0910f88
- Tests: Disable cypress screenshot on run failure c25f96e
- Improve scripts in package.json c8dec44
- Add exports to package.json e2b78a9
- Cypress v11.1 389b409
- Add some class extend tests 86b1436
- Cypress v11 fe1611b
- Improve Tests 1dbd4dd
- Cypress v10 af6cb83
- Remove package-lock.json bde21cc
- Fix/Improve README c1922b9
v1.7.0
Notable New Features:
- Add
reflectToAttributeInConstructor
property option. - Add
delayChangeInConstructor
property option. - Add
propertyDefaults
constructor option.
See README for documentation.
Breaking Changes:
- Previously, some false changes would fire during constructor if
reflectFromAttribute
was specified. That's now fixed. 0a6740b + 15b823b - Previously, if
reflectToAttribute
orreflectFromAttribute
were a callback while a valid type was specified, it would be ignored. Now it will throw an error in the constructor. 0c78719
Commits
- Improve README
- Add Tests 6b73ed9
- Add propertyDefaults 395e819
- Improve constructor arguments. Add ...argRest 5c900fe
- Add delayChangeInConstructor 15b823b
- Rename to reflectToAttributeInConstructor & remove emit 0a6740b
- Improve getValueFromAttribute to use transformRawValue and check readOnly 3a53e59
- Move set code from attributeChangedCallback to setValueViaAttribute 24f5af8
- Use Symbol instead of WeakMap for propsConfig reference 7a9e0f0
- Error instead when valid type exists with attrib transform callbacks 0c78719
- Add property sorting with order option 1d385ab
- Use .forEach on propsConfig 7011fcb