-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Update p5.Vector.js #6831
Update p5.Vector.js #6831
Conversation
- use `...args` - add missing `@return`
The |
@lindapaiste There's a bit of a tradeoff here I think. Named arguments probably will make things slightly clearer but |
It looks like only 3 of these methods do the Maybe I'd see the benefit more if the intermediate variable |
because the origin Besides, according to https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/arguments#description
|
Wondering what the status is on this? Some of my code is currently littered with // @ts-ignore for every vector operation so the return types would be nice. |
Looks good. Thanks! |
...args
@return
Resolves p5-types/p5.ts#123
Changes:
Screenshots of the change:
PR Checklist
npm run lint
passes