Skip to content
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!: refactor to avoid name collisions #152

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

userquin
Copy link
Member

@userquin userquin commented Dec 19, 2024

This PR includes:

  • extract components props to types.ts module and the injection key to helper.ts in both subpackages three and pmndrs
  • renamed all components, component props and composable in pmndrs subpackage export
  • adds .js to all imports in all ts modules and all vue sfc components
  • adds scripts/postbuild.mjs to fix node16 module resolution: right now broken since there is no way to resolve .vue files
  • run previous script in build script
  • adds "typesVersions" to fix node10 types resolutions
  • changes both playgrounds to use the new components from pmndrs
  • tsconfig file in playground to resolve bot subpackages exports via paths entry
  • fixes nuxt playground: use workspace:* protocol to install the package and adds the types to nuxt config file to resolve the import in the index.vue page

We need to add changes to the docs, will be added once this PR approved.

@userquin
Copy link
Member Author

userquin commented Dec 19, 2024

Looks like node10 and bundler will check for .d.vue.ts and .vue.d.ts when importing a .vue file while node16 will check only for .d.vue.ts: I just copy/paste the .vue.d.ts content in the .d.vue.ts file in the scripts/postbuild.mjs:

image

Without last commit:

image

@userquin userquin marked this pull request as draft December 20, 2024 13:26
@userquin
Copy link
Member Author

userquin commented Dec 20, 2024

This PR will be superseded by 2 new PR, one to fix node16 types and one for the renaming...

I'm preparing the PR to fix the node16 types.

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