Closed CatchABus closed 1 year ago
Actually, even value
demands that it's used with an input element but I'd really like to see a better solution for preprocessing.
Actually, even
value
demands that it's used with an input element but I'd really like to see a better solution for preprocessing.
After studying and searching for alternate ways to support bind, I close issue as namespace foreign
doesn't give us much of a choice.
Right now,
svelte-native
usessvelte-native-preprocessor
to allow the use ofbind:
directive for any attribute. That is becausesvelte
is strict about which attributes support two-way binding. See #249There are few drawbacks regarding this:
svelte
standards. Only certain attributes should support two-way bindingMy proposal is to:
svelte-native-preprocessor
and remove it from svelte.configbind:value
for inputs andbind:this
for element referencesHere's how I visualize it:
So, one should be able to perform two-way binding using
value
:Then, it's up to {N} users to get used to
value
attribute but compiler will complain about invalid two-way bindings either way. @halfnelson @farfromrefug What do you think about this?