ionic-team / stencil-component-starter

Minimal starter project for building shareable web components with Stencil
https://github.com/ionic-team/stencil
MIT License
278 stars 128 forks source link

How to use a stencli web component in a stencil app? #110

Closed jackchoumine closed 2 years ago

jackchoumine commented 2 years ago

I have a stencil-starter app. I install a web component by npm : npm i web-components-jack then add import 'web-components-jack in my index.ts

this web-components-jack is build by stencil

image

use a web componet in stencil componet then get error:

 Rollup: Unresolved Import
           Could not resolve './dropdown.css?tag=my-dropdown'
           from
           ./node_modules/web-components-jack/dist/collection/components/dropdown/dropdown.js

i import web-components-jack by script tag in html,it works well. how can i fix it?

rwaskiewicz commented 2 years ago

Hey @jackchoumine,

These types of questions are best suited to #technical-questions in the Stencil Slack, where community members help each other out with types of questions like these.

I'm going to close this issue out, as a support question. Thanks again!