Daniel P H Fox

Results 345 comments of Daniel P H Fox

Possible API (implemented as part of the `New` function): ```Lua New "Instance" { [Attribute "Foo"] = "bar", -- if a state or computed object, binds to the attribute [AttributeChange "Foo"]...

An alternate possible API from Twitter (adapted from a suggestion by @/bradsharppp): ```Lua New "Instance" { [Attributes] = { Foo = "bar", [OnChange "Foo"] = function(newValue) print("The attribute was changed...

> I personally prefer the first option as it is very similar to the API for normal properties. Agreed - I don't personally see many use cases where a lot...

What's the motivation for this change?

It's interesting to think about how this could lead to errors. What if the user calls a function in the transaction which doesn't expect to be called from a transaction?...

Perhaps another solution is to explicitly pass objects to Fusion for them to be handled safely? ```Lua local a, b = Value(2), Value("foo") batchSet({a, b}, {5, "shoe"}) ``` This avoids...

> This is only necessary as an alternative to #144. If that's added, it implicitly avoids the intermediate calculation if not required. It also easily solves the second comment regarding...

Could also be useful in conjunction with timelines: https://github.com/Elttob/Fusion/issues/11

It's not really the same as a tween - a tween approaches a value over time, whereas a timer constantly ticks upward 🙂