I'm trying not to be a hater but really how is this: https://github.com/konstaui/konsta/blob/master/src/shared/cl... better than css or even css in js
Konsta UI – Mobile UI Components Built with TailwindCSS
21–30 of 243 posts
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#22Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#23I originally thought it was something like DaisyUI but for React Native with NativeWind, but this seems quite different, and almost a little strange haha. I'm very impressed by the polish of the project but am curious about the main use case for a library like this. (I guess, in what situation would one want a webpage to feel like a system native app? Potentially this paves the way for PWAs?)
When one has an app that can function as an SPA, wants to distribute outside of app stores but still give a native visual presentation. Currently working on such a side app myself right now. And that I can use this and continue implementing in Vue is a big plus for me.
Konsta UI looks exciting but their Framework7 App Framework looks even more so.
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#24Earlier quoted context omitted.
React doesn't do Web Components, the community is pretty much against them.
Really curious about this. Can you link to some context? We're looking to find the lowest common denominator of expressing UI components and thinking about JSON metadata instead of Web Components. With this, we'd have to implement some adaptor that maps JSON to each UI library, but in our case we really only have to worry about React and Native Mobile.
It is like "you kind of can, but you're on your own" thing,
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#25I'm trying not to be a hater but really how is this: https://github.com/konstaui/konsta/blob/master/src/shared/cl... better than css or even css in js
This is a component you reuse across tons of sites, it's not a one off component you're building for yourself. It's also not just a CSS framework like Bootstrap. This is full CSS + JS component's with functionality, Vue/React/Svelte framework integration, and events built in.
Whether css-in-JS as a whole makes sense beyond these generic component type systems is a good question. There's plenty of complexity introduced.
But for a generic component being used in plenty of use cases - not just UI usecases - but highly interactive JS driven ones as well, then it makes a lot more sense to have styling tied to programming languages and conditionals and options and JS data structures.
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#26Earlier quoted context omitted.
I don't write CSS (normally) and yet I understand every single statement, and can easily find which statement I'd need to change for a given. It's that simple. You could argue "well you should learn CSS!" but at the end of the day, I don't need CSS often enough to want to bother. Frameworks like TailwindCSS have been great for people like me. - Also you went and dug into its guts to find the implementation details, t…
Interesting, I write CSS and react/js all the time, and I don’t understand a bit of that usage example.
"uppercase" => "text-transform: uppercase;"
"duration-100" => "transition-duration: 100ms;"
"px-2" => "padding-left: 0.5rem; padding-right: 0.5rem;"
For someone who knows CSS I don't see it as a big downgrade in readability?
But for someone like me, the right side of that equation isn't something I could go around writing in my HTML, the left form is.
Even if all it's doing is acting as a short form for CSS that allows me to do a "no-no" and embed CSS in my markup, it enables me to be infinitely more productive in CSS than I've ever been.
-
And the reality is, if one day I work on a product that's so cursed with success that breaking that encapsulation starts to bite me:
a) It's rare there won't be a lot about the design that has to change anyways
b) I can hire/pay people who do this stuff for a living.
And in the meantime I'll still get a ton of value from it
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#27One small regret: I wish the library was structured like https://ui.shadcn.com/ , which I love because it allows to copy paste the source code of each component and customize it further in your app, rather than importing a rigid pre made component into your app
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#28Ehm, this remind me that there is https://framework7.io/ too and i spot a similarity on the web sites ;-) IMO Framework7 has way more components available and it can be used in many use cases.
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#29Ehm, this remind me that there is https://framework7.io/ too and i spot a similarity on the web sites ;-) IMO Framework7 has way more components available and it can be used in many use cases.
I am not sure if you are posting in jest but both are published by the same team.
Re: Konsta UI – Mobile UI Components Built with TailwindCSS
#30I'm trying not to be a hater but really how is this: https://github.com/konstaui/konsta/blob/master/src/shared/cl... better than css or even css in js
This is just unfamiliarity IMO. This is a component you reuse across tons of sites, it's not a one off component you're building for yourself. It's also not just a CSS framework like Bootstrap. This is full CSS + JS component's with functionality, Vue/React/Svelte framework integration, and events built in. Whether css-in-JS as a whole makes sense beyond these generic component type systems is a good question. There'…