Live data from Hacker News

Tailwind UI

tailwindui.com

341–350 of 367 posts

Re: Tailwind UI

#341

Earlier quoted context omitted.

You can extract components: https://tailwindcss.com/docs/extracting-components/ And you can store and access components as code snippets within your code editor (e.g. VSCode), that's how I'd store the bigger Tailwind UI components. When I need a component then I just use a shortcut and pick from a component menu.

i think you're missing the point. extracting "component" as code snippets does nothing if one day your boss tells you to change all the size and colors of all the buttons. you still have to go through your entire site and make the changes manually at every instance... or have the foresight to have a class on every button that you can reference through pure css to make the change without breaking tailwind... but at th…

well... looking at the @apply directive that they have, i think found the answer to this. i've been proven wrong:

https://tailwindcss.com/course/composing-utilities-with-appl...

Re: Tailwind UI

#342
post #178

Earlier quoted context omitted.

> The problem with this IMO is that some enterprising person will just use regular tailwind (or another utility-css framework like tachyons) and re-implement all of these components and give it out for free, circumventing the license and killing the value of this. No because I believe that for every enterprising person wanting to circumvent paying for software, there are that many people who want to support the entre…

Capitalism is about making profit. There will be people who feel nice and want to buy this, but it's really not a reliable business model.

Common fallacy. Historically there has been a system of morals that has governed capitalism. Capitalism is about making a profit but also increasing the general welfare. The true capitalist dream is to make tons of money and bring forth great societal good. It's only now where the US has becoming increasingly amoral that we see the "late stage" capitalism we see today.

Re: Tailwind UI

#343

Earlier quoted context omitted.

Bulma user here. I tried tailwind but it never works for me but the Bulma another hand it works perfectly well.

I finished my frontend work in two days with Bulma. This is someone who had zero experience with front-end development.

Agreed. Bulma is definitely more readable and easier to get your head around.

Re: Tailwind UI

#344

Stealing these components would be a very shitty thing to do, but I'm wondering as to how the authors can protect their CSS library from piracy? (esp. considering the 249$ asking price). Legal action? I'm considering open sourcing a software product I'm working on, but it could mean that I'll be bending over backwards to monetize it, as people can just run straight from source.

In this case they're not even trying to stop piracy cause as with their book "Refactoring UI" none of this stuff is locked behind DRM. You can possibly copy all the HTML and spread it around if you have access but that would be scummy and it's great that the devs here trust the users to not help such an effort and have not added intrusive methods to protect this. The license is also very permissive. For what we poten…

Oh. Refactoring UI is by the tailwind folks. Did not know. This gives me some extra confidence.

Re: Tailwind UI

#345
post #315

Earlier quoted context omitted.

Because I don't want that cognitive overhead of even thinking about what the selector should be. Then what if I have another sub-sub text? Do I make that an h3? An h4? I don't want to have to think about that. I just make it "text-xs" and move on. I don't even need to move over to my css file at all - I stay within my template and stay within my flow. It seems crazy and counter-intuitive at first, but I find that it…

I understand but then why not .card > *:nth-child(1) and then so on down the child list? You could get away with those two selectors to match anything with at least an initial name. No decisions except for the first name. Some editors like Brackets allows you to edit other files online and handles css specially so you can edit it just by hovering over class names, etc.

This sounds very brittle. What if you want to come back in the future and add another section to the component?

Re: Tailwind UI

#346

Tailwind is fantastic. Everyone goes through the initial shock of complaining about the "ugly markup", the violation of separation of concerns, etc. But I've worked in enough large codebases to tell you that the ones that use Tailwind have a more consistent UI, with much less handwritten CSS. Bootstrap sites inevitably devolve into a soup of custom CSS and Bootstrap framework. You end up with lots of verbose class de…

Hey, is any of you Tailwind UI websites public? Would love to see it!

Re: Tailwind UI

#347

Earlier quoted context omitted.

How is that any different from setting CSS in the style attribute of your tag? What happens when you need to update all the "text-sm text-gray-700" to something else? Seems like a step backwards at worst and identical to Bootstrap/Foundation at best. Everyone provides class primitives like that What you're describing offends separation-of-concerns

Reality is more important than technical purity. CSS styles and HTML structure are not separate concerns but tightly integrated in most projects. Using Tailwind (or other atomic css frameworks) makes it easy to reason about styling while staying completely inside HTML during editing. Within a few days, you quickly memorize all the names and can build complex visuals while also benefiting from the well-designed defaul…

[deleted]

Re: Tailwind UI

#349
I used tailwind, not for long, until I found basscss.

It comes down to a css library being a utility that defines clean patterns for extension.

Re: Tailwind UI

#350
post #257

Earlier quoted context omitted.

Someone else mentioned this and as I'm not a Tailwind user either, it made me understood a bit more the principle. text-gray-700 is not a font-weight, it's a color predetermined by the framework. They aren't generated, they are hand picked by a designer. Each addition of 100 is a bit darker. https://tailwindcss.com/docs/customizing-colors/#default-col... So essentially, what's the difference between style="color: gra…

In that case, isn't that basically style="color: var(--gray-500);" with extra steps? I love to see people experiment for the sake of experimentation, but I'd be hesitant to adopt Tailwind as an engineer unless I understood why they weren't just CSS variables.

CSS variables are still relatively new though, unsupported until about March 2018 in all browsers, yet the first commit over TailwindCSS is from Jul 20, 2017, nearly a year before browsers even supported the feature. Even today it seems like 11% of users doesn't have support for variables. Could make sense to add support for variables now, but for the sake of backward compatibility, it does make sense to keep it with classnames too.

I love though that as an engineer you would be hesitant to use Tailwind, but you are not aware of how new variables are.

I think Tailwind seems to make sense for any prototypes works and probably even an MVP for a company that still doesn't have a shared CSS that represent the style of the company.

Post reply on HN