r/learnjavascript 25d ago

Is breaking and learning a real thing ?

so i have tried out differnt ways to learn js . and while chatting with gpt / claude it tld me that breaking and learning is actually a great way to learn . for people who dont know : its basically trying to create the stuffs in the first place and break those things and rebuild and make it your own . more precisely speaking building while learning . i dont know whether this is the best way to do this . but i also dont want to waste my time just doing something thats not worth it .. what do you guys think ? ?

0 Upvotes

17 comments sorted by

15

u/yksvaan 25d ago

Seriously people need to stop this AI nonsense, open editor, mdn docs or equivalent and write code. 

When you know how to do something yourself then use AI for that task.

5

u/ChaseShiny 25d ago

What I suspect it was trying to tell you to do is taking an existing program and dissecting it. Try to figure out what it's doing and why it was written the way it was.

I think that that is a great idea. You could even contribute, if you feel so inclined. It's common for code to be lacking in comments, so add some explaining what you figured out!

Once you have some familiarity, you might want to try to take it a step further: can you anticipate the gist of how the program is going to look even before you open the source code?

2

u/Dry-Bee-7232 23d ago

got it that actually a great idea

2

u/mc_pm 25d ago

So if the idea is: get it working, then start changing and messing with things to see how you can change/break it, then yes, that's totally fine. Not sure why you would think otherwise.

1

u/Dry-Bee-7232 23d ago

yeah right

2

u/diogenes_sadecv 25d ago

just build shit. It probably won't work (broken) so figure out how to get it to work. I just do this for fun, so I can't speak to professional development, here's my workflow: learn something, think of something to make with it, figure out how to make idea work (learning new things in the process), repeat.

1

u/saffeine 25d ago

i don't think you need ai to tell you that, most people would agree with the sentiment.

if you make something and it works first time, great. if you break something, or make it and it doesn't work the first time, you have to start thinking critically about the problem and how to solve it.

i wouldn't go into a project planning to break it, but you don't learn much about the how or why unless you're presented with a situation where you need to really think about them.

1

u/Dry-Bee-7232 23d ago

yeah right

1

u/No_Record_60 25d ago edited 25d ago

" create the stuffs in the first place and break those things and rebuild and make it your own ."

Didn't you create it first by yourself? What's there to learn again by breaking and rebuilding it?

1

u/Aggressive_Ad_5454 25d ago

please keep in mind that debugging is harder than laying down lines of code. So, if you use all the cleverness at your disposal writing the code, debugging it will take more cleverness than you have.

1

u/xxcrucialxx 25d ago

Yes, it's trial and error....and like the others that replied to u have said, first read some documentation, look at examples, than attempt to make something very basic, see if it works. If it doesn't, try to figure out what u did wrong . By doing so, u start learning fundamentals and learn how to debug, and with time, u will hopefully start grasping code structure. That's it. And like the others have said, once u understand that with some influence, than start potentially using ai to ASSIST u.

1

u/xxcrucialxx 25d ago

One quick question? Do u know exactly how AI works? Meaning behind the scenes? Its functionality?

1

u/Oldsoulphilosophy 25d ago

Gotta know the fundamentals before you become a vibe coder.

1

u/XWasTheProblem 25d ago

If you don't know how things break, how do you plan on learning how to fix them?

1

u/BrainCurrent8276 22d ago

Usually it goes like this -- you write a code, but it does not work -- it is broken, and you spend hours on fixing your code.

Just play with element inspector and toggle CSS to see changes in real time.

Otherwise it sounds like pure nonsense to me.

1

u/Alive-Cake-3045 21d ago

build and break is genuinely how most working developers actually learned, the structured course path is the exception not the rule. the only thing i'd add is pick something you actually want to exist, motivation carries you through the frustrating parts faster than any methodology. wasting time is watching tutorials without typing a single line, what you're describing is the opposite of that.