Skip to content

Commit 71792dc

Browse files
committed
Add notes
1 parent bb9824c commit 71792dc

File tree

2 files changed

+17
-16
lines changed

2 files changed

+17
-16
lines changed

r&d.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
- We can use `:="{data}"` fro sprae autoinit, since scope has confusing name: `:scope={}`, `:sprae={}`, `:with={}`
7474
-> let's use :prop= for now, since `:={}` can have multiple interpretations
7575

76-
## [ ] What's a use-case for `:={props}` - do we need it? -> likely yes
76+
## [x] What's a use-case for `:={props}` - do we need it? -> likely yes
7777

7878
* {...props} is useful in react components to pass down all unmentioned or unknown props to children
7979
- but sprae is not about componentization
@@ -690,29 +690,29 @@
690690
## [ ] Prop modifiers
691691

692692
- overall seems code complication without much benefit
693-
* [ ] value.bind? value.watch?
693+
* value.bind? value.watch?
694694
- let's wait for use-case: value can be too big to set it every time
695-
* [ ] prop.reflect, prop.observe
695+
* prop.reflect, prop.observe
696696
- let's wait for use-case
697-
* [ ] prop.boolean, .number, .string, .array, .object
697+
* prop.boolean, .number, .string, .array, .object
698698
- let's wait for use-case
699-
* [ ] prop.once, prop.fx ? prop.init?
699+
* prop.once, prop.fx ? prop.init?
700700
- doesn't seem required, let's wait for use case
701-
* [ ] prop.change - run only if value changes
701+
* prop.change - run only if value changes
702702
- seems like unnecessary manual optimization that must be done always automatically
703703
? are there cases where force-update is necessary?
704-
* [ ] prop.throttle-xxx, prop.debounce-xxx
704+
* prop.throttle-xxx, prop.debounce-xxx
705705
- let's wait until that's really a problem
706-
* [ ] prop.class
706+
* prop.class
707707
? what's the use-case
708-
* [ ] prop.next="" - run update after other DOM updates happen
709-
* [ ] prop.fx="" - run effect without changing property
710-
* [ ] x.prop="xyz" - set element property, rather than attribute (following topic)
711-
* [ ] x.raf="abc" - run regularly?
712-
* [ ] x.watch-a-b-c - update by change of any of the deps
713-
* [ ] :x.always - update by _any_ dep change
714-
* [ ] :class.active="active"
715-
* [ ] :x.persist="v"
708+
* prop.next="" - run update after other DOM updates happen
709+
* prop.fx="" - run effect without changing property
710+
* x.prop="xyz" - set element property, rather than attribute (following topic)
711+
* x.raf="abc" - run regularly?
712+
* x.watch-a-b-c - update by change of any of the deps
713+
* :x.always - update by _any_ dep change
714+
* :class.active="active"
715+
* :x.persist="v"
716716
- solvable via nadis
717717

718718
## [x] Writing props on elements (like ones in :each) -> nah, just use `:x="this.x=abc"`

test/optional.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ test("data: base", async () => {
2121
is(el.outerHTML, `<input data-a="1" data-foo-bar="2" data--upper-case="3">`);
2222
});
2323

24+
// NOTE: we don't have :html anymore
2425
test.skip("html: by ref", async () => {
2526
let a = h`<template :ref="abc"><div :text="123"></div></template><x :html="abc">456</x>`;
2627
sprae(a);

0 commit comments

Comments
 (0)