A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/alexlafroscia/ember-cli-stencil below:

alexlafroscia/ember-cli-stencil: Automatic discovery of Stencil.js components for your Ember application

Automatic discovery of Stencil.js components for your Ember application

Stencil provides a great, opinionated process for defining Web Components (custom elements) using TypeScript and JSX. This addon leverages the conventions of Stencil and the Ember CLI respectively to automatically discover Stencil components in your dependencies and pull them into your application without any further configuration needed!

Start by installing your Stencil components as npm modules, as described in the distribution instructions in the guide. Then, install this addon:

ember install ember-cli-stencil ember-auto-import

That's it! Your Stencil components will automatically be detected by the addon and pulled into your application.

Note: ember-auto-import is required for this addon to work correctly.

Since Stencil components are detected automatically, you can just start using any Stencil components discovered in your dependencies without any further configuration required. Props can be passed to them, just like other elements, and events listened to through the {{on}} modifier.

<my-custom-component props={{value}} {{on 'someEvent' this.handleEvent}}>
  Rendering into the slot
</my-custom-component>

If the build seems slow, or you think there are packages missing, you can log some debugging information like so:

DEBUG=ember-cli-stencil:* ember serve

This will report:

If there are any issues around judging a file to be a Stencil collection incorrectly or importing the wrong files, please file an issue.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4