Releases: studiometa/js-toolkit
Releases · studiometa/js-toolkit
v2.0.0-beta.7
Changed
- Improve
withScrolledInViewdecorator performance (#180)
v2.0.0-beta.6
Changed
- Improve services performances (#176)
- Breaking: Events emitted by a component must be configured (#178)
class Foo extends Base { static config = { name: 'Foo', + emits: ['open', 'close'], }; open() { this.$emit('open'); } close() { this.$emit('close); } } - Update NPM dependencies (#177)
Removed
- Breaking: Remove
get:...events to alter$refs,$options,$servicesand$childrengetters (4e29610)
The getters should be overwritten in child classes to alter their value:
class Foo extends Base { static config = { name: 'Foo', }; get $refs() { const $refs = super.$refs; $refs.myCustomRef = document.querySelector('.my-custom-ref'); return $refs; } }
v2.0.0-beta.5
v2.0.0-beta.4
Fixed
- Bump version number in
package.jsonfiles (b25cd3f)
v2.0.0-beta.3
v2.0.0-beta.2
Fixed
- Fix release action (f8895e7)
v2.0.0-beta.1
v2.0.0-beta.0
Changed
- Breaking: Refs are searched from the ones defined in the config only
<div data-component="Foo">
<div data-ref="defined"></div>
<div data-ref="undefined"></div>
</div>
<script>
class Foo extends Base {
static config = {
name: 'Foo',
refs: ['defined'],
};
mounted() {
console.log(this.$refs); // Before: { defined: HTMLElement, undefined: HTMLElement }
console.log(this.$refs); // After: { defined: HTMLElement }
}
}
</script>- Breaking: Refs are no longer resolved to the element's attached Base instance if it exists
<div data-component="Foo">
<div data-ref="bar" data-component="Bar"></div>
</div>
<script>
class Bar extends Base {
static config = { name: 'Bar' };
}
class Foo extends Base {
static config = {
name: 'Foo',
refs: ['bar'],
components: { Bar },
}
mounted() {
console.log(this.$refs); // Before: { bar: Bar }
console.log(this.$refs); // After: { bar: HTMLElement }
}
}
</script>- Breaking: Refs are only resolved when the component is mounted (#137)
- Breaking: Children components are only resolved when the component is mounted (#137)
- Improve typings (2642ab5, #137)
- Improve Accordion component tests (08bc1f2, #137)
- Breaking: remove the autobind of all methods (21d24e3, #137)
- Breaking: change build target to browsers supporting ESM (359cd84, #137)
- Breaking: Replace default export with named export (3a0a22c, #137)
- Breaking: Refactor
OptionsManagerto not update the DOM when setting Array or Object options (56ffe0b, #137) - Improve
withBreakpointManagerdecorator (633d2c5, #137) - Refactor
EventsManagerto useEventListenerobjects (8c0644c, #137) - Refactor the debug method (977b5d3, #137)
- Replace private properties by public properties prefixed by
__(5d0d064, #137) - Breaking: Refactor the config and options management (7556c2f, #137)
- Breaking: Refactor the events' management (b37bc9c, #137)
- Refactor the Service abstract class (b0eeb1e, #137)
- Refactor child components management (05f9040, #137)
- Breaking: Flatten the exports of the
@studiometa/js-toolkit/utilspath (#154) - Breaking: Rename the
pushandreplacefunction from thehistoryutils tohistoryPushandhistoryReplace(#154)
Added
- Add a
memoize(fn)utility (cb6848d, db6bb74, b62deb8, #137) - Add helpers exports to the main entry point (0e7407b, #137)
- Add support for negated boolean options with
data-option-no-...(#143) - Add a withVue2 decorator (#148)
- Add a
withScrolledInViewdecorator (#156) - Add a
scrollToutility (#135)
Deleted
- Breaking: remove legacy helpers (bbbd9cc, #137)
- Breaking: Remove the
$once()method (aee1acc, #137) - Breaking: Remove the
fullbuild (13af657, #137) - Breaking: Delete an obsolete folder level (3aeebb8, #137)
- Breaking: Remove the legacy options management (d9806a1, #137)
- Remove an obsolete import/export (02a1979, #137)
- Breaking: Remove refs resolution to component instance (131c20d, #137)
Fixed
- Fix a bug where the
withBreakpointManagerwas mixing its child instances (8875db6, #137) - Fix a bug where the resize event was triggered by an infinite loop (9006fc2, #137)
New Contributors
- @jeremschelb made their first contribution in #148
Full Changelog: 1.7.3...2.0.0-beta.0
v1.7.3
Fixed
- Fix the version published on NPM with the "latest" tag