Want to study from my in-depth courses?
▶️ Namaste JavaScript - https://namastedev.com/learn/namaste-javascript
▶️ Namaste DSA - https://namastedev.com/learn/namaste-dsa
▶️ Namaste React - https://namastedev.com/learn/namaste-react
▶️ Namaste NodeJS - https://namastedev.com/learn/namaste-node
▶️ Namaste Frontend System Design - https://namastedev.com/learn/namaste-frontend-system-design
We are currently running offers on all our courses, click the links above and don't forget to add coupon code while making payments. You'll find the best coupon codes available at the top banner on our website. 🚀
If you like my videos, then do give me a shoutout over LinkedIn, X(Twitter) or any social media you're active on.
Do tag me, I would love to read your posts!
Thank you for your love and support.
Wish you the best in your career, keep rising! 🚀
- Akshay Saini
Оглавление (3 сегментов)
Segment 1 (00:00 - 05:00)
A few years ago, learning React was a superpower. If you knew how to write React components, you were very much valued in the market. And if you knew how React and Redux work together, if you can write React and Redux code, then you were very high in demand and you were, you know, very much valued by all these big tech companies. Everybody was running behind React and everybody wanted to become a front-end engineer. So, this was the wave that we were riding a couple of years back. But since AI has come into picture, now things have changed drastically. AI can write very, very beautiful React code and there is no doubt about it. Now, since AI has progressed so much, a very big question that comes to everybody's mind is that is it even worth learning React anymore? diving deep into the React internals, understand what's happening behind the scenes? Is it even worth because AI can do almost everything that you want to do, right? It can generate a lot of code and in fact, good code also, right? To an extent. So, is it even worth learning React? This is what I am going to answer in this video. Since AI has become a major part of development, now every developer is using AI. So, writing code in React has definitely changed. I have been using AI to code since a lot of time now. I have built a lot of front-end applications, a lot of back-end applications using AI and I have a decently fair hands-on experience using AI into coding. Now, what I have observed is there are few problems that are there when we use AI into the coding, right? Suppose if I want to build a front-end application using AI, there are few problems. We need to understand these problems properly. That is when we will understand whether learning React is even worth it or not. Let's discuss these problems, understand very carefully and please, please pay attention over here, okay? So, now when I was using React, so there were few problems that I faced. Now, the problems were different in new projects and if I were using AI in my existing projects. Right? So, let's discuss these one by one. Very quickly I'll go through them. The first thing is if you are using AI to generate a new front-end project, so what happens is generally whenever AI spits out code, it will generate a lot of code and that code will have a very generic architecture. So, suppose if you are generating a application in one shot, you are not giving a very detailed prompt to it, you are giving a very small prompt, not uh defining a lot of things inside it. So, what will happen? It will give you a generic architecture. And now, this generic architecture can work for certain applications, but might not work for a lot of applications, right? The second thing is devs have stopped thinking deeply. Now, when AI is generating a lot of code altogether, thousands of lines of code, thousands of files, thousands of commit, code here and there, so what happens is developers have stopped thinking deeply. They are just blindly relying on whatever AI is, you know, spitting out. Now, AI is giving them a lot of like thousands lines of code. So, devs generally don't care about what's there in that code, whether the architecture is good or not, whether the folder structure best practices are used or not, component structure and a lot of other things used to be there that developers really don't care about now if they are building a new project using AI. So, that is also a big problem. The third big problem is false sense of productivity. Now, what happens is whenever you are building a new project, you know, there have been a lot of claims on the internet that, okay, I can build a fully functional e-commerce website in like 5 minutes. I just have to give one prompt and it will generate a lot of code. See, the 5 minutes projects that you are building are useless. Trust me. I have been writing code with AI. I'm not saying that AI is bad or something. AI can generate a lot of code, but those 5 minutes projects that you see, basic to-do apps or even if you generate a e-commerce website in those 5 minutes, those apps are worthless to be very honest. Those are not the real applications that are being built inside big tech companies. No. If you feel that, okay, I can write a prompt and it will generate my front-end application and that will be the final perfect front-end application, AI will do everything, then you are fooling yourself, okay? So, what I'm trying to say is it is giving a false sense of productivity. Everybody thinks that, okay, now suppose if I have to build a front-end application, it's just one prompt away. It's not one prompt away. It is much more than that. It's a lot of engineering that goes behind that also. Now, comes the problem, suppose if I'm using AI in an existing project. So, suppose if I use AI in an existing project, the major problem is lacks full context. You know, there are a lot There is a lot of hidden business logic which is written inside the code. So, there is a
Segment 2 (05:00 - 10:00)
lot of bad code which is written inside, you know, your existing projects. There are a lot of, you know, here and there things happening inside your existing projects that AI lacks context of, right? And it will definitely make an error while it is, you know, doing something on your behalf. That's a bigger problem. The other thing is it can generate confidently garbage code. It AI is very good at fooling you. If you don't look at AI carefully, that code carefully, it can generate a lot of garbage code. It will generate it so fast and so confidently that uh you will be surprised, right? Uh if you will ask AI to do something, it will confidently generate a lot of garbage code that will be of no use, right? That's a big problem. The other problem is refactoring is risky, right? Now, suppose if you have to If AI has generated something, now you want to refactor that, it becomes very, very risky if you are using AI because you don't know what it will do. Suppose if it is making changes to some files, it can definitely affect other files also. There are ways you can handle all those things, but what I'm trying to say is these are very common problems that people are facing when using AI and even I have faced when I was using AI in my existing as well as new projects. Now, consistency problem. AI is not very consistent. You will have to be very specific about what you want AI to do, otherwise it can do a lot of random things that you might not want. Uh suppose if you are maintaining separate uh file for a constant functions, AI will generate a constant function and it will put it somewhere else, right? Uh it can It might create a new constant file for you. It might not put exactly where you want it to do, right? Unless you specify it yourself. What I'm trying to say is there are a lot of problems when you are using AI to code in I'm just talking about production level code. If you are just making your side project, you can just give it one shot and it can generate something uh that will look very good in the first glance, but it is not a very good production ready code. Trust me, right? If you are just, you know, using a few prompts and generating a lot of big front-end project out of it, right? So, it's not probably the best code. You need to understand how AI can be used to, you know, uh build front-end applications. You will have to be really, really good at it, right? So, what I'm trying to say is AI has its own pros and it can has its own cons also. It has definitely pros and cons also, right? So, what are the pros? The pros part it is definitely making your life easier. Now, you no longer have to, you know, uh remember a lot of syntax, you no longer have to write everything from scratch, remember a lot of syntax issues, you no longer have to, you know, it helps you in debugging. I'm 100% aligned with it. But what I'm trying to say is there are a lot of cons as well. These were certain cons and a bigger con is that if you are building a production grade, very heavy, big application, then definitely you will have to be a little more smarter yourself. We have not come to a point where anybody who does not know anything about React can just use prompts and can build a front-end application. We have not AI has not reached there yet. I'm not sure how much time it will take, but at least I don't see it happening in near future. After a couple of years, maybe after 5 years, 6 years, AI might be able to do that as well. But what I am seeing right now is today also we need a very good understanding of React as a developer. And the people who say that, okay, the people who are not software engineers, who have not written a single line of code, can think that, okay, they will build front-end applications just by prompting without knowing code, they are just fooling themselves. There are a lot of things that a front-end engineer takes care of. Now, let's go on to important things that what should I focus on? Now, I understood that, okay, AI cannot do everything, right? AI cannot do everything. There are a lot of things that a front-end engineer does. So, and let me also tell you that learning React is very much necessary, even more necessary today. Why? Because AI can generate garbage at a very high speed. So, you as a developer will have to take control of things that AI is doing. If you don't take care control of things that AI is doing, then AI can create a mess in your project that will be very difficult for you to fix later on. And let me tell you if you will ask AI to fix it, it will make a mess even more. So, now as a front-end engineer, if you will definitely have to learn React even today and in fact, it will be even more better if you learn it properly, quickly, and then start using
Segment 3 (10:00 - 14:00)
AI along with it. Now, what where you should focus on, you should focus upon deep understanding. That is still very much valuable. If a person understand React internally, if a developer understand how React works behind the scenes, it can ask AI to do even better job. Even better job, trust me. If a person knows React very good, then they will definitely be able to code much better than somebody who does not know anything to code, right? 100% I'm sure about it. Now, the second thing is you will also have to focus upon component architecture. As I told you, AI gives you a very generic architecture. But, as a senior engineer, you will have to take care of that control of how you are architecting your components. That's very much important. AI sometimes messes up with best practices, so you will have to be very conscious about making sure that what best practices you have to ask AI to implement, and then you as a developer also have to verify whether the AI is following your guidelines properly or not. Security is a major concern. Sometimes, if you are just building one-shot applications using AI, security is a very big concern because AI can do a lot of random things, right? That might not make your app very much secure. So, you'll have to be as a developer very conscious about are you dealing with security in a right way or not? And the same is the case with performance. If you are building an application, you have to, you know, build it in such a way that it is performant. Otherwise, if you'll just rely blindly on AI, and if you're not even using a very good model, if you're using an average model, then it will mess up a lot in performance, trust me. I have seen that myself. Uh if you are using the latest and the best models of Anthropic, that does a very good job of it. But, if you are using a little cheaper models, then it will create a mess in your project, right? project. System design is very important. So, uh you should know a lot about system design. When I say system design, it comes on to networking, security, performance, optimization, offline download, LLD, HLD, component architecture. There is a lot of things in front-end system design. You have to be good at front-end system design. And, of course, the last thing is that you will have to be better at your prompts. Always make sure you are giving detailed controlling what AI is doing. You don't have to just prompt randomly to AI because AI will then generate a lot of random things. You have to give a lot of context to AI. Always use AI as a junior developer, as an intern in front of you. Just like you review every line of code that intern writes, similarly, you'll have to behave along with AI also. You have to dictate a lot to AI that you do this, you don't do this, this is the best practice, this is not the security thing that you need to take care of, you don't have to do this, this is the performance this. So, just like you have to, you know, pay a lot of attention in what intern is doing in your project, similarly, you'll have to do the same thing for AI as well. So, this is all What I'm trying to say is if I come back to the question of is it still learning uh is it even worth learning React anymore? The big answer is definitely yes, and in fact, I would suggest that 100% go and learn React even more. That will make you a developer on steroids, right? Uh it will just improve your learning journey insanely. Uh after learning React, use AI, leverage AI to speeden up your process of development. But, people who don't have the knowledge of React will definitely create a mess, and they will, you know, mess up in the project. I have seen it again and again. People who think that they have never studied React and will just, you know, uh write prompts and make everything make a good front-end application, that's not happening. I have not seen a single person who can build a production grade application by just using AI, right? Uh Right, it's it does not give you really good code, right? Unless you guide it properly. So, you as a developer will have to improve yourself first, then you have to use AI to leverage. So, that's all in this video, my dear friends. Hope you would have understood it. If you have more doubts around anything about AI, about development, about front-end, about back-end, about DSA, about system design, I'm happy to help you here. So, comment down below, and uh you know, I will help you. I will make more videos around the same topic. And please, before you end this video, before you go away from this video, hit that like button. It will motivate me to more make more and more videos. Thank you so much for watching this video till the end. I'll see you in the next one very soon. Namaste.