

In my personal opinion, I prefer Lit over Stencil because Lit is oriented more as a set of additional features on top of platform features, whereas Stencil is oriented more as a framework. See the ClockController example and adapt to use asynchronous fetch() calls. For your stock ticker example, you could write a reactive controller which updates the host with stock prices based on API calls. You can use a "light DOM as data" approach, assign DOM properties, or use stringified attributes, depending on what works for you. Sure, web components have a variety of means of accepting complex data of any variety. #webcomponents #nextjs #typescript #usetheplatform Then go straight to learning NextJS and adding my UI to NextJS apps.Ĥ) Can I use StylusCSS when making my Lit custom UIs? If so how (I want to write them using html + typescript + stylus syntax)!? Like comment: Like comment: 1 like IF Q 1 and 2 = True, I will learn a web component lib instead of react.

HYBRIDSJS UNPKG SERIES
OR a more complex example is UI widget that displays the stock price in the last week from our DB as a line chart, Will this UI element be able to fetch the 'value' data from our and 'key' data from our backend frameworks DB or will it just appear blank and we have to somehow hook them together? I got the impression in your intro blogs that the dev or user defines the data displayed in a customer element - in this would it would mean each UI element is rendering as a 'static elements', is this assumption wrong?.ģ) Your 'lets build web components 8parts' series did not cover StencilJS, why? I wanted to hear your thoughts of Stencil vs Lit - because I considered defaulting to Ionic UIs (which I think can be tweaked with stencil) and creating my own with stencil/lit when Ionic doesn't fit my UI needs. Can we now create a custom UI element that displays the 'current' which updates every minute from data in our DB rather than interactive user input data.
HYBRIDSJS UNPKG UPDATE
our DB stores and that update every minute. Do you mind clarifying these elementary points please? So I know that I'm on the correct learning path and don't lose 6months on something that may not work.Ĭan web components (in an easy way without thousands of dependencies).ġ) Be used in frameworks like NextJS or does it only work on client side rendered things like react/angular/vue? OR do we not even need a front end library and just use the web components UI (this confuses me, is it web components + Next or web components + nothing)?Ģ) Can they be dynamic and use long lists of data from our backend in our custom UI elements? e.g. I'm a baby dev considering if I should learn web components using Lit. Hybrids is released under the MIT License.Excuse me Benny. The project documentation is available at the hybrids.js.org site. You can read more in the Router section of the documentation.

The component model is based on plain objects and pure functions*, still using the Web Components API under the hood: import from "hybrids"

All of the parts follow the same unique concepts making it easy to understand and use! Quick Look The Simplest Structure It supports building UI components, managing complex states, creating app flows with client-side routing, and localizing its content for the worldwide markets. The main goal of the framework is to provide a complete set of tools for the web platform - everything without external dependencies. Hybrids is a JavaScript UI framework for creating fully-featured web applications, components libraries, or single web components with unique mixed declarative and functional architecture.
