New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[web][fix] Add setValue to InternalAnimatedValue #532
[web][fix] Add setValue to InternalAnimatedValue #532
Conversation
EvanBacon
commented
Jan 1, 2020
- fix How to run examples in Web? #481
- throw errors for better debugging when types are passed incorrectly
- fix software-mansion#481 - add errors for better hints when types are passed incorrectly
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -18,11 +18,17 @@ export class AnimatedParam extends AnimatedNode { | |||
} | |||
|
|||
setValue(value) { | |||
if (!this.argsStack.length) throw new Error(`param: setValue(${value}) failed because argsStack is empty`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small nitpick, IMO this.argsStack.length === 0
would be better here
__onEvaluate() { | ||
if (!this.argsStack.length) throw new Error(`param: __onEvaluate() failed because argsStack is empty`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
^
ya web support is still very unstable but at least the problems can be addressed now. |