Skip to content

What's new in v3.3.0

Choose a tag to compare

@KiranMantha KiranMantha released this 02 Jan 04:15
· 172 commits to master since this release
572d227
  1. revamped readme and improved documentation through github wiki
  2. added support for native observedAttributes and attributeChangedCallback
  3. implemented dom diffing
  4. added latest typescript support

With the addition of dom diffing, PlumeJS now fixed few glaring issues like flickering and loss of focus on current active element when re-rendering. This is done internally and no need to make any changes to existing code base.

While taking webcomponents approach, PlumeJs missed the implementation of native support for observedAttributes.
For Example:

@Component(...)
class MyComponent {
    static observedAttributes = ['data-label'];

    onNativeAttributeChanges(name, oldValue, newValue) {
       console.log(name, oldValue, newValue);
    }

    render() {...}
}

in html

<my-component data-label='test'></my-component>

That's it. whenever the attribute data-label changes, it calls onNativeAttributeChanges of MyComponent. Remember that observedAttributes and ObservedProperties are different as the former is used for html attributes and the later is used for component props.

Full Changelog: v3.1.1...v3.3.0

PS: If there is any build issue after upgrading to latest version, add skipLibCheck: true to the project tsconfig.json file