stdlib icon indicating copy to clipboard operation
stdlib copied to clipboard

refactor: improve type specificity for `utils/group-own`

Open Shubh942 opened this issue 1 year ago • 4 comments

Resolves #1085

Description

What is the purpose of this pull request?

This pull request:

  • Adds generics for improved type safety for the group-own function.

Related Issues

Does this pull request have any related issues?

This pull request:

  • resolves stdlib-js/stdlib/issues/1085

Questions

Any questions for reviewers of this pull request?

No.

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.


@stdlib-js/reviewers

Shubh942 avatar Mar 01 '24 22:03 Shubh942

@Planeshifter @kgryte please review this pr

Shubh942 avatar Mar 01 '24 22:03 Shubh942

@Shubh942 Thanks for your efforts, but as-is this cannot be merged due to various issues:

  • it incorrectly removes the options parameter from the function signature (notice that the returns option also influences the shape of the returned output, see the README.md)
  • irrespective of that, it assumes that the values of the returned record are all string arrays (string[]); while true for the example code, the function is not limited to string values.

Planeshifter avatar Mar 01 '24 23:03 Planeshifter

@Planeshifter I have made the changes.

Shubh942 avatar Mar 02 '24 18:03 Shubh942

@Planeshifter would you please review this PR

Shubh942 avatar Mar 26 '24 12:03 Shubh942