r/reactjs • • 3d ago

Discussion Beginner learning React + Vite: Should I stick to plain CSS, switch to Tailwind CSS, or use a UI library?

I'm currently learning frontend development with React and Vite, and I want to make sure I'm focusing on the right tools to become job-ready.

Right now, I'm practicing plain CSS to understand layouts and styling fundamentals. However, I see almost everyone recommending Tailwind CSS or component libraries like shadcn/ui and Material UI.

At what point should a beginner move from plain CSS to Tailwind?

Do companies expect you to know Tailwind, CSS Modules, or both?

Are UI component libraries bad for learning when you're trying to build a strong portfolio?

Would love to hear what your workflow looks like in real-world projects!

37 Upvotes

62 comments sorted by

97

u/Ok-Advantage-308 3d ago

Stick to css.

You won’t appreciate tailwind until you try doing everything in css yourself.

19

u/otheyhigh 3d ago • Bravo

This is the most accurate advice (for me personally). Start with CSS to understand how core styling works in the web engines. Once you get a good understanding, try libraries or frameworks to see how they do things differently.

This will help you choose the correct approach based on application setup and requirements.

(Edit) noticed that almost everyone advices the same. So ‘This is the most accurate advice’ applies to all of those all well.

8

u/blindgorgon 3d ago

Another angle to view this from: CSS will always be there. Sure, it will evolve, but it’ll pretty much always be the actual thing handling the view layer styles. Frameworks will come and go.

17

u/rodrigocfd 2d ago

You won’t appreciate tailwind

Tailwind is just glorified inline CSS.

We had a CSS project which was migrated do Tailwind... which later we migrate back to CSS modules. Never again.

5

u/twigboy 2d ago

Ahh glad I'm not the only one thinking that

Tried it out but ended up migrating off tailwind too.

1

u/Dragonasaur 2d ago

Tailwind is the modern Bootstrap, great for getting stuff running without needing all the planning thinking for theming

1

u/Harleny-Quennet 2d ago

do you mean sticking to global stylesheets or using css modules right away so they dont have to deal with class name collisions?

21

u/WitlessMean 3d ago

better to learn css since all the libraries will be replaced at some point and you should know the base tool.

also, css is not hard.

4

u/2hands10fingers 2d ago

I keep hearing from pure backend engineers that css is hard for them. It kinda baffles me.

2

u/TheRNGuy 2d ago

Never heard that from any backend engineers. Also, css is a frontend thing, it's not needed on backend. 

3

u/Ceryyse 2d ago

Yes but you can appreciate that they'll have taken a look at something not their specialty and said, "huh this looks super hard"

2

u/TheRNGuy 2d ago

If they could learn difficult topic such as backend, they should be able to learn another, easier topic.

Even hobbyists can learn it.

2

u/badboysdriveaudi 2d ago

If you can learn inheritance, composition, and polymorphism, then you can learn the mechanics of CSS.

You don’t have to learn every single minute detail of every single attribute in play because all of that can be looked up from a reference guide (Google). Any backend developer worth their weight should be able to pick up CSS.

1

u/aaulia 2d ago

IMHO, simple CSS is fine. The issue is when you start having animation in CSS, conditional rendering, adaptive/responsive handling, all in css. It grew from just styling to containing logic, and it just kinda hard to wrap your head around stuff that seems all over the place, you have css, jsx, ts, and one thing csn be done in any of those, or all of those, without clear distiction.

I guess I'm rambling, lol

1

u/TheRNGuy 2d ago

Not necessary will be replaced. If they will be, it will take 1 day to learn. 

31

u/leonheartx1988 3d ago

Even after 3 whole years of using tailwind I don't appreciate it. I don't like writing classes directly in jsx. I still prefer using css modules

5

u/Vtempero 3d ago

Plain CSS.

4

u/FrBatista 2d ago • Heartwarming

