feat(components): add the /components
entry point
#6140
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
📄 Description
The PR updates the stencil config and does the following:
dist
output-target) from./dist/post-components/post-components.esm.js
to./dist/esm/post-components.js
.This new file contains basically the same logic as the old one, but is the direct equivalent for the
cjs
entry point./loader
folder back to the/dist
folder, since it belongs to the Stencildist
output-target.However, users can still import it with
@swisspost/design-system-components/loader
, thanks to the exports definition in ourpackage.json
./components
entry point (generated with the Stencildist-custom-elements
output-target), which provides standalone, none lazy-loading components.They can be used as an equivalent to the formerly removed
/loaders
entry point and are needed for the angular-output-targetoutputType: standalone
approach, which is planned to be implemented soon.Users can import it with
@swisspost/design-system-components/components
.Internally we can use the components with
@swisspost/design-system-components/react
. However, we will never need to do that manually, since the components-react output is generated directly with the help of the stencil config in the compoments package.📝 Checklist