Skip to content

Make language fully declarative #97

Answered by ogoffart
spersson asked this question in Ideas
Discussion options

You must be logged in to vote

I like your idea of marking properties mutable [...]. But how would it work together with libraries of components? If a library does not have the mutable keyword for a property then users of this component can't change it from event handlers?

I think the key is that we would not mark the property itself as mutable but the binding. Which is why the binding is on the right hand side.
But perhaps we need both: a way to mark the property as const (so that nobody can change it) and a way to mark the binding as read-only (so that once assigned it can no longer change from the same component) and ideally const or read only would be a default unless specified otherwise. We just need to find a g…

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by aurindam
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Ideas
Labels
None yet
2 participants