Alpha One
Pre-release
Pre-release
brianmhunt
released this
21 Dec 00:25
·
1321 commits
to main
since this release
This is the second alpha of TKO.
It incorporates a number of changes, fixes a number of edge cases (particularly with the parser), and incorporates the last pre-release binding plugin, fast-foreach.
- Fix negation operator (-) application - integers/floats e.g.
-1
work, as well as variables-x
and expressions-(x + y)
- Use tko.binding.foreach for the
foreach
binding (based on brianmhunt/knockout-fast-foreach) - Add
each
as an alias offoreach
- Parser
- Correct behaviour with dereferencing members of expressions (e.g.
(x || y).z
or(abc || {x: null})['x']
) - Fix canonical (
() => ...
) lambdas - Support C & C++ style comments (knockout/knockout#1524)
- Fix filter/or ambiguity on pipe
|
- Raise an error with anonymous functions
- Fix && and || operator precedence
- Correct behaviour with dereferencing members of expressions (e.g.
- Updated Rollup - changes order of compilation, smaller output
- Fix issue with first rendering of an elseif binding
- Make the
template
binding expose a conditional for else-binding - Expose ko.dependencyDetection
- Make sure
obj.x
usesthis
ofobj
wherex
is a function (e.g.click: model.onClick
hasthis
ofmodel
) - Ensure
obj.x
only usesobj
asthis
whenx
is a prototypal method (and not just a value) - Honour explicit references to
this
(as$data
) - Ensure bindings with multiple filters work as expected
- If available, use a WeakMap for DOM node data (resolves knockout/knockout#2141)
- Fix filters not separated by whitespace (e.g.
value|filter1|filter2
)