One thing missing from this thread: SCSS. Tailwind gets the attention, but SCSS is still everywhere in production codebases, and it works like CSS rather than replacing it — variables, nesting, partials, mixins — so it teaches you to organize styles the way a professional codebase does. You’ll learn more, and your CSS will be worth more to an employer, if you go plain CSS → SCSS first, and pick up Tailwind when a project requires it. It takes an afternoon once the fundamentals are there, as others here have said. On the libraries question: fine for a project where the UI isn’t the point, not for a portfolio piece meant to show you can style.

3

u/VegetableRadiant3965 3d ago

Plain CSS, then Styled-Components/Emotion.

1

u/TheRNGuy 2d ago

It's even worse for userstyles, because of randomised class names, especially after changes. 

1

u/VegetableRadiant3965 2d ago

I don't think OP mentioned anything about UserStyles.org styles. Also the UserStyles extension is known to steal user data.

1

u/TheRNGuy 2d ago

Because it's underrated problem, but programmers should think of it. 

2

u/behumbleorgethumbled 3d ago

Use css modules and make your own ui library based on Base UI primitives. I ditched Tailwind and went this route recently.

3

u/Velvet-Thunder-RIP 3d ago

id start with css, learn css then move to a new level. Tailwind wont be appreciated yet.

3

u/Ceryyse 2d ago

I can't lie the majority of the people telling you to stick to plain CSS sound like people who have been using it for years and they will have watched all the new fads come and go.

TailwindCSS helps me as a Fullstack engineer because i already know the CSS but the shorthand is great to remember.

Why say more word when less word do trick?

7

u/backwrds 3d ago

hot (but accurate) take: tailwind is for morons.

6

u/tenXXVIII 2d ago

You’re prob everyone’s favorite coworker

3

u/backwrds 2d ago edited 2d ago
<div class="mx-auto flex max-w-sm items-center gap-x-4 rounded-xl bg-white p-6 shadow-lg outline outline-black/5 dark:bg-slate-800 dark:shadow-none dark:-outline-offset-1 dark:outline-white/10">
  <img class="size-12 shrink-0" src="/img/logo.svg" alt="ChitChat Logo" />
  <div>
    <div class="text-xl font-medium text-black dark:text-white">ChitChat</div>
    <p class="text-gray-500 dark:text-gray-400">You have a new message!</p>
  </div>
</div>

... or ...

<div class="message">
  <img src="/img/logo.svg" alt="ChitChat Logo" />
  <div>
    <div class="title">ChitChat</div>
    <p>You have a new message!</p>
  </div>
</div>

4

u/Standgrounding 2d ago

Hard disagree.

-1

u/Ceryyse 2d ago

Still a hot take mate. You claim people who prefer writing shorter words instead of longer words and still achieve the same trick are morons. ',:/

1

u/moniv999 3d ago

Can also try PrepareFrontend platform for practising relevant frontend interview questions.

1

u/minimuscleR 3d ago

Stick to plain CSS. Learn React. Get good at react.

MUI or Mantine or whatever are good when you are learning react but need functioning UI too. Depending on the task. MUI will look default, it will be boring without customization, but if you are wanting to learn how tables work and how to optimise performance, then who cares about the look of the UI.

If you are learning how to write react, how to use props, then just use vanilla CSS. CSS modules is the same thing too.

1

u/Ok_Car_8951 2d ago

first learn plain css, when flexbox and grid come to you then tailwind is 2 days work only

1

u/TheRNGuy 2d ago

Learn CSS and then tailwind. 

Use Tailwind, but add empty class to some tags for userstyle authors.

1

u/chris_abi 2d ago

I think learning plain CSS first is definitely worth it. I'm also learning React with Vite, and understanding Flexbox, Grid, positioning, spacing, and responsive design makes it much easier to understand what Tailwind is actually doing.

I see Tailwind as a productivity tool rather than a replacement for CSS knowledge. Once you're comfortable with the fundamentals, learning Tailwind and a component library like shadcn/ui makes sense.

I'd rather understand how to build and style components myself before depending too much on prebuilt ones.

1

u/ericnishio 2d ago

For learning, definitely focus on plain CSS and learn to build your components from scratch. You’ll learn a lot. Once you’ve had enough experience with CSS you’ll understand the benefits of Tailwind. CSS tools become trivial to adopt once you’ve mastered the basics.

