Skip to content

chore: migrate from biome to oxlint and oxfmt - #79

Merged
saseungmin merged 4 commits into
mainfrom
chore/oxc
Feb 16, 2026
Merged

chore: migrate from biome to oxlint and oxfmt#79
saseungmin merged 4 commits into
mainfrom
chore/oxc

Conversation

@saseungmin

@saseungmin saseungmin commented Feb 16, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • Chores

    • Migrated lint/format tooling to OxLint/OxFmt, bumped pnpm, and upgraded CI action versions.
    • Consolidated and enriched package metadata (homepage, license, author, repository, publish settings) across packages.
    • Restored/updated package scripts and workspace package manager fields.
  • Documentation

    • Updated and clarified README, localized docs, migration guides, and changelogs for readability.
  • Style

    • Applied consistent code formatting, added format checks, and added editor recommendations/settings.
  • Examples

    • Updated example project scripts (start command).

@changeset-bot

changeset-bot Bot commented Feb 16, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 61e2df8

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 4 packages
Name Type
react-native-youtube-bridge Patch
@react-native-youtube-bridge/react Patch
@react-native-youtube-bridge/core Patch
@react-native-youtube-bridge/web Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai

coderabbitai Bot commented Feb 16, 2026

Copy link
Copy Markdown

Warning

Rate limit exceeded

@saseungmin has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 20 minutes and 3 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📝 Walkthrough

Walkthrough

Adds OxLint/OxFmt tooling and VSCode settings, updates CI and package manager versions, consolidates package metadata across workspaces, applies widespread formatting, and wires a WebView controller into YoutubeView for player lifecycle/control integration.

Changes

Cohort / File(s) Summary
Tooling configs & editor
.oxfmtrc.json, .oxlintrc.json, .vscode/extensions.json, .vscode/settings.json, biome.json
Introduce OxLint/OxFmt configs and VSCode recommendations/settings; remove Biome config.
Pre-commit / hooks
lefthook.yml
Switch hooks to pnpm oxfmt/oxlint and update globs to recursive patterns.
CI / Actions / Release
.github/actions/setup/action.yml, .github/workflows/ci.yml, .github/workflows/release.yml
Bump checkout/setup/action versions, update pnpm/node setup versions, add format check step and switch lint step to lint:ci; string quoting tweaks in release workflow.
Root & package manifests
package.json, pnpm-workspace.yaml, .changeset/shiny-signs-agree.md
Consolidate and add package metadata, add oxfmt/oxlint dev deps, bump pnpm, remove some workspace catalog entries, add changeset marking patches and oxfmt housekeeping.
Per-package package.json updates
packages/*/package.json (core, react, web, react-native-youtube-bridge, example, web/package.json)
Restore/consolidate public metadata, files/exports/main entries, scripts, publishConfig; add/update devDependencies (react, oxfmt/oxlint), set packageManager (web).
Controller wiring & runtime changes
packages/react-native-youtube-bridge/src/YoutubeView.tsx, packages/react-native-youtube-bridge/src/YoutubeView.web.tsx, packages/react-native-youtube-bridge/src/modules/WebviewYoutubePlayerController.ts, packages/react-native-youtube-bridge/src/modules/YoutubePlayer.ts
Add WebviewYoutubePlayerController usage and lifecycle wiring in YoutubeView (createInstance, INTERNAL_SET_CONTROLLER_INSTANCE, INTERNAL_UPDATE_PROGRESS_INTERVAL); import MessageData and MATCH_URL_YOUTUBE; rework some imports and webView source spreading.
Utilities & URL handling
packages/react-native-youtube-bridge/src/utils/youtube.ts
Make URL param assignments explicit (if-statements) and add explicit params (loop, muted, playsinline, rel) to constructed URLs.
Formatting / lint small edits
many TS/TSX files (types, hooks, README and docs across packages, web/.ts(x)/config/, CHANGELOGs, example src)
Widespread formatting, import reorderings, lint comment migrations (biome→oxlint), small signature reflows; README/docs text and sample formatting updates only.
Git / templates / HTML
.gitignore, .github/ISSUE_TEMPLATE/bug_report.yml, web/index.html
Remove VSCode ignore lines, minor template whitespace/quote changes, and reformat viewport meta tag.

Sequence Diagram(s)

mermaid
sequenceDiagram
participant App as React App / YoutubeView
participant Web as WebView / iframe
participant Controller as WebviewYoutubePlayerController
participant Player as YoutubePlayer (internal)
participant Core as Core (MessageData / MATCH_URL_YOUTUBE)

App->>Web: mount + load html/uri (webViewSource)
Web-->>App: onLoadReady event / postMessage
App->>Controller: createInstance(webviewRef, options)
Controller->>Player: initialize / subscribe
Controller->>App: INTERNAL_SET_CONTROLLER_INSTANCE
loop playback
    Web->>Controller: postMessage (player events)
    Controller->>Player: dispatch event / update state
    Controller->>App: INTERNAL_UPDATE_PROGRESS_INTERVAL (progress)
end

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Possibly related PRs

Poem

🐰 I hopped through configs, tidy and spry,
OxFmt trimmed whiskers, Biome said goodbye,
Controllers plugged in, messages play,
Docs polished bright for a brand-new day,
Hooray—code carrots for all who try!

🚥 Pre-merge checks | ✅ 3 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'chore: migrate from biome to oxlint and oxfmt' accurately and directly describes the main objective of the changeset, which is replacing the Biome formatting/linting tooling with Oxlint and Oxfmt across the repository.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/oxc

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Feb 16, 2026

Copy link
Copy Markdown

Deploying react-native-youtube-bridge-example with  Cloudflare Pages  Cloudflare Pages

Latest commit: 61e2df8
Status: ✅  Deploy successful!
Preview URL: https://8169e239.react-native-youtube-bridge-example.pages.dev
Branch Preview URL: https://chore-oxc.react-native-youtube-bridge-example.pages.dev

View logs

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Feb 16, 2026

Copy link
Copy Markdown

Deploying react-native-youtube-bridge with  Cloudflare Pages  Cloudflare Pages

Latest commit: 1943944
Status: ✅  Deploy successful!
Preview URL: https://8bf846cf.react-native-youtube-bridge.pages.dev
Branch Preview URL: https://chore-oxc.react-native-youtube-bridge.pages.dev

View logs

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 5

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (2)
packages/react/src/hooks/useYoutubeVideoId.ts (1)

32-41: ⚠️ Potential issue | 🟠 Major

Avoid derived expressions in dependency arrays.

The dependency array contains a complex derived expression instead of the raw source value. This violates React best practices and suppresses the exhaustive-deps rule, which exists specifically to catch this anti-pattern.

The current approach creates an unintended optimization: if the source object reference changes but the extracted value remains the same, the memo won't re-compute. For example, passing { videoId: 'abc' } followed by a new object { videoId: 'abc' } won't trigger recalculation. While this might be intentional, it deviates from standard React patterns and makes the code harder to maintain.

Use [source] directly in the dependency array and let React handle change detection normally.

CONTRIBUTING.md (1)

107-107: ⚠️ Potential issue | 🟡 Minor

Stale reference to ESLint in the Scripts section.

Line 107 still reads lint files with ESLint, but the project has migrated to oxlint. This should be updated for consistency with the rest of the document.

📝 Suggested fix
-- `bun run lint`: lint files with ESLint.
+- `bun run lint`: lint files with oxlint.
🤖 Fix all issues with AI agents
In @.changeset/shiny-signs-agree.md:
- Around line 1-8: CI failed due to oxfmt formatting issues in the changeset
content that lists the packages ("react-native-youtube-bridge",
"@react-native-youtube-bridge/react", "@react-native-youtube-bridge/core",
"@react-native-youtube-bridge/web"); run oxfmt --write to reformat the changeset
file, review the updated .md to ensure the YAML header and the "chore: reformat
code with oxfmt" body remain correct, then stage and commit the formatted file
and push the commit to update the PR.

In @.oxlintrc.json:
- Line 7: Replace the "nursery": "error" setting in the oxlint configuration
with "nursery": "warn" to avoid CI breakage on oxlint upgrades; update the
"nursery" key in the .oxlintrc.json (the existing "nursery" entry) and, if
desired, promote individual nursery rules to "error" later after they stabilize
rather than keeping the global nursery bucket as an error.

In `@packages/react-native-youtube-bridge/docs/migration-v2.md`:
- Around line 163-165: The code sample shows invalid TypeScript generic spacing
in the playerRef declaration; update the useRef usage for the symbol playerRef
so the generic is written without spaces and includes the nullable type and
initial null value (i.e., use a proper TypeScript generic like
useRef<PlayerControls | null>(null)), ensuring you reference the PlayerControls
type and keep useRef import intact.

In `@packages/react-native-youtube-bridge/src/utils/youtube.ts`:
- Around line 23-28: The code currently skips adding startTime/endTime when they
are 0 because it uses truthy checks; change the conditional in the function that
builds the URL to explicitly check for null/undefined (e.g., replace "if
(startTime)" and "if (endTime)" with checks like "if (startTime !== null &&
startTime !== undefined)") so url.searchParams.set('startTime',
startTime.toString()) and url.searchParams.set('endTime', endTime.toString())
run for 0 values; ensure you reference the same startTime/endTime variables and
the url.searchParams.set calls when making the change.

In `@web/package.json`:
- Line 22: The web package's packageManager field currently uses "bun@1.3.9"
while the root package.json uses "pnpm@10.29.3"; decide on the monorepo-wide
package manager and make them consistent — if the monorepo should use pnpm,
change the "packageManager" value in the web package from "bun@1.3.9" to
"pnpm@10.29.3" (or vice versa update the root package.json to "bun@1.3.9" if bun
is intended); ensure the single canonical value is applied to the
"packageManager" field in both the root package.json and the web package's
package.json.

Comment thread .changeset/shiny-signs-agree.md
Comment thread .oxlintrc.json
Comment thread packages/react-native-youtube-bridge/docs/migration-v2.md Outdated
Comment thread packages/react-native-youtube-bridge/src/utils/youtube.ts Outdated
Comment thread web/package.json
"vite": "^6.3.5"
}
},
"packageManager": "bun@1.3.9"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🌐 Web query:

bun 1.3.9 release notes

💡 Result:

Bun v1.3.9 (published February 8, 2026) release notes highlights: [1][2]

  • bun run --parallel / --sequential: run multiple package.json scripts concurrently or in order, with prefixed output; supports workspaces / --filter plus flags like --no-exit-on-error and --if-present. [1]
  • HTTP/2 fix: net.Server → Http2SecureServer connection-upgrade pattern now works (used by tools like http2-wrapper). [1]
  • bun:test: mock() and spyOn() now implement Symbol.dispose, enabling using for automatic cleanup/restore. [1]
  • Proxy behavior: NO_PROXY is now respected even when a proxy is passed explicitly to fetch() / WebSocket. [1]
  • Profiling: adds --cpu-prof-interval (microsecond sampling interval), matching Node’s flag. [1]
  • Compilation: ESM bytecode is now supported in bun --compile when using --bytecode --format=esm. [1]
  • ARM64 stability: fixes SIGILL crashes on older ARMv8.0 CPUs (e.g., Raspberry Pi 4, AWS a1) by avoiding ARMv8.1-only atomics. [1]
  • Markdown perf: faster Markdown-to-HTML (SIMD scanning) and faster Bun.markdown.react() via tag-string caching. [1]
  • Runtime/JSC upgrade: performance work including SIMD-accelerated RegExp prefix search, RegExp JIT improvements for fixed-count groups, and JIT/intrinsic optimizations for startsWith, Map/Set.size, and trim. [1]

Sources: Bun blog release notes [1] and the GitHub release entry linking to them [2].

[1] (bun.sh)
[2] (github.com)

Citations:


🏁 Script executed:

# Find all package.json files in the repository
find . -name "package.json" -type f | head -20

Repository: react-native-bridges/react-native-youtube-bridge

Length of output: 287


🏁 Script executed:

# Search for packageManager field across all package.json files
rg '"packageManager"' --type json

Repository: react-native-bridges/react-native-youtube-bridge

Length of output: 188


Address packageManager inconsistency across the monorepo.

bun@1.3.9 is a valid release (released February 8, 2026), but the monorepo uses inconsistent package managers: the root package.json specifies pnpm@10.29.3 while web/package.json specifies bun@1.3.9. Ensure this difference is intentional; if the entire monorepo should use the same package manager, align all packageManager fields.

🤖 Prompt for AI Agents
In `@web/package.json` at line 22, The web package's packageManager field
currently uses "bun@1.3.9" while the root package.json uses "pnpm@10.29.3";
decide on the monorepo-wide package manager and make them consistent — if the
monorepo should use pnpm, change the "packageManager" value in the web package
from "bun@1.3.9" to "pnpm@10.29.3" (or vice versa update the root package.json
to "bun@1.3.9" if bun is intended); ensure the single canonical value is applied
to the "packageManager" field in both the root package.json and the web
package's package.json.

@saseungmin
saseungmin merged commit 4993ebb into main Feb 16, 2026
5 checks passed
@saseungmin
saseungmin deleted the chore/oxc branch February 16, 2026 10:45
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.

1 participant