-
-
Notifications
You must be signed in to change notification settings - Fork 1
Releases: beforesemicolon/markup
Releases * beforesemicolon/markup
Release 1.0.0
Markup finally V1 with a lot of simplification and improvements.
const [count, setCount] = state(0);
const incCount = () => setCount(prev => prev + 1);
const decCount = () => setCount(prev => prev - 1);
const temp = html`
<p>Count:${count}p>
<button type="button" onclick="${incCount}">+button>
<button type="button" onclick="${decCount}">-button>
`;
temp.render(document.body);
const incCount = () => setCount(prev => prev + 1);
const decCount = () => setCount(prev => prev - 1);
const temp = html`
<p>Count:${count}p>
<button type="button" onclick="${incCount}">+button>
<button type="button" onclick="${decCount}">-button>
`;
temp.render(document.body);
New Stuff
- Now you create side effects for your state, and it supports a return value of any type for tracking and caching
- Support for object attribute
which allows for dynamic attribute setting - introduces
onMovelifecycle for when the template is moved - introduces parentNode property
- introduces the
insertAftermethod as a way to render the template - create docs website from .md files
- introduces the @beforesemicolon/router
Improvements
- auto detect state usage and automatically handle template
- state only broadcasts when values change
- state updates are batched
- optimize render and DOM elements creation where needed
- calling lifecycles multiple times will no longer keep all callback functions. only the last one will be used
- improves performance and internal logic with cached templates, easy cleanups, badged state updates, and more
- extend repeat to accept Set, Map, and object literals
- update builder to use @bfs/builder
- improve@bfs/WebComponent packages with new Markup
- improves
suspenseto run with template rendering instead of on definition
Deprecated
- deprecates helper and Helper. Now you can just create functions that use state inside and they will be reactive by default.
- deprecates attr prefix and dotted attributes, e.g:
class.active="...",style.primary="..."as now these can dynamically be set with injected function values - deprecates
onDestroy. it can be provided as the return value ofonMountmethod - changes event listeners options syntax from
to - renamed
nodesproperty tochildNodes
What's Changed
- Bump the npm_and_yarn group across 1 directories with 1 update by @dependabot in #12
- Next by @ECorreia45 in #14
- Update documentation.scss by @ECorreia45 in #15
- Bump the npm_and_yarn group across 1 directory with 2 updates by @dependabot in #19
- Release 1.0.0 by @ECorreia45 in #17
Full Changelog: 0.15.0...1.0.0
Assets 3
0.18.0
What's Changed
- restrict
unmountfor only mounted components - Removes the need to use the
attr.prefix in more scenarios. Nowattr.is only needed when you don't have piped conditions - fixes setting and removing empty class error
- improve attr handling in general
- Bump the npm_and_yarn group across 1 directories with 1 update by @dependabot in #12
- Next by @ECorreia45 in #13
- deprecate the "executable" concept for the "dynamic value" concept instead.
- increase test coverage
- reduce client bundle size
- remove the cached nodes when unmounted. Un-mounting clears all and mounting set all up again
- simplify internal logics
Fix bugs related to:
- tracking templates when using deeply conditionally nested templates
- rendered nodes, causing the template to have an inaccurate track of currently rendered nodes
Full Changelog: 0.15.0...0.18.0
Assets 2
Release 0.15.0
c16b038
This commit was created on GitHub.com and signed with GitHub's verified signature.
The key has expired.
- Further removes the need to specify the
attr.prefix for conditional attributes - Fixes internal issues and improve attribute handling in general
Assets 2
Release 0.14.1
4a28a63
This commit was created on GitHub.com and signed with GitHub's verified signature.
The key has expired.
New template lifycycles onMount, onDestroy, and updated onUpdate
Check Docs
What's Changed
- Bump semver from 6.3.0 to 6.3.1 by @dependabot in #1
- make the attr. optional by @ECorreia45 in #7
- Release 1.14.1 by @ECorreia45 in #10
New Contributors
- @dependabot made their first contribution in #1
Full Changelog: https://github.com/beforesemicolon/markup/commits/0.14.1