Skip to content
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

String values for motionPath array in Typescript #578

Open
7ingyu opened this issue Feb 21, 2024 · 1 comment
Open

String values for motionPath array in Typescript #578

7ingyu opened this issue Feb 21, 2024 · 1 comment

Comments

@7ingyu
Copy link

7ingyu commented Feb 21, 2024

Demo: https://codepen.io/7ingyu/pen/PoLgXKy

image
image

I'm currently using the MotionPathPlugin to animate some fish in a pond. (See above demo for sample code). I generate random paths for the fish the swim. I am currently using vh and vw values for the path array. It works fine in the codepen, but my application is in Typesccript and apparently Point2D and PathObject both require numbers.

Would it be possible to add string as an allowed value type, or would that be a bad idea?

@jackdoyle
Copy link
Member

Interesting, I never really anticipated someone using strings in that way, but I can update the TypeScript definition in the next release to accommodate it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants