-
-
Notifications
You must be signed in to change notification settings - Fork 1
fix: type errors #66
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
fix: type errors #66
Conversation
|
Warning Rate limit exceeded@kazupon has exceeded the limit for the number of commits or files that can be reviewed per hour. Please wait 7 minutes and 17 seconds before requesting another review. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the 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. 📒 Files selected for processing (1)
WalkthroughImproved type safety by introducing a generic type parameter Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes
Possibly related PRs
Suggested labels
Poem
Pre-merge checks and finishing touches❌ Failed checks (1 inconclusive)
✅ Passed checks (2 passed)
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. Comment |
commit: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (9)
deno/README.md(2 hunks)deno/http.ts(2 hunks)deno/index.ts(1 hunks)deno/web.ts(0 hunks)src/h3.ts(0 hunks)src/hono.ts(0 hunks)src/http.ts(2 hunks)src/node.ts(0 hunks)src/web.ts(0 hunks)
💤 Files with no reviewable changes (5)
- src/node.ts
- deno/web.ts
- src/hono.ts
- src/web.ts
- src/h3.ts
🔇 Additional comments (7)
deno/http.ts (2)
19-19: LGTM!The author attribution in the comment improves clarity.
222-224: Excellent type safety improvement!The generic type parameter
T extends unknown[]ensures that the arguments passed tomapToLocaleFromLanguageTagmatch the parameter types expected by the getter function, preventing type mismatches at compile time while preserving runtime behavior.src/http.ts (2)
19-19: LGTM!Author attribution improves comment clarity, consistent with the change in
deno/http.ts.
222-224: LGTM!The generic type parameter addition mirrors the improvement in
deno/http.ts, ensuring consistent type safety across both the src and deno implementations.deno/README.md (3)
37-39: LGTM!Using
deno add jsr:@intlify/utilsaligns with modern Deno dependency management practices.
44-44: LGTM!The
bun addcommand is the standard way to add dependencies in Bun, consistent with other package managers.
77-79: LGTM!Simplifying the README to point to API documentation reduces duplication and establishes a single source of truth for API details.
| /** | ||
| * `@intlify/utils` default module entry. | ||
| * | ||
| * `@inlityf/utils` will export javascript runtime agnostic utility functions and types. | ||
| * | ||
| * @example | ||
| * ```ts | ||
| * import { parseAcceptLanguage, isLocale, getHeaderLocale } from '@intlify/utils' | ||
| * ``` | ||
| * | ||
| * @module default | ||
| */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix typo in module name.
Line 4 contains a typo: @inlityf/utils should be @intlify/utils.
Apply this diff:
-/**
- * `@intlify/utils` default module entry.
- *
- * `@inlityf/utils` will export javascript runtime agnostic utility functions and types.
- *
- * @example
- * ```ts
- * import { parseAcceptLanguage, isLocale, getHeaderLocale } from '@intlify/utils'
- * ```
- *
- * @module default
- */
+/**
+ * `@intlify/utils` default module entry.
+ *
+ * `@intlify/utils` will export javascript runtime agnostic utility functions and types.
+ *
+ * @example
+ * ```ts
+ * import { parseAcceptLanguage, isLocale, getHeaderLocale } from '@intlify/utils'
+ * ```
+ *
+ * @module default
+ */🤖 Prompt for AI Agents
In deno/index.ts around lines 1 to 12, there's a typo in the module description:
replace the incorrect `@inlityf/utils` with the correct `@intlify/utils`
everywhere in the block comment (including the example and description) so the
module name is consistent and accurate; update the comment text accordingly and
ensure no other spelling mistakes remain in that header block.
Description
Linked Issues
Additional context
Summary by CodeRabbit
Documentation
Refactor