stdlib
stdlib copied to clipboard
refactor: improve type definitions for ndarray array
Resolves #1088
Description
What is the purpose of this pull request?
This pull request:
- Improves type definition of ndarray's
arrayfunction. - Infers return type based on the passed
dtype's value, else usesbufferarguments' type.
Related Issues
Does this pull request have any related issues?
This pull request:
- resolves #1088
Questions
Any questions for reviewers of this pull request?
@Planeshifter From my understanding, I'm assuming the type of buffer argument and the type of buffer property in options argument are the same? Please let me know if otherwise.
Other
Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.
No.
Checklist
Please ensure the following tasks are completed before submitting this pull request.
- [x] Read, understood, and followed the contributing guidelines.
@stdlib-js/reviewers
@Planeshifter could you kindly review this PR?