Skip to content

refactor: rename overloaded constructors to from* names [codex]#255

Open
jderochervlk wants to merge 25 commits intomainfrom
codex/issue-236-constructor-from-names-carryover
Open

refactor: rename overloaded constructors to from* names [codex]#255
jderochervlk wants to merge 25 commits intomainfrom
codex/issue-236-constructor-from-names-carryover

Conversation

@jderochervlk
Copy link
Copy Markdown
Collaborator

@jderochervlk jderochervlk commented Apr 19, 2026

Summary

  • rename overloaded constructors to from* source-type names
  • keep true default constructors as make()
  • add compile-coverage tests for the renamed constructors
  • model VideoFrame pixel-data constructors as separate ArrayBuffer, TypedArray, and DataView bindings
  • update the branch from current main

Validation

  • npm test
  • npm run format:check
  • ASTRO_TELEMETRY_DISABLED=1 npm run build:docs
  • GitHub Actions CI run #599 passed

tsnobip and others added 19 commits April 17, 2026 17:49
Port the surviving API cleanup from the final pre-alpha branch onto the monorepo split introduced in #249.

This adds the missing concrete modules, translates the fetch/runtime/canvas/websocket/media surface cleanup into the package layout, and keeps the branch green with updated tests.
Drop scroll2/scrollTo2/scrollBy2 and keep the descriptive *XY overload names requested in review.

Co-authored-by: Codex <codex@openai.com>
…with-commits-and-responses

Address review feedback: rename constructors, unbox FormDataEntryValue, reuse MessageEvent types, simplify tests
@jderochervlk jderochervlk changed the base branch from carryover/post-249-pre-alpha to main April 19, 2026 14:10
Comment thread docs/content/docs/contributing/api-modelling.mdx Outdated
Update DOMMatrix, DOMMatrixReadOnly, Path2D, and ReadableStream single-source constructor overloads to take direct unlabeled arguments.

Refresh compile-coverage tests and contributor documentation to match the constructor naming convention.
Comment thread packages/Canvas/src/Path2D.res Outdated
Comment thread packages/Canvas/src/Path2D.res Outdated
Comment thread packages/Canvas/src/Path2D.res Outdated
Remove source-shape callouts from the constructor docs added in this PR.

Rewrite constructor summaries to focus on the ReScript API surface and update the contributor documentation guidance to match.
@jderochervlk jderochervlk marked this pull request as ready for review April 22, 2026 14:13
@jderochervlk
Copy link
Copy Markdown
Collaborator Author

@codex

@jderochervlk jderochervlk changed the title [codex] rename overloaded constructors to from* names refactor: rename overloaded constructors to from* names [codex] Apr 22, 2026
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 2c7ece03a2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/Canvas/src/VideoFrame.res Outdated
@jderochervlk jderochervlk requested review from brnrdog and tsnobip April 22, 2026 14:46
Copy link
Copy Markdown
Member

@tsnobip tsnobip left a comment

Choose a reason for hiding this comment

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

except from the sharedArrayBuffer, the rest looks good to me!

Comment thread packages/Canvas/src/VideoFrame.res Outdated
Replace the unknown SharedArrayBuffer-only constructor surface with a typed-array overload alongside the existing ArrayBuffer and DataView bindings.

Update the compile-coverage test to exercise the new VideoFrame.fromTypedArray binding.
@jderochervlk jderochervlk requested a review from tsnobip May 4, 2026 14:25
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

Successfully merging this pull request may close these issues.

3 participants