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

feat(bytes): @std/bytes@1.0.0-rc.1 #4651

Merged
merged 2 commits into from May 2, 2024
Merged

feat(bytes): @std/bytes@1.0.0-rc.1 #4651

merged 2 commits into from May 2, 2024

Conversation

iuioiua
Copy link
Collaborator

@iuioiua iuioiua commented Apr 29, 2024

Reviews, please thoroughly review the source code and the documentation of this package and approve once:

  1. You foresee no breaking changes.
  2. Documentation and implementations are satisfactory, make sense, and don't raise concerns.

This is our first time stabilizing a package, so please point out any stones we left unturned in the process.

Closes #4629

@github-actions github-actions bot added the bytes label Apr 29, 2024
Copy link

codecov bot commented Apr 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.36%. Comparing base (3155f00) to head (eb02236).
Report is 4 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4651   +/-   ##
=======================================
  Coverage   91.36%   91.36%           
=======================================
  Files         477      477           
  Lines       37334    37334           
  Branches     5325     5325           
=======================================
  Hits        34109    34109           
  Misses       3164     3164           
  Partials       61       61           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@iuioiua iuioiua marked this pull request as ready for review April 29, 2024 03:16
@iuioiua iuioiua requested a review from kt3k as a code owner April 29, 2024 03:16
@dsherret dsherret self-requested a review April 29, 2024 04:09
@lucacasonato lucacasonato self-requested a review April 29, 2024 07:31
Copy link
Member

@lucacasonato lucacasonato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have looked through the docs, and they look good. All function signatures seem reasonable. No blockers from me.

@iuioiua iuioiua changed the title feat(bytes): stabilize @std/bytes feat(bytes): @std/bytes@1.0.0-rc.1 May 1, 2024
@kt3k
Copy link
Member

kt3k commented May 2, 2024

One thing I noticed is that the 3rd params of copy, includesNeedle, indexOfNeedle, and lastIndexOfNeedle don't exactly follow the style guide rule (Exported functions: max 2 args, put the rest into an options object.).

They all use optional primitive type (offset?: number) as the 3rd param consistently. I personally think this is intentionally in this way, and we don't need to change them (instead we probably should update the style guide)

What do you think?

@iuioiua
Copy link
Collaborator Author

iuioiua commented May 2, 2024

Yeah, that's a great idea. I think options objects suite functions/methods with broader functionality and the potential to expand their functionality in the future. Non-object options suite functions/methods with narrower functionality and are unlikely to expand their functionality in the future. Perhaps this distinction should be noted.

@lucacasonato
Copy link
Member

Yes I agree. I don't think we should make them objects. Let's update the style guide

Copy link
Member

@kt3k kt3k left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@iuioiua iuioiua merged commit e7ce4ff into main May 2, 2024
13 checks passed
@iuioiua iuioiua deleted the bytes-stable branch May 2, 2024 11:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

proposal: stabilize std/bytes
3 participants