how chatGPT RUINED programming forever (but not really)

Phil Choi traces how programmers learned before Google and Stack Overflow, then shows how ChatGPT and Copilot fit into that history. He walks through a real example with React Hook Form to show why combining AI tools with actual problem-solving beats relying on any single source.
Chapters
All right, let's go. Two hours later. You know what it, let's just do like this. You can't touch this. You can't touch this. In today's video, we'll take a journey through time to see how programmers used to code, how they adapted to tools like Google and Stack Overflow and where we are today with AI powered coding assistants like GitHub, Copilot and ChatGPT. Let's think about how people coded. Like maybe before, before Stack Overflow or Google Forms, you know, you had textbooks, like big thick textbooks like this one or this one. And you'd have to just, you know, study them and maybe let's just look at it like how people coded before Stack Overflow. All right, so let's just read about it together. So before Stack Overflow, I would think there's books and manuals, documentation. You'd have to like, just try things. I think you'd have to like open up maybe like the source code and you'd have to just start reading about it and like, hey, what does this do? And just have to be super curious because there weren't, there weren't, there wasn't like Stack Overflow in like maybe like 90s. You'd have to just be very curious. So I give a lot of respect to those programmers. I know a couple and they said it was, you know, it was like something new. Nobody knew how to do it and it was really respected at the time. Like, someone who I want to give props to is like the roller coaster tycoon guy. I think the whole, whole thing is written in assembly. Roller coaster tycoon assembly. So yeah, it was programmed by one guy and he, you know, these developers aren't like, I don't really hear about these kind of programmers nowadays where they just, it's just one person, one man team. Now programming is becoming really big and it's done by a bunch of people. It's really amazing what they did and how far programming has come now, you know. But these programmers weren't just writing code. They were laying the foundation for the tools and practices we rely on today. Tools like Google and Stack Overflow turned programming into more collaborative and resourceful practice. Suddenly you didn't need to memorize everything. You can look it up, find examples and learn from other developers. But now, like when I first started coding, what I always do is I always look up what other people did, right? Like, let's just think about something like how to make form validation with react, hook, form and there's just a bunch of blogs, stack overflow. And then if you have a bug like React Hook form not giving error message and you feel like, okay, the validation errors are not showing and using React Hook. So I used to look up this stuff and just keep on looking it up and then you'd find a green check mark and you say, hey, you need to add the message in the required field or just a query if there's an error. And then you kind of figure it out, right? Or I'm sure other people have the same kind of issue on like GitHub forums, react. So GitHub forms, same thing. And I was simply missing on change on the forum. So there's definitely a lot of these. Like you see that like you're not the only one having the issue. Like it's really funny because like maybe when I was first started programming they, you know, they'd always like, okay, what is your level in like JavaScript or like this programming language? And you kind of say like, okay, I think I'm a 7 and 8, but with Google I think I'm an 11, right? Because everything was on Google at the time and it was super good. But like, you know, you definitely have a faster learning curve for beginners and like you can easily collaborate with your code and you can focus on like other people's real world problems and things like this. But one thing happened like, you know, the Control C, Control V developer started happening where they just copied and pasted without learning and debugging became harder because you're actually using other people's work and the original problem solving of like what an actual programmer's job is, right? You're there to solve problems. That was kind of gone from that whole era, I feel. But I mean if you over relied on it. So there's always kind of like a balance of like taking influence rather than copying, right? Like even like my old CTO or whatever, he'd always like give me chunks of code and he'd be like. And I'd be like, do you just want me to put it in the code base? And he'd be like, no, that's for reference. And I was like, okay, that's fine. And then you know, yes, I could use it, but only after I understood it. Now there's just a bunch of resources. But now like let's take the whole, let's take like the same question that I asked before React took form not giving error message, right? And then I go to ChatGPT and I just, I put it in here and incorrect register usage so now error is not accessed properly and it kind of tells you what's going on. And then sometimes people will be like, hey, this isn't good enough, right? So they'll stop it and they'll be like reactive form errors example. And then here's an example of how to handle. And then you just get the example code and then you just start copy pasting it, right? And I don't think that is like the right way to do it. So now what I'm understanding from here is you have an input and you register into the reactive form and then you put these error messages. Like it has to have a min length and a required. And then if any of the errors pop up from this errors that's coming from form state of the username because it's registered as username right here. Then it shows the error and the error username message and the message is what gets kind of used there. And I'm sure there's a lot of these explanations here, but definitely just coding with GPT, just copy pasting, you just become that copy paster from Stack Overflow and it's not that good. There's definitely correct ways to do it. Like you got. You have to read the whole thing. What I'm always used to is GitHub copilot. So for example, I'll have my GitHub copilot here. And let's just say I think I have my completions turned on. So then maybe I just do import react or I know that I have, I need to have state and I know that I need to have some kind of. And it helps me with the auto completion. So then now I can say export default function app. There you go. And then return. There you go. And in the package JSON, I know that I have reactive form here. So let's just do it. Let's go import react, use form from reactive form. All right, now what's going on here? And then I can return a div here. Hello. There you go. So now you guys can see that I have this hello here. Right? So now I need to figure out how to use this reactive form. So there's like a lot of things you have to do, but I have a div. And then let's just put H1 react react code perform. There you go. And then I know that I'm going to need some kind of state. So let's just say email set email equals usestate. And then I'm going to string or null. I'll start off at null. And then I can do const password, set password and it already knows what I want to do. Const confirm password, set confirm password. There you go. And now I know that I need register, handle, submit and watching errors. So there you go. And actually with use form, I don't think I need to set state actually. Okay, so if I look at ChatGPT now I know that I need to register in an input field, right? So there you go. So I have a form errors on name. Okay. And then I have to submit, right? Okay, cool. So from here maybe I'll do a form. Oh crap. I have a div. And then I have a label and then maybe I want the email and then the input and then it'll register the email. Right? But this is telling me to kind of just spread it in. So the email and the label is actually going to be HTML for the email and then I can put an ID on the input. There you go, HTML4. And then I can break out and I could spread the register and it's kind of helping me. Right, and then so, and then these are the error messages required and the, and then this like GitHub, Copilot and ChatGPT and these AI assistants are very good for like regular expressions. So now I know that this is the email regular expression. I see the add symbol, I see the dot, I see that it has to be two or four and okay, so now that is cool. Now what is the form? Missing form has no corresponding. Okay, let's add the form on the bottom. There you go. Guess I don't need to add this name because that's what the form is going to do for us. And then from here I can actually say like this, errors. And then if errors.email it could say invalid email. Right, let's check it out. Email it up. And then in the used form maybe I can do it, you know. There you go. Error occurred, not remembered. Where are they trying to read email? I have this email thing here and actually the register handle submit watch and errors don't come from there. So let's look at the ChatGPT now errors. There's something called form state. So we'll do form state and then the errors pops off of there. So now errors at the errors email. Now go back and then if I actually put the input submit and then what if I put the button submit type submit. What if I did submit and then on click now I can know, I know that it needs the handle submit function and I need to prevent B B prevent default. Now I try to Submit here it should say invalid email, right? You see that? Now style equals color red. Now until I fix this, it won't go away. So that's kind of like a way that I think is you can kind of understand and use react like AI assistant and then you just copy paste. So that's like what people used to do. And then what I say we need a password, right? So I pop in the password. ID is email actually and ID is for password. Password. There you go. What is password? Oh, and then I, what if I just don't add default values? Now here I can say it needs to be at least six characters and required is true. Now if I submit it's going to say invalid and the error message should be invalid password. There you go. Until so now I can say okoyl.contactmail.com Error message goes away. 1, 2, 3, 4, 5, 6 Error message will go away. Now you can submit and you can get the. So now that is kind of how you should use GitHub Copilot. But there are downsides to using this, right? You can over rely on it and stop looking stuff up on Google, right? Because you should actually read the documentation and learn what you're using. So that's why they make like websites like this, right? Reactive form and then you actually start reading it and you know, try to understand. You do like a quick start and you can figure it out. But definitely like a combination of all of them are very good. And I think what you're really training for as a developer is your problem solving skills. So yes, like AI can spit out some code for you, but you know what if that code that the AI spits out has problems, your job is to figure out those problems that are or errors that are happening. And that's something that you have to try and solve and you have to figure out. But if you have, if you don't have that part of your mind kind of built, I feel like you're gonna get stuck a lot more than actually having it help you. And you know, like, like I said, like there's a big potential for the AI to not suggest the right answer and not understand. I'm sure the AI knows, but it's our problem communicating it to the AI. So there is like both parts and if you can communicate it well to AI, you can communicate it well to Google and find the answers there. And if you can communicate it well to Google, I'm sure you can communicate it well to someone that's human and they can help you figure it out. In the right way. So you know, never blindly copy what AI suggests. Take the time to understand the code and how it works. For example, if CoPilot suggests a function, review its logic and see if it aligns with your requirements. And you know, in the end, the best way is to combine everything. We're in a world where AI is here. Thanks for watching. If you found this video helpful, don't forget to like, subscribe and comment below. Let us know how you use AI tools in your coding journey. If I can do it, you can do it too. Coding saves lives.
More from Phil

day in the life of a software engineer | 5 hour productivity | building my dev agency 🔥

day in the life of a software engineer | 3 hour productivity | coding my 6-figure community startup

day in the life of a software engineer | 5 hour productivity | coding our sns startup app LFG

day in the life of a software engineer | 5 hour productivity | creating apps that makes big money






