ionic-team / stencil-site

Stencil site and documentation source.
https://stenciljs.com/
MIT License
338 stars 422 forks source link

Document dist-custom-elements output target #765

Closed markacianfrani closed 2 years ago

markacianfrani commented 3 years ago

Stencil version:

 @stencil/core@<any>

I'm submitting a: [x] feature request

Provide documentation on the dist-custom-elements output target. This is a really useful feature that is undocumented. So far I've found it leads to a way smaller bundle size and provides a lighter weight option for users to cherry pick individual components.

Questions to consider:

Additional considerations:

Is dist-custom-elements supposed to used in the Vue output target? The docs mentioned this:

customElementsDir
This is the directory where the custom elements are imported from when using the [Custom Elements Bundle](https://stenciljs.com/docs/custom-elements). Defaults to the components directory. Only applies when includeImportCustomElements is true.

the components directory is the default directory of the dist-custom-elements output target. which makes me think that it was meant for this target. Either way, it works flawlessly with it.

rwaskiewicz commented 3 years ago

Thanks for this! We're going to be looking into this in the near future, although I can't give an exact timeline just yet. In the mean time, I'm going to move this to the stencil site repository, as that's where our documentation lives today. Thanks again!

splitinfinities commented 2 years ago

This is complete! https://stenciljs.com/docs/custom-elements