Real projects use different tools and libraries depending on the requirements and scope. For example, some graphic designers use Material UI as a foundation so then it makes sense for you to use Material UI as well. You need to be flexible and adapt to different situations.

1

u/Gloomy_Height_2119 2d ago

Always start with plain CSS, no SCSS or tailwind or any CSS-IN-JS stuff.

Understand how plain CSS works, handling shared styles, component specific styles, managing style conflicts, reusibility.

After that you can go one step ahead and try CSS modules, and tailwind if you like the idea.

1

u/tachyon_bit 2d ago

- Learn vanilla CSS.
- Learn CSS modules.
- Learn CSS preprocessors.
- Learn Tailwind.
- Learn CSS-in-JS.

1

u/namesandfaces Server components 2d ago

Modern CSS went at light speed and IMO it's Tailwind that couldn't catch up. Tailwind doesn't provide enough to humans or agents anymore.

The only thing that Tailwind has that CSS doesn't is compile-time level features like code compression.

1

u/BoBoBearDev 2d ago edited 2d ago

Absolutely learn css-grid and container-query for layout. You can put whatever inside the layout, but you must own the layout yourself. Because css-grid and container query is a standard, it will not change over time.

And I said css-grid and not css-flex, is because css-grid is more fault tolerant, thus making it reliable and predictable. Adding and removing stuff inside the layout doesn't break the layout.

Do not use 3rd party solutions for layout. I don't know why they hate css standards, maybe they are trying to target audiences who has over 10 years old browsers? (for container query, it is 2017).

Anyway, learn those two yourself. The rest is not a big deal, use whatever you like.

1

u/TheRNGuy 2d ago

Use vanilla css and then see if you have problems that tailwind fixes. 

I'd say, both have upsides and downsides...

or you can even use both at same time.

There's no specific time when to learn. Learn whenever you want.

1

u/WanderWatterson 1d ago

If your work is mainly custom UI then just use plain CSS, you probably don't need tailwind, it is more like CSS shortcuts rather than a full abstraction layer on top of CSS

If you need to build UI quickly, then I recommend Mantine or the newer kid in the block Astryx from Meta. However you can still always drop to custom UI by using those UI libraries in headless, you can custom design the UI, while still keeping battle-tested components logic that those libraries offer

1

u/droctagonapus 1d ago

Never hurts to learn vanilla css. You will form opinions on it which will inform what css tools you want to use, if any. Maybe you just need sass. Maybe you just want vanilla css but hate scoping problems so css modules is enough for you. Maybe after using vanilla css tailwind's class approach looks very appealing.

You can't have informed opinions on the latest tooling without knowing what it solves in vanilla css. CSS changes often. It has features that tailwind cant do like many useful things like making new colors from other colors, and you cant use them in tailwind without adding classes to tailwind. Have fun managing that.

1

u/Sunwukung 1d ago

Use vanilla, setup some theme variables (design tokens), prefer scoping styles to components - and build a consistent global baseline typography.

I'd avoid having hard coded numbers/values floating around your CSS unless it's really specific to a particular piece of UI.

A theme file helps centralise stuff like spacing, colours etc. I shudder to think of some legacy projects where there were like 97 different "greys".

https://open-props.style/ I love this library which gives you Tailwind-esque values, without replacing CSS with utility classes

1

u/f13th 2h ago

I'd build a small complete project with plain CSS first, then rebuild it with Tailwind. Something like a landing page with a working contact form, responsive navigation and a few reusable components. You'll understand what Tailwind actually abstracts away and have a better idea of when a component library saves you time.

-4

u/IAm_veg_biriyani 3d ago

in era of AI it doesnt matter

-3

u/mavenHawk 3d ago

This is the only real answer here

3

u/Intelligent-Ad-1424 3d ago

Nah bro, learn to code from scratch and you’ll be more employable because you’ll learn how the browser works under the hood and ultimately understand how to debug and read code better. Code review will always be the bottleneck unless they can change something fundamental about how AI works. They need actual human-level sentience to break that barrier.

4

u/mavenHawk 3d ago

I have been a professional dev for 6 years and I can tell you that all those fundamentals you speak of are down the drain at my very large company. Nobody reads code anymore. I ask someone for a review and they just have their agent do the review. That's it. And this is for server side code. You think people are gonna care about css vs tailwind when they barely care about auth anymore? 

I once cared about tailwind vs css and to make my css as elegant and modular as possible and many other things. But the industry has moved on. No point in answering OP's question any other way.

4

u/Intelligent-Ad-1424 3d ago

I’ve been in the industry for a decade, and the skills are very much still relevant and are quickly returning to the forefront as companies have begun to encounter the limitations, pitfalls, and expenses of current AI technology. If you know what you’re doing it’s easy to see how poor of a job AI actually does.

1

u/mavenHawk 2d ago

I don't agree. If you know what you are doing then you can make AI do a great job. 

2

u/Intelligent-Ad-1424 2d ago

Yes, you can MAKE it do a great job. It doesn’t do it on its own. You as the engineer still need the actual programming skills to be good enough to do that.

1

u/pablobird_dev 3d ago

Stick with plain CSS and CSS Modules until layout fundamentals like flexbox, grid, and the box model feel second nature. Once you understand what CSS properties are actually doing under the hood, picking up Tailwind or shadcn takes an afternoon and makes much more sense.

1

u/MrRoBoT696969 3d ago

Css first tailwind later

1

u/92smola 3d ago

Depends on your aims, I was always the guy who knew css best on any team I worked with and it was the reason that got me in to development, during all these years I realised that it seems like the majority of frontend devs dont like css and never have and they get by just fine, now in the age of ai that is even “worse” or “better” depending how you look at that. If I was interviewing you, I would ask you the same question you are asking here, what are the differences between all of those, plain css, tailwind and ui libraries, what approaches would be better in what kind of a project, for example anything crud/dashboard like is very likely to be built with shadcn and tailwind these days, shadcn itself is just a tailwind wrapper around radix, so those fit together to give you a wide range of pre made ui components that you can then layout and restyle to an extent with tailwind. On the other hand some more branding/communication - visually attractive, interactive designs with some creative layouts etc. doesnt need ready made form ui or anything like that, and even plain css might be better then tailwind to handle those, cause they fit less neatly in to a predefined set of design tokens that tailwind kind of assumes. Good thing for you about tailwind is that its basically just css, just a different methodology, if you understand flex layout on one side you understand it on the other as well, so you can learn those at the same time, just not in the same project, and they will reinforce each other. Again to mention ai, its great to see new people coming in and wanting to learn properly, but tbh I am not sure that in the long run anyone would ever be paid to write css by hand, for now the next level of abstraction is still useful, know what approaches you want to use in the project, ui lib or not, if yes which one and why, if plain css what is the naming strategy, how do we structure css/scss files relative to what they are representing, how to define design tokens and enforce them through the design, then on a higher level, what are your components, how are they organised, which variants do they have, what are their interaction states, how to they all fit together in to a design system, is the design system used on one project only or multiple projects, same stack or different. Oh and I would say skip material ui if you can. I threw a lot of words and concepts here that might be hard to catch on for a beginner, but dig in the age of ai I think we need a way to help juniors at the same time do some fundamentals but then quickly start focusing on the bigger picture is what is still left of the job, so dont worry to much about remembering what the exact combination of css properties you need to set to truncate text, try to be more comfortable jumping to higher levels of abstractions sooner then you would if you were starting pre ai.

0

u/shrodikan 3d ago

FE developer job-ready skills:

- Claude / Codex / Copilot
- MCP servers
- CSS / tailwind
- git
- chrome devtools
- Playwright / vitest / jest
- NVDA / accessibility
- XSS / HTML / CSS sanitization

-3

u/spicy_smegma7 3d ago

You mean like writing BY HAND?

2

u/TheSlowShyGuy 2d ago

Some people still enjoy using their brains

-6

u/augurone 3d ago

I think Tailwind is the best answer for flexibility in a modern React-driven framework, but that is after 15 years of writing CSS in all the ways.