Live data from Hacker News

Why can't I write code inside my browser?

tomcritchlow.com

21–30 of 624 posts

Re: Why can't I write code inside my browser?

#23

I take the "wtf is user/local/bin in $path?" to be a question from a non-tech person that is interested in learning to code. I can't be sure though since the author stated he has failed to install Node js. Should Chrome have Node JS loaded into it during install? I don't do web-dev so my answer is no. Should there be browsers made for those learning web-dev that come with these? By all means, sure. Go nuts. This also…

This was a real question FYI. I don't know what that means. Googling "Making sure /usr/local/bin is in my $PATH" leads me here: https://stackoverflow.com/questions/19202007/making-sure-usr... So I fire up the terminal and write echo $PATH and then go back to SO to see that it looks like it's all set up correctly. But why do I need to go to SO? Why do I need to fire up the terminal? It just feels too damn hard and too…

It's one of those basic things. Like, when someone says "Make sure you have salt in the kitchen" they say just that, not "Open the first cupboard in your kitchen. See if there is a blue tin with a little girl in a frock carrying an umbrella" and so on and so forth.

The "make sure X is in your $PATH" is its own thing. I sympathize but there is a balance between docs for the expert and docs for the novice. This is closer to the former.

Re: Why can't I write code inside my browser?

#24
Firefox used to have a "scratchpad" for doing code in the browser, albeit somewhat barebones. Unfortunately it was more or less abandoned and eventually removed.

It would have been nice to see it expanded instead. A full on node environment would be a bridge too far IMHO but it would have been great to have added a good way to reuse modules and some more GUI niceties.

It did have full access to the current web page so there would have been security issues with new coders copy/pasting code from the internet. But a revised version could give it its own isolated environment by default.

Re: Why can't I write code inside my browser?

#25

I'm curious if the author has heard of sites like: * https://repl.it/ * https://jsfiddle.net/ I didn't see anything like that mentioned in the article, but I think that you can easily write code inside your browser today. Also, web browsers are already extremely heavy and complicated. That complexity is convenient for end users, but it also has costs, like making it very difficult and expensive to create a new compet…

Mentioned Glitch and Replit in the article - they're great and I love them but there's still something missing about relying on these platforms imho. I think cementing a default coding environment right into the browser would make it a lot more accessible - and actually be much closer to real coding where you're manipulating files and running code. Plus: glitch/replit are quite slow to do any real coding inside of vs…

But why stop there? Let’s bundle something like Excel or Powerpoint, or Photoshop or Final Cut.

If we’re deciding to bundle additional software with a browser, why would a programming environment (chosen based on someone’s favorite language) be top priority?

Re: Why can't I write code inside my browser?

#26
Not all documentation should be aimed at an absolute beginner - the authors point about $PATH seems moot to me, especially considering how easy it is to look up. Should a library also explain how an async function works in JS when introducing its feature that uses promises? Of course not. Any field requires technical knowledge, and we're lucky we live in a world where its increasingly easier to overcome any roadblocks you find. I'm very anti gatekeeping, but if one expects to have every little detail drawn out for them then they're going to struggle in any even slightly complex field.

Overall I dont see how any of their points supported the random "install node by default" conclusion - and the point saying "most" people hate command lines made me physically reel.

Re: Why can't I write code inside my browser?

#27

Earlier quoted context omitted.

This was a real question FYI. I don't know what that means. Googling "Making sure /usr/local/bin is in my $PATH" leads me here: https://stackoverflow.com/questions/19202007/making-sure-usr... So I fire up the terminal and write echo $PATH and then go back to SO to see that it looks like it's all set up correctly. But why do I need to go to SO? Why do I need to fire up the terminal? It just feels too damn hard and too…

It's one of those basic things. Like, when someone says "Make sure you have salt in the kitchen" they say just that, not "Open the first cupboard in your kitchen. See if there is a blue tin with a little girl in a frock carrying an umbrella" and so on and so forth. The "make sure X is in your $PATH" is its own thing. I sympathize but there is a balance between docs for the expert and docs for the novice. This is clos…

Also I'm fairly certain that an explanation of what $PATH is on unixlike OSes and how to manage that is one of the first things one will see when reading any number of dev basics/getting started tutorials. I understand wanting to jump right into writing "real" projects but things like this are why I think spending a little time finding well-written tutorials and doing them makes a big difference when picking up a new language/library/framework/etc.

Re: Why can't I write code inside my browser?

#28

I'm curious if the author has heard of sites like: * https://repl.it/ * https://jsfiddle.net/ I didn't see anything like that mentioned in the article, but I think that you can easily write code inside your browser today. Also, web browsers are already extremely heavy and complicated. That complexity is convenient for end users, but it also has costs, like making it very difficult and expensive to create a new compet…

Mentioned Glitch and Replit in the article - they're great and I love them but there's still something missing about relying on these platforms imho. I think cementing a default coding environment right into the browser would make it a lot more accessible - and actually be much closer to real coding where you're manipulating files and running code. Plus: glitch/replit are quite slow to do any real coding inside of vs…

If you open the dev tools in your browser there's a full sandbox environment right there, not to mention the load of other sites available. I don't see why specifically Node should be installed.

Re: Why can't I write code inside my browser?

#29
post #25

Earlier quoted context omitted.

Mentioned Glitch and Replit in the article - they're great and I love them but there's still something missing about relying on these platforms imho. I think cementing a default coding environment right into the browser would make it a lot more accessible - and actually be much closer to real coding where you're manipulating files and running code. Plus: glitch/replit are quite slow to do any real coding inside of vs…

But why stop there? Let’s bundle something like Excel or Powerpoint, or Photoshop or Final Cut. If we’re deciding to bundle additional software with a browser, why would a programming environment (chosen based on someone’s favorite language) be top priority?

They already put entire desktop environments in some two decades ago. It never took off.

Re: Why can't I write code inside my browser?

#30

I take the "wtf is user/local/bin in $path?" to be a question from a non-tech person that is interested in learning to code. I can't be sure though since the author stated he has failed to install Node js. Should Chrome have Node JS loaded into it during install? I don't do web-dev so my answer is no. Should there be browsers made for those learning web-dev that come with these? By all means, sure. Go nuts. This also…

This was a real question FYI. I don't know what that means. Googling "Making sure /usr/local/bin is in my $PATH" leads me here: https://stackoverflow.com/questions/19202007/making-sure-usr... So I fire up the terminal and write echo $PATH and then go back to SO to see that it looks like it's all set up correctly. But why do I need to go to SO? Why do I need to fire up the terminal? It just feels too damn hard and too…

Why do I need to go to Stack Overflow? Being sympathetic I would say that because the Node JS Installer makes the assumption that you know what the PATH environment variable is and you know how directories work.

Why do I need to fire up the terminal? Your OS doesn't do things via GUI like you do, so you need to validate that what it needs is available in the manner it will use.

Too damn hard and too opaque.? How did you learn that Node js was even a thing? You weren't born with the knowledge and everything has a learning curve to it, very few things are truly easy to do starting at the very bottom.

I agree that things need documentation and onboarding. I think we can view the Node js docs similar to a shop manual at a auto repair shop - it will expect you to know what tools are what and how to do certain things.

Post reply on HN