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

feat: Publish web-types.json's TypeScript definitions independently of Vue dependencies #83

Open
maxpatiiuk opened this issue Jun 21, 2024 · 3 comments

Comments

@maxpatiiuk
Copy link

The [vue-docgen-web-types](https://www.npmjs.com/package/vue-docgen-web-types) package provides TypeScript definitions for web-types.json

I would love to use those TypeScript definitions in my Lit library, but I can't because that package installs a lot of vue dependencies, which I don't need in my Lit library.

@vue/compiler-core@npm:3.4.29, @vue/compiler-dom@npm:3.4.29, @vue/compiler-sfc@npm:3.4.29, @vue/compiler-ssr@npm:3.4.29, @vue/shared@npm:3.4.29, and 34 more (+1.03MB)

It also wants to have "vue" as a peerDependency

To make using web-types in non-Vue libraries easier, could you please publish the typescript definitions independently or Vue dependencies?
Thank you

@piotrtomiak
Copy link
Collaborator

Hi @maxpatiiuk. The vue-docgen-web-types package is dedicated for Vue projects. It will not create anything for Lit Components AFAIU. Please choose some dedicated solution for Lit components. WebStorm also support Web Component Manifest format and I think there is tooling out there to generate it for Lit components.

@maxpatiiuk
Copy link
Author

maxpatiiuk commented Jul 18, 2024

The vue-docgen-web-types package is dedicated for Vue projects. It will not create anything for Lit Components AFAIU

To clarify, I do not want to use vue-docgen-web-types for generating anything.
All I want is get the TypeScript .d.ts type definitions for web-types.json - such definitions are currently present in the vue-docgen-web-types package, rather than as a standalone package.
(then, I will use this plugin to generate web-types.json)


To have web-types.json be usable for non-Vue web component projects, it's schema should be published as a standalone NPM package.
For reference, take a look at this package from custom-elements-manifest: https://www.npmjs.com/package/custom-elements-manifest

@piotrtomiak piotrtomiak reopened this Jul 18, 2024
@piotrtomiak
Copy link
Collaborator

Sorry for misunderstanding! I will try to publish the package with .d.ts file, but I am going for vacations now, so it may take some time.

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

No branches or pull requests

2 participants