Skip to content

feat(dart_frog): expose captured request params #1818

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

felangel
Copy link
Contributor

@felangel felangel commented Aug 4, 2025

Status

READY

Description

Type of Change

  • ✨ New feature (non-breaking change which adds functionality)
  • 🛠️ Bug fix (non-breaking change which fixes an issue)
  • ❌ Breaking change (fix or feature that would cause existing functionality to change)
  • 🧹 Code refactor
  • ✅ Build configuration change
  • 📝 Documentation
  • 🗑️ Chore

@felangel felangel self-assigned this Aug 4, 2025
@felangel felangel added the feature A new feature or request label Aug 4, 2025
@felangel felangel requested a review from alestiago as a code owner August 4, 2025 03:37
@felangel felangel added the product: dart frog Issues related to the Dart Frog core library label Aug 4, 2025
/// Returns the url parameters captured by the [Router].
/// Returns an empty map if no parameters are captured.
///
/// The returned map is unmodifiable.
Copy link
Contributor

@alestiago alestiago Aug 4, 2025

Choose a reason for hiding this comment

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

nit: the signature doesn't guarantee is unmodifiable and there doesn't seem to be any test in place to guarantee params is unmodifiable. shall we add a test or update the signature to reflect the statement?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah good call. I'll adjust -- also want to think a bit about whether we can consolidate this and mountedParams which was added a while ago.

Will make some more adjustments later today, thanks for the review!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature A new feature or request product: dart frog Issues related to the Dart Frog core library
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat: Allow routing parameters in middleware
2 participants