Skip to content

fix: duplicate generated type config naming #2158

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

Merged

Conversation

BobbieGoede
Copy link
Member

@BobbieGoede BobbieGoede commented Apr 5, 2025

I'm running into an issue while implementing nuxt-modules/i18n#3341

In the build it looks like the GeneratedTypeConfig interface gets renamed to GeneratedTypeConfig_2 and is no longer exported, which means we can't augment it.

This is what the type looks like in the build currently:

declare type GeneratedInstanceType = GeneratedTypeConfig_2 extends Record<'legacy', infer Legacy> ? Legacy : never;
export { GeneratedTypeConfig }

@kazupon kazupon added the Type: Improvement Includes backwards-compatible fixes label Apr 5, 2025
Copy link

pkg-pr-new bot commented Apr 5, 2025

Open in StackBlitz

@intlify/core

npm i https://pkg.pr.new/@intlify/core@2158

@intlify/core-base

npm i https://pkg.pr.new/@intlify/core-base@2158

@intlify/devtools-types

npm i https://pkg.pr.new/@intlify/devtools-types@2158

@intlify/message-compiler

npm i https://pkg.pr.new/@intlify/message-compiler@2158

petite-vue-i18n

npm i https://pkg.pr.new/petite-vue-i18n@2158

@intlify/shared

npm i https://pkg.pr.new/@intlify/shared@2158

vue-i18n

npm i https://pkg.pr.new/vue-i18n@2158

@intlify/vue-i18n-core

npm i https://pkg.pr.new/@intlify/vue-i18n-core@2158

commit: 798e28c

@kazupon kazupon requested a review from Copilot April 5, 2025 17:04
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

Comments suppressed due to low confidence (2)

packages/vue-i18n-core/src/types.ts:19

  • Changing the module augmentation comment from '@intlify/vue-i18n-core' to '@intlify/core-base' may disrupt existing augmentations. Please verify that consumers update their augmentation targets accordingly.
+ * declare module '@intlify/core-base' {

packages/vue-i18n-core/src/types.ts:26

  • Re-exporting GeneratedTypeConfig instead of declaring an interface could impact module augmentation functionality. Please ensure that this change fully supports the intended augmentation behavior.
export { GeneratedTypeConfig }

Copy link
Member

@kazupon kazupon left a comment

Choose a reason for hiding this comment

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

LGTM!

@kazupon kazupon merged commit 6ea7900 into intlify:v11 Apr 5, 2025
24 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Improvement Includes backwards-compatible fixes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants