According to Wikipedia, “reactive programming is a declarative programming paradigm concerned with data streams and the propagation of change.”. So basically if I say a = b + c, a will change when b or c change, and it doesn’t matter how it’s implemented.
a = b + c
Yes, that is true. But the article you are referring to also state that
"in reactive programming, the value of a is automatically updated whenever the values of b or c change, without the program having to re-execute the statement a:=b+c to determine the presently assigned value of a."
In react or VueJS, when a value like a in your example changes, we have to rerun the same code and thereby re-execute the statement a = b + c. Making React or VueJS not reactive by that definition. In SvelteJS, the values are automatically updated as in the definition.
Not sure how Svelte would know what a is without rerunning that code.
In Svelte, we can reassign the value of a without redeclaring the inline function. Which we would have to do in React.
That is one of my points about Svelte being truly reactive.
Not sure what you mean by “redeclaring the inline function”.
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.