Skip to content

Conversation

@mmeester
Copy link
Contributor

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

The example in the code for i18n only handles slugs that have a single level, for slugs with multiple levels like /nl/foo/bar, route.params.slug will be ['foo', 'bar'] resulting in foo,bar when transforming it to a string.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@vercel
Copy link

vercel bot commented Jan 26, 2026

@mmeester is attempting to deploy a commit to the Nuxt Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link

coderabbitai bot commented Jan 26, 2026

πŸ“ Walkthrough

Walkthrough

This pull request updates documentation in the i18n integration guide to reflect how slug computation handles array route parameters. The change shows that when route.params.slug is an array, the segments are joined with '/' before applying withLeadingSlash, whereas previously the slug was always converted directly from String(route.params.slug). This affects the resulting slug value used for page cache keys and content queries.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

πŸš₯ Pre-merge checks | βœ… 3
βœ… Passed checks (3 passed)
Check name Status Explanation
Title check βœ… Passed The title clearly and specifically describes the main change: handling slug as an array in the computed property for the i18n documentation example.
Description check βœ… Passed The description is directly related to the changeset, explaining why the fix was needed (handling multi-level slugs that result in arrays) and the problem it addresses.
Docstring Coverage βœ… Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ 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

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 Jan 26, 2026

npm i https://pkg.pr.new/@nuxt/content@3703

commit: 6b7395a

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