Skip to content

fix(types): resolve isArrayOfArray type return#6097

Merged
benjamincanac merged 1 commit intov4from
type/fix-array-check
Feb 25, 2026
Merged

fix(types): resolve isArrayOfArray type return#6097
benjamincanac merged 1 commit intov4from
type/fix-array-check

Conversation

@sandros94
Copy link
Member

Discussed privately, minor type issue that is not picked up by vue-tsc.

@sandros94 sandros94 self-assigned this Feb 25, 2026
@sandros94 sandros94 added bug Something isn't working typescript v4 #4488 labels Feb 25, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 25, 2026

📝 Walkthrough

Walkthrough

This PR refactors type annotations in two files. EditorToolbar.vue removes an explicit type annotation on the groups computed property, allowing type inference instead, and adjusts a type cast. In index.ts, the isArrayOfArray function's type signature is refactored from a simple generic accepting A[] | A[][] to a more sophisticated version using nested conditional types. Both changes affect compile-time type behavior without altering runtime logic.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description check ✅ Passed The description relates to the changeset by acknowledging it addresses a minor TypeScript typing issue, though it lacks specific details about what was fixed.
Title check ✅ Passed The title directly addresses the main change—improving the type return of the isArrayOfArray function, which is the primary focus of the pull request.

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

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch type/fix-array-check

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.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 25, 2026

npm i https://pkg.pr.new/@nuxt/ui@6097

commit: cf02659

@benjamincanac benjamincanac changed the title type: fix isArrayOfArray type return fix(types): resolve isArrayOfArray type return Feb 25, 2026
@benjamincanac benjamincanac merged commit 04292d9 into v4 Feb 25, 2026
28 of 31 checks passed
@benjamincanac benjamincanac deleted the type/fix-array-check branch February 25, 2026 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working typescript v4 #4488

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants