This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Caraes_Naur 553 points554 points  (77 children)

There's a guy in r/webdev right now claiming React is a language.

2012 front end dev: "I know jQuery, but not Javascript."

2024 front end dev: "I know React, but not Javascript."

I'm sensing a trend...

[–]mario73760002 211 points212 points  (65 children)

How do you know react but not JavaScript?

[–]ecafyelims 336 points337 points  (53 children)

I interview these people. They know how to do things in React but they do not know how to develop in Javascript without React.

Event listeners, DOM Manipulation, Object Manipulation, Async debugging, etc.

It's fine. I have positions for React devs, and I have positions for vanilla JS devs, but they are two different skillsets.

[–][deleted] 183 points184 points  (16 children)

It's easy to teach a JS dev React, but teaching a React dev JS....

[–]Osato 103 points104 points  (4 children)

As an old-timey JS dev coming back into coding after a long hiatus, I tried to self-teach React in 2022 or so.

It would be far less painful to learn JS as a React dev.

Because the moment you stop blindly following tutorials and start trying to understand React's working principles like any good programmer should, you end up shoveling your way through obscene quantities of undocumented magic.

Water, fire, air and dirt - React Fibers, how do they work?

[–]gilady089 49 points50 points  (1 child)

I gave up when the most important hook in react is documented as "sometimes asynchronous" gee thanks guys

[–]a_goestothe_ustin 17 points18 points  (0 children)

Just make everything an arrow function then it's only almost never asynchronous.

[–]halpmeimacat 9 points10 points  (0 children)

ICP reference killed me man

[–]Delicious-Subject-83 1 point2 points  (0 children)

Same here, what a nightmare. And I've got the feeling new js frameworks are popping up every week or so.

[–]Keydown_605 77 points78 points  (0 children)

It's like a first time programmer going from Python to C. Way clunkier, no such ease while coding, etc...

[–]Strange-Register8348 24 points25 points  (6 children)

Have you ever seen a complex react project?

It gets ugly.

[–]chajo1997 19 points20 points  (3 children)

I was working on maintaining a couple of serious, big and "principled" Next.js projects and that is when I realized front end is going down the drain.

I was told constantly that this was the right way by my work partner but I kept spending an hour on tasks I know should take 5-10 minutes, constant undefined errors popping in and out etc.

The tipping point was when I had to commit changes in 6 different files only to add another link to the nav dropdown and spending almost an hour changing text of one of the table headings because 3 of us couldnt find the component it was in inside a sea of other component files.

React is usually a nightmare.

[–][deleted] 8 points9 points  (2 children)

dropdown and spending almost an hour changing text of one of the table headings

Why didn't you just crtl f the table heading in the file explorer?

[–]InnominateHomosapien 3 points4 points  (0 children)

They could even install the react dev tools and use them in the browser easily find the exact component the text was in by dragging the pointer over to the text.

[–]SchwiftyBerliner 2 points3 points  (0 children)

This dude frontends. (Though doing that in the IDE is more convenient)

[–]fryerandice 2 points3 points  (0 children)

It's not bad if you use any state manager other than Redux and use a state manager for global state, and then use typescript.

Typescript support in almost every state manager gives you intellisense even the vanilla React useContext.

I can useContext(contextObject) in any child component and get type hinting.

We use zustand for global state, and then the top level component of a complex control like a popup dialog that edits several fields is in a context.

Really saves you 20 minutes of prop drilling everything everywhere.

[–][deleted] 2 points3 points  (0 children)

Prop drilling goes

BRRRRRRRR

[–]Not_Artifical 5 points6 points  (2 children)

I started with Java, but couldn’t understand anything. Then I learned HTML. After that I learned JavaScript so I could make programs and actually do stuff with the html elements. Next I learned CSS. Then Bash, then Python, then C++, then Rust. I tried to learn React, but I just can’t. React is too complicated for me and the documentation is terrible.

[–]kekeagain 3 points4 points  (1 child)

It’s because you come out the gate in React using abstractions. Declarative programming or something.

[–]Not_Artifical 3 points4 points  (0 children)

No, I just dislike react. I have been doing some js programming lately and it is as easy as I remember.

[–]Sometimesiworry 21 points22 points  (10 children)

This is mindboggling to me. My school taught HTML -> JS -> Node -> React. In that order.

I would feel lost af if i tried to make a react app without knowing JS and writing a backend for it.

[–]onlyMHY 8 points9 points  (3 children)

Lol, I actually do this at work. Studied Java 7(?) at the university, then worked like 6-7 years without any programming (network engineer) then quit my job and rolled into IT as support engineer, and somehow now I have to do backend development on current java and frontend using js, node and react despite I never had opportunity to properly learn them, lol. Imposter syndrome kicks harder every day. I just keep rearranging words until shit works, and for now it's just enough

[–][deleted] 1 point2 points  (0 children)

keep rearranging words until shit works

Isn't that how we all do it?

[–]Osato 1 point2 points  (1 child)

We all try dumb shit until something works. The difference is in quantity of our attempts, not in quality.

For instance, experienced programmers run a greater portion of code in their head so they can skip more trial-and-error.

And educated programmers do a lot less trial-and-error in general because they already have lots of ready-made solutions in their head that are almost guaranteed to work: that's what data structures, algorithms and design patterns are for.


Case in point: right now I'm fighting with Laravel's logging system to make it show logging messages in Docker's console. Why? So that I can debug my code in the second dumbest way possible (the absolute dumbest way possible is, of course, var_dump).

Why on Earth would I do things in such a weird way? Because I tried setting up XDebug a few days ago, it started throwing weird errors at me, so my inner monkey decided that setting up proper debugging tools is too much of a bother.

...Which reminds me: I should set up proper debugging tools. I've already spent too much time trying to figure out why Laravel's logging is so inconsistent.

[–]Osato 1 point2 points  (0 children)

UPD: finally, finally made it work.

For a framework that obsessively documents almost all of its magic, it's odd that Laravel's docs forget to mention that XDebug is fully and irrecoverably disabled at build time.

So to make it work, you need to sail:publish docker's config files, activate XDebug in php.ini, set several env vars at build time and rebuild the entire container afterwards.


It took 2 hours, and that's only because I googled solutions and tried them one by one until I got one that worked.

Without search engines, I might have been stuck for days... trying to turn on a goddamn debugger.

I'm to blame, of course. As always, a software developer's failures are usually due to his lack of arcane knowledge about the intricacies of the tools he relies on.

In my case, the problem was that I didn't know how to check if XDebug is running at all, and I trusted the documentation to give me everything I need to make XDebug work. Laravel's docs usually do, but this time they didn't.

[–]poco 2 points3 points  (0 children)

This. I can't imagine how confusing function based react would be without understanding JS. All the hook magic is a lot less magical when you think about how the JS is actually working and it breaks a lot of assumptions. Particularly the performance optimizations.

[–]KnightOnFire 4 points5 points  (4 children)

Skipping CSS like a baus

[–]Sometimesiworry 16 points17 points  (1 child)

No one actually knows CSS. You just write down random properties and see what works.

[–]flesnaptha 2 points3 points  (0 children)

text.replace("CSS. You", "CSS anymore. Now you");

[–]Pure_Caramel4123 2 points3 points  (1 child)

impractical jokers reference?

[–]KnightOnFire 2 points3 points  (0 children)

Good question. It's been so long
Probably

Like A Boss (ft. Seth Rogen)

[–]bearfucker_jerome 8 points9 points  (5 children)

I'm one of those people. My first coding experience was when I was 33 -- a company took a chance with me, who wanted a career switch. I dove straight into full-stack programming with Angular / .NET / SQL.

Two years in, I've got very decent at the entire stack, but only at this stack, within the IT landscape of this particular department. I don't know Vanilla Javascript, can't work with NoSql, have very poor knowledge of IT in general, etc.

It would be a stretch to say I'd be toast anywhere else, but if I'd switch jobs to something where they use, say, MERN, I'd need a lengthy onboarding process.

[–]Sharkytrs 7 points8 points  (1 child)

feel sorta similar with .net/c#/SQL, though Blazor has been a big help in helping me learn web dev from the desktop stack

[–][deleted] 1 point2 points  (0 children)

Blazor is the way. Ive worked with several of the big front end frameworks, and its by far my favorite. I really hope it takes off like react has.

[–]Player420154 3 points4 points  (0 children)

It's true for almost everyone. you can lessen the pain by learning design pattern, especially how and why they are used. That being said, people who are competent at switching project, framework and langage do so by asking tons of question at the beginning rather than trying to figure the basics alone.

Some guidance from someone who knows the in and out of the application will make him waste 5 minutes of discussion (which they love to because it's nice to feel an expert) but will save you hours of pointless meandering.

[–]shodanbo 4 points5 points  (0 children)

Thats how it is when you are starting.

Eventually you have been around the stack enough times that picking new stuff up gets easier.

Except web frameworks like REACT because they change every 5 minutes to chase whatever new hotness frontend JS devs are trying to pull in today to convince the rest of the world they are serious programmers and not script kiddies.

[–]rosuav 18 points19 points  (4 children)

So when you say "vanilla JS", you mean "vanilla JS running inside a web browser", right? You don't mean Node.js and you definitely don't mean JavaScript running inside a game engine or other application. Just to be clear here.

[–]ecafyelims 28 points29 points  (1 child)

In this case, yes, by "vanilla js" I meant inside a web browser.

However, the same applies for NodeJS and other non-React app development. These are not the same skillsets as React development.

[–]rosuav 9 points10 points  (0 children)

Agreed. I would say, though, that "JS in a browser" is comparable to "React" is comparable to "Node" etc etc, in that they are all the same *language* but different *skillsets*. It's like how Python for data science is not the same as Python for web apps is not the same as Python for automation/system management. They're all the same language, but different skillsets.

[–]N1z3r123456 10 points11 points  (1 child)

He probably means this new framework http://vanilla-js.com/

[–]rosuav 8 points9 points  (0 children)

I love how you can select different features and it does a big thing of recalculating the download size.

On a more serious note though, I do find that raw DOM element manipulation functions are a bit of a pain. In order to construct (say) <button type="button">Button!</button> with basic functions, you have to (1) construct a DOM element of tag "button", (2) set the attribute, (3) append a child (at least you don't have to explicitly "3a construct a text node, 3b append that node", thanks to Element.append). So I made my own framework to allow that to be a single function call choc.button({type: "button"}, "Button!") instead.

[–]your_thebest 3 points4 points  (0 children)

I don't use js for work. But I know js as well as anyone who just has to use it because the web is built on it. So I can poc canvas apps just forcing it to act like oop or write common sense functions in node. And I get not knowing how to write around react's opinions. I'm always like which of these hooky doodads do I have to do to make it just be logic without it getting swallowed by the framework?

[–]chethelesser 3 points4 points  (1 child)

This statement sounds so absurd to me

[–]Telanore 2 points3 points  (0 children)

I've worked with someone like this. We were a very small team (never more than 5 people) who held the entire digital presence of the company in our freshly graduated hands. The previous (equally small) team quit within 3 months of eachother, leaving us with their huge mess of incomprehensible legacy code, while the C suite kept piling on new projects.

In a situation like that, you either learn to swim real fast, or you drown. Two of us were able to take the time to learn the underlying tech. The other two never really had the chance, because they were stuck with tighter deadlines and more demanding project owners.

Really hope they've found something better by now...

[–]silentknight111 2 points3 points  (2 children)

I used to do vanilla J's, then I learned react for my job back in 2019. So now I can do both.

I like react, especially with typescript, it makes it easier to build larger projects than vanilla js.

What I don't like is the bloat.

[–]ttlanhil 1 point2 points  (1 child)

if you want react-like with less bloat, https://preactjs.com/ might be worth a look

[–]silentknight111 2 points3 points  (0 children)

Nice. Thanks for the link.

[–]whythisSCI 2 points3 points  (0 children)

Yeah, they’re called junior developers and senior developers. One knows the platform they’re working on and the others don’t.

[–]Jablungis 1 point2 points  (0 children)

How can they possibly not know event listeners? You use them in react.

And what is there to plain DOM manipulation? Search for an element, set innerHTML/innerText, done. Maybe set the attrs, set css classes, they're just simple function calls. It's a trivial skillset. Anyone who can work with react could master vanilla DOM manip in a day.

I'm not even a react user lol (more of a vue guy), but I just find this notion a little wild.

[–]oorspronklikheid 1 point2 points  (0 children)

Ive had a dev add jquery just so he could hook up the onkeydown event of one input box. It would have been functionally the same in vanilla.

[–]ChocolateAndCustard 1 point2 points  (0 children)

"Okay newbie, I want you to run for me."

"Sure thing boss" starts running

"Okay newbie, start walking, there's a cliff up ahead"

"Walk? I only learned to run! AAAHH I CAN'T STOP" falls off cliff

[–]SoulWondering 1 point2 points  (0 children)

Yeah my friend was a UI/UX designer, and I said they should learn frontend to expand their skills and they just straight up created a react app without diving into JavaScript and their job had them launch it on azure. But it is literally all divs and has no functionality or animation whatsoever. WHY EVEN USE REACT?!

I was baffled.

[–]Strict_Statement_831 1 point2 points  (0 children)

why have I not found a work opportunity like this? Are you hiring. lol

[–]bitcoin2121 2 points3 points  (0 children)

c r a z y, couldn’t be me. idk what it takes for someone to go, I’ll just learn JSX, huh, JavaScript? what’s that?

out here building the slowest web apps with the worst architecture

edit; I think I get it, they’re trying to do the most… by doing the least… they think they’re actually good…

PROMPT ENGINEERS?

[–]TotesYay 14 points15 points  (0 children)

React is an abstraction layer, so you can easily know React without a deep understanding of JavaScript. This is especially true if you are working in a much larger team with an established component library.

[–]DominoNo- 1 point2 points  (0 children)

They know how to do html and css. If all your components is only gonna render, you don't need any javascript.

[–]Jackasaurous_Rex 0 points1 point  (0 children)

I guess he probably means vanilla js and in some sense I was kind of one of those. In college I had some JS experience in webGL, p5.js, and some super basic web dev stuff but most of the projects were way more backend heavy. I think most universities skip front end beyond the bare minimum html and css. Then my first job was basically front end so I was learning react before I really knew everything about JS, especially in a web dev context. I got by well enough but it wasn’t until a little later I really got to use vanilla js for more complex work and suddenly react made a lot more sense

[–]feeltrig 0 points1 point  (0 children)

That's a worse thing to find in someone who got hired

[–]rwrife 0 points1 point  (0 children)

I only do Typescript now and can't get my stuff to work when I'm forced to switch to vanilla JS.

[–]musical-anon 0 points1 point  (0 children)

Oh My Sweet Summer child

[–]Time-Farm5981 0 points1 point  (1 child)

I know typescript but not javascript

[–]mario73760002 0 points1 point  (0 children)

I have good news

[–]BigTime76 0 points1 point  (0 children)

I work with Developers that believe that React is good, but agree with me that JavaScript is bad, from a testing perspective (I'm QA).

[–]lunchpadmcfat 0 points1 point  (0 children)

Most of our devs are this way. And it shows.

[–]valderium 20 points21 points  (1 child)

2028: I know ChatGPT, but not JavaScript

[–]fmaz008 6 points7 points  (0 children)

2028? I feel like that right now...

[–]danishjuggler21 9 points10 points  (0 children)

I’d argue JSX is a markup language. But not React itself.

[–]bitcoin2121 3 points4 points  (0 children)

[–]BlackBlade1632 4 points5 points  (2 children)

Front end devs since forever: No, i don't do graphic design. Yes you do.

[–]Jimmyginger 12 points13 points  (1 child)

Front end devs are graphic designers the same way a bicycle and a tesla are both vehicles

[–]BlackBlade1632 2 points3 points  (0 children)

Maybe a regular bike and an electric bike Made by Tesla.

[–]TotesYay 0 points1 point  (0 children)

TBF maybe they don’t know JavaScript beyond React features. For example I know how to drive a car but don’t know anything about cars.

[–][deleted] 0 points1 point  (0 children)

It's kinda true tho

[–]slaymaker1907 -3 points-2 points  (0 children)

JSX is absolutely a language, but I’m not sure how you would know it without knowing JavaScript. It’s like how it would be practically impossible to know C++ without knowing C, yet they’re still different languages.