Live data from Hacker News

Using Code Snippets in Chrome Developer Tools

alexkras.com

31–40 of 43 posts

Re: Using Code Snippets in Chrome Developer Tools

#31
I know a lot of developers basically treat Google as Jeebus returned, and therefor infallible, but this just seems like unnecessary bloat.

What's next, a JS minifier built into Chrome, so 1% of users can use it as an IDE while everyone else just gets more shit they don't need or want?

Re: Using Code Snippets in Chrome Developer Tools

#32

I know a lot of developers basically treat Google as Jeebus returned, and therefor infallible, but this just seems like unnecessary bloat. What's next, a JS minifier built into Chrome, so 1% of users can use it as an IDE while everyone else just gets more shit they don't need or want?

The editor is necessary to the Chrome Developer Tools, since you can edit existing pages and debug the changes. The Code Snippet functionality is however not necessary (in my opinion), but it's such a small part of Chrome Developer Tools that I'm not sure it qualifies as bloat.

Re: Using Code Snippets in Chrome Developer Tools

#35
post #5

In the 80s home computers shipped with a programming language as their OS (BASIC language to be precise) - today the browser dev tools are the closest equivalent. You can use them on any PC with no additional software - wished it was made more obvious so everyone could experiment with programming like those of us who got their first computer experience 25-30 years ago could do.

Not true , 80s OS language for home computers was 100% Assembly, z80 assembly to exact. Basic was provided as an easy to use scripting language. Modern web tools and languages and frameworks are bloated and fragmented. Actually the only thing that keeps the 80s nostalgia is modern implementations of Smalltalk if you come from Amiga , or lisp if you come from command line CP/M OS. Web Dev is a huge pile of mess and I am surprised how you consider anything but the exact opposite of the 80s home computers.

Re: Using Code Snippets in Chrome Developer Tools

#37
post #9

Earlier quoted context omitted.

The browser has always been the one of the easiest ways of tinkering with programming, but these days our browsers come with sophisticated developer tools unlike anything else installed on an average person's PC. Back when I didn't know anything about compilers I wanted to write 'C++' but didn't understand how I could produce an executable, I instead saved html and js into folder and loaded them up in the browser --…

1980s: Computers come with a BASIC interpreter 2000s: Computers come with a web browser that can run JS 2010s: Computers come with a web browser that can run JS and has some other tools But what was available in the early 1990s, when IBM-compatible PCs had become cheap enough to have at home, but ~everyone ran DOS+Windows? I don't remember there being any way (unless you count BAT files) to easily get started writing…

I don't remember there being any way (unless you count BAT files) to easily get started writing programs.

The DEBUG utility would let you write small utilities in Asm, and PC magazines would publish source code listings in a format suitable for use with it --- the assembler had no labels so any address calculations needed to be done manually, but IMHO that just made it easier for people to see how "code" and "data" are really the same thing interpreted in different ways. It was limited to producing "flat binary" COM files up to 64K in size, but you quickly realise that when using Asm, 64K is a lot of code and a lot of interesting things can be done with far less; most of these utilities were in the hundreds of bytes to single-digit-kilobytes range.

Compare that with today when a compiled "Hello world" binary in C is already larger than the majority of the utilities supplied with MS-DOS...

Re: Using Code Snippets in Chrome Developer Tools

#38
I have always loved Snippets and the whole Chrome Souces ecosystem in general. In fact, I use Sources as my editor of choice over Sublime, Notepad++, etc. I find the "map to local" feature outdoes anything I use from the other editors. Only gripe is I wish snippets were stored as text files (or at least that was an option)... couple weeks ago my Chrome profile got corrupted and I lost like a year of snippets.

Re: Using Code Snippets in Chrome Developer Tools

#39

I know a lot of developers basically treat Google as Jeebus returned, and therefor infallible, but this just seems like unnecessary bloat. What's next, a JS minifier built into Chrome, so 1% of users can use it as an IDE while everyone else just gets more shit they don't need or want?

I doubt it adds much to the download size. DevTools already has a copy of the CodeMirror js library for displaying JavaScript in the debugger with syntax highlighting. I suppose you could strip CodeMirror of all editing functionality, but that sounds like more trouble than it's worth.

Re: Using Code Snippets in Chrome Developer Tools

#40
post #20

Earlier quoted context omitted.

But if you have internet access then you can get almost any dev tool and documentation, but if you don't have access then you probably don't have Chrome or Firefox, and even if you have the browser, it has no offline documentation. The 80s was different because internet access wasn't so widespread.

The dev tools built into browsers also tend to be rather bloated and sluggish; opening Firefox's debugger on my 2010 Core2 Duo laptop pegs the firefox process at 40% CPU just idling. Scrolling is painful. Passable for making a quick change to test an idea but I wouldn't use it as an introduction to an IDE. Then again I suppose I should be grateful it runs at all; Servo browser won't start because it requires a certai…

> The dev tools built into browsers also tend to be rather bloated and sluggish

> Scrolling is painful.

> Passable for making a quick change to test an idea but I wouldn't use it as an introduction to an IDE.

I have the same experience, albeit in Chrome. Using it on "about: blank" and restricting yourself entirely to the console helps (e.g. no debugger, not using the feature described in OP, etc). But at that point it's just a REPL, not an IDE.

Post reply on HN