Slashdot Mirror


We Need To Reboot the Culture of View Source (wired.com)

theodp writes: Back in ye olde days of the information superhighway," begins Clive Thompson in It's Time to Make Code More Tinker-Friendly, "curious newbies had an easy way to see how websites worked: View Source." But no more. "Websites have evolved into complex, full-featured apps," laments Thompson. "Click View Source on Google.com and behold the slurry of incomprehensible Javascript. This increasingly worries old-guard coders. If the web no longer has a simple on-ramp, it could easily discourage curious amateurs." What the world needs now, Thompson argues, are "new tools that let everyone see, understand, and remix today's web. We need, in other words, to reboot the culture of View Source." Thompson cites Fog Creek Software's Glitch, Chris Coyier's CodePen, and Google's TensorFlow Playground as examples of efforts that embrace the spirit of View Source and help people recombine code in useful ways. Any other suggestions?

305 comments

  1. The JavaScript on most sites.. by intellitech · · Score: 5, Insightful

    ..is intentionally incomprehensible. Whether indirectly through minification or directly via obfuscation.

    I know it's hard for some people to accept, but there is a serious amount of interest (and, rightfully so) in preventing the reverse engineering of website code, or at least, hindering efforts to do so.

    --
    vos nescitis quicquam, nec cogitatis quia expedit nobis ut unus moriatur homo pro populo et non tota gens pereat.
    1. Re:The JavaScript on most sites.. by HornWumpus · · Score: 1, Insightful

      Newbies have no business looking at web pages. It's too much of a fucking mess, it will only scare them off.

      Find something interesting and simple for them to learn on. Yes it will have to be contrived, but so what?

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    2. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 2, Interesting

      But why? A competent developer can duplicate the functionality of most webpages easy enough, so what does obfuscation gain apart from putting off curious newbies?

    3. Re:The JavaScript on most sites.. by KiloByte · · Score: 0, Troll

      Javascript needs to die. While it can be used for good, for one such use there's 10 parallaxative "responsive" webshites.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    4. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 1

      (and, rightfully so)

      I wonder about this. While I understand they want to protect copyright, the real problem is the inability to audit what is executed. It's bad enough without obfuscation to be sure, but it just makes it nearly impossible to operate securely. The only choice is to disable javascript altogether (or use umatrix/noscript for middle ground risk/benefit), and if that doesn't work, just not use the site. In a future which seems increasingly 'webapp'd' with blackbox'd software and hardware, the choice will soon be to accept the invasion or quit using computerized tech altogether. Copyrights should not bypass dominion by device owners, and EULAs which demand it should be considered bullshit.

      As far as I'm concerned, websites will always be second class citizens compared to real desktop software, so I really don't care that web donkeys want to shield their shitty javascript from their fellow js troglodytes. Even if they do manage to kill off client only software, they are still clunky, unreliable, insecure, and ultimately user hostile. They're also ephemeral, which makes it foolish to depend on them for any critical workflow (eg google's web apps vs school systems). It's just too easy to abuse the situation when the user has no control over anything.

    5. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 1

      Because one learns very little of value from contrived examples.

    6. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      wasn't google pushing a 'binary' form of html or web pages at some point a few years ago? that's even worse.

    7. Re:The JavaScript on most sites.. by digitalchinky · · Score: 4, Insightful

      If you kill off Javascript, you also kill off medial image imaging (my line of work) or a thousand other things you depend on but don't realize. Be careful what you wish for. The web is much bigger than the sea of annoying cookie notices, calls to action, and responsive design. Javascript, like or not, gets crap done :-) It's not perfect, but it's not so terrible either.

    8. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Yeah, it was called NiggaClient. It would inject AIDS into your pages.

    9. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      10 print "hello"
      20 goto 10

    10. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      JS isn't going anywhere. Debugging with the stacktrace, runtime errors, and the need for linting is shitty, but JS isn't going anywhere. It has invaded native and embedded systems just as much as responsive designs. One might be tempted to blame SEO rules, etc., but developers needed to step up their game anyways. Old websites were way shittier than 'modern' apps, in many cases.

    11. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      You do understand that we're on your desktops and smartphones? We're also in your IoT and blockchains. I know this because I've done all those personally and at scale.

    12. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      I'm in your moms and wives injecting them with the anaconda between my legs.

      - Tyrone 'Nigga Tyrone' DeShante

    13. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Yep, about five years ago when you begged me to take over.

    14. Re:The JavaScript on most sites.. by AHuxley · · Score: 2

      To hide content thats DRM. A huge image or movie thats displayed but only a low res version will save with the web page.

      --
      Domestic spying is now "Benign Information Gathering"
    15. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 1

      Especially to-do lists.

    16. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      or you could just develop clientside software that does the same thing with a fraction of the hardware and a fraction of the security and reliability problems. Of course, that would also come with a fraction of the control you would otherwise enjoy.

    17. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 1

      I wouldnt' say that. Today's sites (and 'apps') are far less useful and more difficult to use because of all the wasted whitespace, fidgety widgets, and other retarded gibberish. The classic fixed width (percentage of browser window size) frames with menu on the left and main content on the right is still the superior layout. For the love of fuck, who wants to read anything lengthy when it's size 18 font?

      captcha: posers - how fitting.

    18. Re:The JavaScript on most sites.. by TWX · · Score: 1

      Funny that you're typing this on an old website that has arguably gotten just a little worse by the inclusion of Javascript and the adoption of a client-side model.

      I watched the Web from its very inception become what it is, and it's ridiculous.

      --
      Do not look into laser with remaining eye.
    19. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      HTML5. Itâ(TM)s not perfect but the sooner .js and flash die, the better we all will be.

    20. Re: The JavaScript on most sites.. by guruevi · · Score: 2

      Most JavaScript is minified for bandwidth reasons. Most things a site uses are also open libraries with open extensions or plugins, think jQuery and *shudder* Angular.

      You can decompile everything on the web pretty easy. Developer mode in both Chrome and Safari will reindent most minified code to readable scripts and the rest isn't really that important, most things you want to do are better done not the way Google does it (you really don't want another MVC layer in your "View").

      --
      Custom electronics and digital signage for your business: www.evcircuits.com
    21. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Answer: Security through obscurity, aka the wet dream of every middle manager through executive. Devs only go along with it to hide the shame of putting the entire security model in the client.

    22. Re: The JavaScript on most sites.. by infolation · · Score: 1

      First, the official advice is "Concentrate on promoting more than demoting".

      Second, there never seems to be enough mod points to downvote all trolls. Better to vote in a way that promotes browsing at 'Score:3 or above' than whack-a-mole the swamp.

    23. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 2

      A competent developer can duplicate the functionality of most webpages

      This statement is highly misleading, because it doesn't apply to all the back-end part which is completely hidden. For example, a website consisting in plain HTML pages which are generated dynamically cannot be emulated. You might go page by page and store all the HTML (or any embedded code), but this task might be too difficult or even impossible; additionally, this would be a mere collection of the results outputted by the current version of the functionality, rather than a duplication of said functionality.

      My two sites are 100% dynamic (written in PHP). You can try to collect the HTML of quite a few of their pages, but certainly not of all of them. Bear in mind that one includes a ranking of web domains whose size right now is over 9M. I have enabled a URL-friendly access which allows visitors to list chunks of that ranking starting at any position and including up to 250 elements. Additionally, these records are being regularly updated (at the moment, once every 24 hours).

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    24. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      > but there is a serious amount of interest in preventing the reverse engineering

      Yes, I see that

      > (and, rightfully so)

      No, I don't agree. If someone wants to execute code on my machine, (s)he has to have my trust. No, most of the biggies haven't.

    25. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Well, they run their code on my machine. They'll have to accept that I reverse engineer the code and use their APIs.

    26. Re:The JavaScript on most sites.. by hagnat · · Score: 1

      you might not like javascript (i am not a fan either), but you can't deny its place in web development. It allow us to do a lot more client side than any alternative, and its finding some niches in server side as well. The only "problem" with javscript (and PHP for that matter) is that since its a easy to learn and use language, a lot of newbies with little knowledge of good practices use it in ways that more senior developers would cringe about. Everybody is a newbie at least once at everything they do in life, even you.

      --
      "life is a joke, and someone is laughing at me"
    27. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Fuck you Tyrone, you cud kiss mah black ass.

      -Jamal "Not to be confused with Jamal Black" Brown

    28. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Do you have examples of what you propose being implemented successfully? Most often you would probably get insecure and sluggish Java applications with a GUI unlike any other no matter what operating system you use. Or a slightly better dotNet application (at least better UI) but that works only on Windows.

    29. Re:The JavaScript on most sites.. by houghi · · Score: 1

      How does making code hard to read prevent reverse engineering. This is like saying that changing the port of ssh makes your system safer.
      To me it just sounds like security through obscurity.

      And the code you see is generated by a database anyway.
      Car example: it is reverse engineering an engine of a car by opening the doors.

      --
      Don't fight for your country, if your country does not fight for you.
    30. Re: The JavaScript on most sites.. by Zero__Kelvin · · Score: 1

      You don't know what "responsive" means, do You? Hint: You want a site to be responsive. If it isn't then it is designed wrong.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    31. Re:The JavaScript on most sites.. by St.Creed · · Score: 1

      I actually like JavaScript a lot. It's a nice functional language that has an IDE literally on every computer on the planet. We could do a lot worse... like Java, in the browser. Applets, anyone?

      --
      Therefore, by the (faulty) logic you're using, you're just a cow with a keyboard - osu-neko (2604)
    32. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      It worries me that you are doing something as important as medical imaging in Javascript.

    33. Re:The JavaScript on most sites.. by AmiMoJo · · Score: 1

      The raw source code of a web page is kinda like raw assembler code. Sure, you can understand and read it, but most people don't because there are better tools. The vast majority of web developers don't bother with most of that stuff.

      At the high level end you have CMS packages that you install and then do 99% of the work in a browser via the tools that the CMS provides. Then in the middle you have people who use frameworks and libraries to do all the hard stuff and then write some wrapper/logic code around them.

      There is nothing wrong with any of that - it's a good thing that software development gets easier and more accessible, and of course more maintainable. It just means that for most people there is little point using the "view source" feature because they will never need to interact with most of it, same as most people don't check the assembler output of their compiler. It's not really a loss, it's just the changing nature of web development.

      --
      const int one = 65536; (Silvermoon, Texture.cs)
      SJW, n: "Someone I don't like, and by the way I'm a fuckwit" - AC
    34. Re:The JavaScript on most sites.. by xSauronx · · Score: 1

      > If you kill off Javascript, you also kill off medical image imaging

      ugh, right? i work with an ECM product holding medical/hr/accounting records and the whole back end uses javascript. I sort of hate it.

      --
      By and large, language is a tool for concealing the truth. -- George Carlin
    35. Re:The JavaScript on most sites.. by SQLGuru · · Score: 1

      The biggest gain from obfuscation (in the form of minification) is improving speed. Sure, we all have broadband, but web sites have gone from a single file that was self contained to a file that pulls in so many other files (multiple CSS, multiple JavaScript files, tons of images, etc.). So minification is basically compression......sure, it's not saving gigs, but it DOES improve the load times. And a fast page is a visited page.

    36. Re: The JavaScript on most sites.. by Rei · · Score: 1

      This. It's very common to have separate "development" and "deployment" versions (the latter often with a title like ".min.js"), the latter having been run through a program that mangles it not to "hide" things, but to minimize bandwidth. Part of the mangling can be undone on the client side. Part of it can't.

      Honestly, I think it'd be best for everyone if we'd finally get around to standardizing Javascript compilation, with servers being able to request both compiled and uncompiled versions. Then everyone's happy. Developers can code in a nice, easy to read format, don't have to deal with maintaining two versions, and have the smallest-possible bandwidth use on deployment. Web users have their pages load fast, run fast, and can in development mode request the raw code. Having the raw code as a delivery option allows for backwards compatibility with older browsers. What's the drawback?

      There's a push in the direction of WebAssembly, but it's not the same. It has no "backwards compatibility mode and support is currently limited. It doesn't give users the source code. It doesn't allow for using today's massive JS codebase. Etc. Emscripten isn't much better.

      --
      Dear Diary...today I was pompous and my sister was crazy.
    37. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Most reaponsive sites are terrible. And they give you a shitty dumbed version on a mobile device even though they can more than handle a full desktop siten

    38. Re:The JavaScript on most sites.. by hord · · Score: 1

      Fraction? When everyone is reinventing GUIs, ToolKits, and Widgets again? The advantage of the browser is that it gives a unified "desktop" to every device (even if modern HTML/CSS is painful). The browser is the standard "client". It just needs to be rebooted to act like one rather than being an ad platform.

    39. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Just write, transpile, minify and bundle TypeScript. And do not forget to publish the .map files in your release step (security through obscurity only blocks the interested from learning).

      Problem solved, readable JavaScript.

    40. Re:The JavaScript on most sites.. by CastrTroy · · Score: 1

      I wonder if more web applications will ever go the route of just downloading an "App". You can provide a much better experience to end users by providing an App on their device of choice. You can visit Facebook on your mobile browser, but I'm pretty sure the vast majority of users who use Facebook on their phone choose to do so through the official App. Same goes for many popular websites such as Twitter, Reddit, and most banking applications. I've even started using an App (Readit) to browse Reddit on my Windows desktop.

      Web sites are fine for things where you only spend a couple minutes a day using them. They definitely have their advantages, and are great for sending link to people where you know they'll be able to see the content that you see. I don' think you'll ever see web sites completely disappear. But for many web applications, it would make much more sense to just develop a full app that communicates with an online server rather than try to shoehorn so much functionality into the browser.

      --

      Anthropic principle: We see the universe the way it is because if it were different we would not be here to see it.
    41. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      The tragedy is that while minification may yield a 20-50% reduction in size of the original JS source file, most websites throw those gains away by importing tens of megabytes of dependencies, anyway.

    42. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      You can optimize webpages by not using fancy shit frivilously.

    43. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      If you kill off Javascript, you also kill off medical image imaging (my line of work

      No, you would just kill off medical imaging in Javascript. You're already doing it wrong by using that language for something as sensitive and resource intensive as medical imaging, anyway.

    44. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 1

      The raw source code of a web page is kinda like raw assembler code

      No, it is not. As explained, my two sites are fully written in PHP and generate all the HTML code dynamically. You cannot access this PHP code because it runs on the corresponding server; you can only see some of the outputs generated by that code (e.g., HTML). On the other hand, you can have access to the client-side scripts like JavaScript, but my sites have just a tiny bit of that. Web-based programming is formed by two parts: client-side (visitors can see the code via "view code") and server-side (visitors cannot see the code or associated resources). What you call "raw source code" is a complex reality about which visitors can only know half of it.

      It is true that a big proportion of modern websites are heavily relying on the client-side part; but there are also quite a few other ones (like my two sites) which are almost completely back-end-based. In any case and regardless of what might be the most common approach, the statement "duplicate the functionality of most webpages easy enough" comes from the wrong assumption that visitors can have access to all the webpage functionalities (websites = client-side), an error which my original comment tried to correct.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    45. Re: The JavaScript on most sites.. by CanadianMacFan · · Score: 1

      And yet they send bloated multimedia files. Optimizing a commonly used graphic and you will save a lot more in bandwidth. I've seen some places where they could have the files sizes of their images cut in half without impacting quality.

    46. Re:The JavaScript on most sites.. by skids · · Score: 1

      Well, at least there's a plausible "reason," however bad, why all the declarative constructs that get proposed in standards end up unimplemented in browsers (full SVG SMIL and sortable tables to name a couple) and instead get worked up in script form. I mean, a reason other than anemic coding vigor, which is a depressing reason rather than one one can get fired up about.

    47. Re:The JavaScript on most sites.. by Hentes · · Score: 1

      Compressed http will help you a lot more in terms of size than "minification" ever can.

    48. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Have you stopped raping your neighbor's goats yet?

      Yes, because they give consent now.

    49. Re:The JavaScript on most sites.. by AmiMoJo · · Score: 1

      I meant they are similar conceptually, not in terms of accessibility.

      --
      const int one = 65536; (Silvermoon, Texture.cs)
      SJW, n: "Someone I don't like, and by the way I'm a fuckwit" - AC
    50. Re: The JavaScript on most sites.. by KiloByte · · Score: 1

      You don't know what "responsive" means, do You? Hint: You want a site to be responsive. If it isn't then it is designed wrong.

      Try browsing from an ARM laptop: you get useless "mobile" versions even though the machine has a form factor indistinguishable from x86 laptops. Or, on a desktop, have your primary monitor in portrait mode (much better for 90% of sane webpages!) -- you'll often see it degrade to a mystery hamburger menu with all other misfeatures.

      I see what the idea of "responsive" means, but what I complain about are prevailing implementations.

      --
      The creatures outside looked from Alt-Right to Antifa; but already it was impossible to say which was which.
    51. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      It isn't medical imaging. It is the fact that the developers have gone to cheap tools to do so, similar to someone buying a bunch of fidget spinners from Taobao for cheap, popping the bearings off, and using those for parts to make the mechanism needed to move control rods in and out of a nuclear facility.

      The problem is that the "it builds, ship it" mentality is so pervasive, it even goes into sectors where lives are at stake. We saw the same thing with Java where it is part of the EULA for it not to be used for medical or nuclear powered devices... but I've seen it used on IV drip machines, heart monitors, and other items, where it expressly should not be present.

      But, who cares. If someone makes another misconfigured Therac-25, it isn't like anyone is going to be held accountible. There are limits on medical liability cases, companies might get a slap on the wrist and a "don't do that again", and if the company went under, the top brass isn't affected.

    52. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      I will reverse-engineer your site to the last bit if I want to. Just so you know.

    53. Re: The JavaScript on most sites.. by Zero__Kelvin · · Score: 1

      Choose "Request desktop version" browser option. It works from a phone too.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    54. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      I wonder if more web applications will ever go the route of just downloading an "App". You can provide a much better experience to end users by providing an App on their device of choice.

      No, please don't. Keep the web open. Keep the web free. Fade down the walls!

    55. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      I got Amazon Dot. Where are my cock eggs?

    56. Re:The JavaScript on most sites.. by wvmarle · · Score: 1

      An autoformatter in the "view code" option would be a great help, indeed. All that javascript without line breaks could be made so much more readable if it'd be reformatted with sensible line breaks and indentation, ideally with keyword highlighting and so. Of course still no comments but at least it'd make the stuff somewhat readable.

    57. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0
    58. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      And this makes my blood boil. For all the push toward TDD and documentation we now have tests that don't test anything and documentation that tells you exactly where all the hacks were...last year. Software still lacks design and isn't refactored which results in sprawling tar balls of unreadable code.

      The concepts behind code live longer than the code but we can't see those from 10 feet off the ground, and certainly not from View Source.

      Software configuration and tooling has always been a bugbear. The fact that the average C++ app usually requires you to set up a Linux VM or Docker instance to make it compile with specific dependencies is kinda trashy. The fact that most people give up is why everyone would rather use JavaScript. It's our own damn fault if we don't make our code accessible.

    59. Re:The JavaScript on most sites.. by tepples · · Score: 1

      Minification then gzip saves more size than gzip alone, as minification allows more of the code to fit into gzip's 32 KiB back-reference window.

    60. Re:The JavaScript on most sites.. by tepples · · Score: 1

      You can provide a much better experience to end users by providing an App on their device of choice.

      My "device of choice" is a PC running Xubuntu, an X11/Linux distribution. How many app publishers would be willing to serve that environment as a first-class citizen as opposed to sticking to Windows, macOS, Android/Linux, and iOS?

    61. Re:The JavaScript on most sites.. by tepples · · Score: 1

      While I understand they want to protect copyright, the real problem is the inability to audit what is executed.
      [...]
      As far as I'm concerned, websites will always be second class citizens compared to real desktop software

      Among the most popular desktop applications, how many give the user the "ability to audit what is executed"?

      They're also ephemeral

      So is a desktop application that displays "Your client is out of date. [ Install Updates ]" when the server is using a newer protocol version than the client. So is a desktop application that breaks on a new operating system version because it inadvertently relies on implementation-defined, unspecified, or undefined behavior that has changed in the new OS.

    62. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 1

      I will reverse-engineer your site to the last bit if I want to. Just so you know.

      You can take any piece of software, use it and try to replicate its behaviour. Depending upon the complexity, your ability (+ the ability of the original authors), available resources, etc., that copy might be more or less similar to the original version; but you will most likely not create an identical result. Logically, you cannot emulate regularly-updated contents/datasources, what is pretty much the whole point of my two sites.

      In any case, you cannot get the (PHP) code of my sites from anywhere (unless someone stole it from me at some point; in that case, I would be grateful if you could let me know about it :)) or duplicate them by exclusively focusing on retrieving the generated HTML (as said, one of them has a specific part including a virtually infinite number of pages). In other words: they are excellent examples of non-decompilable code.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    63. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 1

      Non-decompilable software would have made waaaay much more sense. LOL.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    64. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      If you kill off Javascript, you also kill off medial image imaging (my line of work) or a thousand other things you depend on but don't realize.

      [Sigh]. If you're doing medical imaging in Javascript, you're probably doing it wrong.

    65. Re:The JavaScript on most sites.. by HornWumpus · · Score: 1

      Every programmer working learned the basics from contrived examples.

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    66. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Funny that you're typing this on an old website that has arguably gotten just a little worse by the inclusion of Javascript and the adoption of a client-side model.

      I watched the Web from its very inception become what it is, and it's ridiculous.

      Nah. The old static pagination never worked, now it does a lot better to load comments.

    67. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Not anything of value for creating actual, complex software. This is why the code.org tutorials are such a joke. They don't teach writing software in a way that matches anything in the real world.

    68. Re:The JavaScript on most sites.. by HornWumpus · · Score: 1

      You _don't_ code, it's obvious.

      --
      John McAfee 'It was like that time I hired that Bangkok prostitute; to do my taxes, while I fucked my accountant'
    69. Re: The JavaScript on most sites.. by Desler · · Score: 1

      Oh no! How will the site ever recover after such an earth-shattering proclamation.

    70. Re: The JavaScript on most sites.. by Desler · · Score: 1

      Tried it and most sites still just give you the shitty mobile site these days. Wells Fargo is a prime example where you can't reach the desktop site on a phone. The mobile site for no good reason has multiple features removed such as simply seeing your account and routing numbers and viewing your statements which only involves opening a PDF. Neither should require a desktop.

    71. Re:The JavaScript on most sites.. by Desler · · Score: 1

      If you ignore the fact that the old site had a years-old bug pagination bug that the Slashdork web monkeys could never seem to fix.

    72. Re:The JavaScript on most sites.. by Gr8Apes · · Score: 1

      Most sites people use work conceptually just fine without JS. Some force you to have JS for no real reason other than they want to track everything you do.

      --
      The cesspool just got a check and balance.
    73. Re: The JavaScript on most sites.. by ponraul · · Score: 1

      Mod Parent UP!

    74. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Have to take the bitter with the sweet, I suppose.

    75. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      The worst thing is javascript-less slashdot doesn't let me choose my settings from a combo box. I merely want to read everything at -1 and scroll by, not open comments in tabs as I did 15 years ago.

      Now where it's bad is the link or message that invites to "switch to the classic view system by toggling it in your preferences".
      This is dumb : situations where I browse javascript-less tend to be situations I don't want to log-in either, or don't want to bother doing it, or cannot even do it e.g. dillo is a somewhat awesome browser with no javascript whatsoever but tends to not have the smarts to be able to log in. I need to browse slashdot at -1 in it.

    76. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      but it's not so terrible either

      Yes, actually, it is.

    77. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      And yet they send bloated multimedia files. Optimizing a commonly used graphic and you will save a lot more in bandwidth. I've seen some places where they could have the files sizes of their images cut in half without impacting quality.

      +1 ... and to add this:

      If web sites REALLY WANTED TO SAVE ON BANDWIDTH they would stop using "autoplay" multimedia files, like ESPNFC.

      Yeah, I know the "I want it all NOW" generation would scream loudly like the "precious snowflakes" that they are, but seriously, does almost every page of a web site like ESPNFC have to contain "autoplay" video files?

      Just look at Youtube. It is quite popular worldwide without having to resort to "autoplay" video files. Does anyone disagree with my claim that Youtube is popular?

      I am only picking on ESPNFC in this case as a blatant example of a web site that excessively uses "autoplay" video files. There could be others out there.

      Now cue up the idiot that claims not having "autoplay" multimedia files would make their life miserable while riding The Tube or speeding on the M1.....

    78. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Don't look at web pages - good idea, too much garbage.

      But feel free to look at source.

      A prettyprinter will fix the formatting, and optionally replace variable names.

    79. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      The browser is meant solely to navigate HTML pages. The cruft that's been built around it over the past 20+ years is what's killing it. Not to mention tho 'governing body' just approved DRM in the platform.

      It will die, slowly.

    80. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Give me a, "This site works best in IE5 at 800x600 resolution"!

    81. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      Yep, look into WebAssembly, aka asm.js.

      Like everything else Javascript, it's half-assed shoehorning. What can you expect from a language literally built in 10 days?

    82. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      or you could just develop clientside software that does the same thing with a fraction of the hardware and a fraction of the security and reliability problems.

      Nah, maintaining code and deployment for multiple platforms is just a hassle, better to write it in Javascript. It doesn't have security or reliabilty problems any more than multiplatform native code. Sure you can wax on about it but without concrete examples and proof it's just your rambling, baseless assertions.

      Of course, that would also come with a fraction of the control you would otherwise enjoy.

      Yes, being able to roll out improvements to everybody immediately is hugely advantageous to both me and my customers, it would be stupid to take that away.

    83. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      >It's not perfect, but it's not so terrible either.

      Oh yes, yes it is.

      I have learned more and more about javascript, until I finally learned enough to know that, while it would be possible to know enough to be sure that you are doing things correctly, I have no interest in achieving that level of expertise.

      And for those of you snarking out there - I'm confident that 99% of you don't have that level of expertise. The more you learn, the more you know how difficult it is to do anything remotely sane in javascript.

      And if you're still thinking about snarking, unless you can quote me chapter and verse from this article without consulting a reference, then go fish:

      http://javascriptissexy.com/understand-javascripts-this-with-clarity-and-master-it/

      Remember - you must know all of the above by heart, otherwise you are just making a mess of your javascript apps. Not only that, you must remember to do it correctly _each and every time_ you type.

    84. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      No, it actually is pretty fucking terrible.

    85. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      How sure are you this helps in any substantial manner? Information theory would indicate that by removing some of the redundant information before compression, you are making the stream less compressible.

    86. Re:The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      if you want to speed up a website then:
      1) make sure to host everything on the same server to minimise dns lookups
      2) consolidate the js and css in 1 file each
      both of those have 3 or 4 orders of magnitudes more effect on speed then minification

      what minification helps with is bandwith costs for huge sites with millions of views per day

    87. Re: The JavaScript on most sites.. by SQLGuru · · Score: 1

      Minification is less about removing redundant information so much as reducing the size of the tokens. If you replace a variable named 'keepTrackOfSomeValue' with a variable named 'a', you save a fair bit of space in the original file.

    88. Re: The JavaScript on most sites.. by Anonymous Coward · · Score: 0

      I am building angular components using jupyter notebooks.

    89. Re: The JavaScript on most sites.. by guruevi · · Score: 1

      You can, it's why you upload the .map with the .min.js, when you open editor mode, most browsers automatically requests eg. jQuery.map together with jQuery.min.js which "deminifies" the JavaScript back into the original code.

      --
      Custom electronics and digital signage for your business: www.evcircuits.com
    90. Re: The JavaScript on most sites.. by guruevi · · Score: 1

      It's not reduce bandwidth for the sake of reducing bandwidth cost, you reduce bandwidth so your site loads faster, THEN you load the autoplays. Off course most ad-aggregation systems will destroy this again unless you correctly implement it. You can easily filter the idiot web developers on how they load ads.

      --
      Custom electronics and digital signage for your business: www.evcircuits.com
    91. Re: The JavaScript on most sites.. by ale2011 · · Score: 1

      You can decompile everything on the web pretty easy.

      Not when all variable and function names are replaced by random strings. I'm unclear whether they do it to prevent code reuse or to hide their web site logic.

      Rather than reboot ViewSource, I deploy NoScript

    92. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 1

      Just in case it wasn't completely clear, I have written the PHP code of both my sites completely from scratch; what means that there isn't even a single public/written by others bit. Also note that what I meant with one of my sites including a part with an almost infinite number of pages was this, where you can modify the last part [starting index]_[length up to 250] as much as you wish within the maximum number of records (currently, 9134287).

      I have been getting some naive (and/or plainly ridiculous) visits from bots during the last days. Not sure if this was provoked but this post or not (my sites get a relevant number of dumb-bot visits; honestly, no idea why), but I am including this additional information just in case. If you want to know anything else, just ask.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    93. Re:The JavaScript on most sites.. by CustomSolvers2 · · Score: 1

      Actually, the referred link is just a small part of the whole story as far as this same functionality works also for other formats (i.e., raw, XML and JSON). By bearing in mind that all these records are being regularly updated (currently, every 24h) and its number increased (currently, at a rate of about 50k-60k/day), I guess that my "a virtually infinite number of pages" isn't an exaggeration.

      --
      Custom Solvers 2.0 = Alvaro Carballo Garcia = varocarbas.
    94. Re: The JavaScript on most sites.. by guruevi · · Score: 1

      Most minification also produces a map file and unless they truly want to hide the code, they are usually uploaded alongside the rest of the code by most developers.

      --
      Custom electronics and digital signage for your business: www.evcircuits.com
  2. Open source not view source by James+Carnley · · Score: 5, Insightful

    View source is a relic of how the internet used to be. It's not coming back and I would argue should be hidden by default in browsers. It's akin to decompiling the source of an .exe file to look at the code (which some people do) and learn how it does things. Not a good method.

    What you really want for learning and teaching techniques is to view the real source code. The source code with comments, with context, and with reproducibility in full. This is what open source projects and those demo websites do. They intentionally format the code in a readable way for the purposes of learning.

    Someone learning to code on the web should not be looking at production code in a scalable web app, they should be following tutorials and using demo projects like you do in every single other language. The web isn't special it just had the quirk of the View Source button that was neat at the time but is now out of date and a relic of a bygone era.

    1. Re:Open source not view source by courteaudotbiz · · Score: 1

      I would add that the "view source" is not a way to learn to code the "under the hood" functionalities. It is a way to see how the site integration is done. Back in my days, I learn how to build proper TABLES, TR, TD. Now I have learned to work with DIVs to organize my containers.

      I find the "Developer tools" to be now way more useful than "view source". First it does not require a new page load, so you can see the markup after a POST for example. And you can just point at the element of interest, and it shows you where it is in the page's "source code" (Markup code)

      Building dynamic, DB driven websites is not a thing of "view source", it is a game of tutorials. Make your first "Hello World!", then continue on. That's how I learned PHP. At first I learned procedural coding, and no I just began working with objects. But this has nothing to do with "View source".

    2. Re:Open source not view source by Anonymous Coward · · Score: 4, Interesting

      View source is a relic of how the internet used to be. It's not coming back and I would argue should be hidden by default in browsers. It's akin to decompiling the source of an .exe file to look at the code (which some people do) and learn how it does things. Not a good method.

      It's a great method if one wants to look at the output of a compiler. It's also useful to look at the internals of a web page as far as just how much it's generated on the fly in javascript vs baked in by a server-side script/app.

      What you really want for learning and teaching techniques is to view the real source code. The source code with comments, with context, and with reproducibility in full. This is what open source projects and those demo websites do. They intentionally format the code in a readable way for the purposes of learning.

      Which goes to show you how the big complaint I had about the way the web was going came true. Sure, we bypassed having Flash hell. But we've replaced it with HTML5 and javascript hell. The fact that you don't think it's actually possible for a web site to have comments with context and such and that one can only get that in demo websites is precisely the problem. If I want to make a web site like Amazon, what better framework is there than to literally see how they do it?

      Someone learning to code on the web should not be looking at production code in a scalable web app,

      Actually they should, in part, to understand exactly what their framework is outputting to get an idea of just how scaleable said web app really is in production. More generally, developers of web pages need to look at the code to have an idea of why stuff isn't working right.

      they should be following tutorials and using demo projects like you do in every single other language.

      Another major part of learning another language is seeing actual production code, not just demo projects. And debugging programs, possibly even without the source code. It's actually a necessary step to get into the mindset of "what could possible be causing this problem".

      The web isn't special it just had the quirk of the View Source button that was neat at the time but is now out of date and a relic of a bygone era.

      No, it was special. For a long time, a web page really was something that could be intelligible in "view source" because html was merely a markup language. Page generators could simplify the boilerplate production, but even then the output was still readily human readable. Honestly, the move to CSS didn't kill this. Javascript itself didn't kill this either. What mostly killed this was that Google (and others) intentionally obfuscated their code precisely to make it so people COULDN'T learn from it. Any claims about code size? That's what gzip (and other) in-line compression is for.

      Oh, and, btw, you should really look up the history of LISP machines to get some perspective on just how consumer interests turn an open platform into a shithole.

    3. Re:Open source not view source by amalcolm · · Score: 0

      I bet you're fun at parties.

      --
      Time for bed, said Zebedee - boing
    4. Re: Open source not view source by Zero__Kelvin · · Score: 1

      No ... ONE (antiquated) pronoun is "he" ... a person can use the more accurate (i.e. gender neutral) "they" if they want. The former is only correct when you refer to a specific male, or a subject that is guaranteed to be male.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    5. Re:Open source not view source by coofercat · · Score: 1

      I read the jist of what he's saying not so much as "we should be able to view source" but "we need a way for newbies to get online". To some extent I agree with him - the webdev I've ever done has been so unintuitive and tedious I can't imagine why anyone would ever want to be a webdev.

      To elaborate, I find HTML pretty straight forward. It's pretty clear what you're supposed to be doing. However, once you start needing CSS, then things get considerably less intuitive. CSS means that the ordering in HTML is somewhat irrelevant, although in some cases, even though the CSS is re-ordering things on the screen, the HTML ordering is still important. That's confusing. Then browser differences make the whole thing really, really annoying because you get it all working in your favourite browser and try it in another and it looks hideous, or worse, it looks fine, but a banner or heading is sized differently and so it looks weird. Worse still is you try it in the same browser on a different OS and it looks different in another way. Getting anything to look right in all cases is (it seems to me) a hard problem.

      Once you've got all that straight, then try adding in some Javascript. It's not a great language to get started in, and it too has so many weird foibles that "real" programming languages don't. Testing it works is hard too because of browser differences, screen differences etc. You can't really even have unit tests on non-UI-affecting stuff. If you want to do anything more formal, with proper testing regimes and so on, then you're into a really complex development process with some pretty exotic tools.

      So... after all that... yeah, a simpler 'web' would be no bad thing. Getting there would be near impossible though - making a replacement for CSS and Javascript sounds like a noble endeavour, but the world has too much investment in them to want to switch any time soon.

    6. Re: Open source not view source by Anonymous Coward · · Score: 0

      No, moron. "They" is not accurate because it is plural. It is politically correct bullshit.

    7. Re: Open source not view source by DarkOx · · Score: 1

      bullshit its been grammatical norm to use 'he' when the gender is unknown for centuries. There is no question of accuracy its a question of knowing the definition. 'They' is usually plural and is therefore just as ambiguous although in a different when you start using it to possibly refer to individuals.

      English does not have a lot of hard and fast rules. There is no official governing body. Use 'they' if you want but don't force you special snowflake bullshit on the rest of us and don't lie about it being somehow more correct. The fact is its no more and no less correct, because there is no correct. There is only did you recipient understand your message correctly and with minimal processing effort.

      --
      Repeal the 17th Amendment TODAY! Also Please Read http://www.gnu.org/philosophy/right-to-read.html
    8. Re: Open source not view source by metrix007 · · Score: 1

      The 'he' pronoun isn't antiquated, idiot. God damn codemonkey thinks he knows everything.

      --
      If you ignore ACs because they are anonymous - you're an idiot.
    9. Re:Open source not view source by Anonymous Coward · · Score: 0

      What mostly killed this was that Google (and others) intentionally obfuscated their code precisely to make it so people COULDN'T learn from it.

      You can verify that Google asks the user not to cut and paste their minified js.

    10. Re: Open source not view source by Anonymous Coward · · Score: 0

      bullshit its been grammatical norm to use 'he' when the gender is unknown for centuries.

      "Whoso pulleth out this sword from this stone and anvil..."

    11. Re:Open source not view source by Anonymous Coward · · Score: 0

      There have been times when I had to jump into the source code and figure out why a web site does not display properly and modify something to see the content.

      No view source, broken web pages with important info are gone forever.

    12. Re:Open source not view source by tepples · · Score: 1

      Any claims about code size? That's what gzip (and other) in-line compression is for.

      Not when gzip(minify(source_code)) is measured as significantly smaller than gzip(source_code).

    13. Re: Open source not view source by Zero__Kelvin · · Score: 1

      When used in a non-gender specific fashion it is absolutely antiquated. Good luck learning English!

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    14. Re: Open source not view source by Zero__Kelvin · · Score: 1

      Yep, it wasn't antiquated until it became antiquated. I agree. Awesome point!

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    15. Re:Open source not view source by Anonymous Coward · · Score: 0

      You do realize that this is an argument for a better, more-specific compressor for html/css/javascript, right? In fact, this is why we had SPDY and have HTTP/2. Having said that, I can imagine that minified code will always be smaller than the comparable unobfuscated code, but the point remains that (1) you're better off pushing for more use of gzip across the board (which is actually more the issue) and (2) accepting that it's a good trade-off to still have human-readable web pages even if it does add a 1% (or whatever) overhead.

    16. Re:Open source not view source by tepples · · Score: 1

      You do realize that this is an argument for a better, more-specific compressor for html/css/javascript, right?

      MoreSpecificCompressor(minify(source_code)) will still be significantly smaller than MoreSpecificCompressor(source_code).

      (2) accepting that it's a good trade-off to still have human-readable web pages even if it does add a 1% (or whatever) overhead.

      In order to convince bean counters of this, we'd first need to see the exact size ratio between gzip o minify and gzip alone (what you call the "whatever") in order to calculate the extent to which this ratio affects page load time and bandwidth cost.

    17. Re:Open source not view source by laddiebuck · · Score: 1

      I agree with you that we're in Javascript hell. But I agree with OP that View Source is no longer the fix. Like you said, today's Javascript is the output of the compiler, and most of it is retrieved on the fly anyway. "View Selection Source" is still useful, but "View Source" is losing relevance each year. Javascript today is minified, packaged, transpiled, and sometimes even converted into bytecode. Not to mention web devs work in chaos in the first place: it's hard enough to debug a modern web framework if you're looking at the source code and documentation, let alone using View Source.

    18. Re:Open source not view source by Anonymous Coward · · Score: 0

      In order to convince bean counters of this...

      And that's the argument that has result in the current shithole situation. Which I think was my original point. :) Well, that and the "my html is so special, it needs to be made so the user can never read it; get on that, engineers!"

  3. What the world needs now is love, sweet love by Anonymous Coward · · Score: 0

    It's the only thing that there's just too little of

  4. Why do we need to? by thecombatwombat · · Score: 1

    They don't seem to have established that we've actually lost anything. This basically just sounds like old people going "things are different and therefore bad."

    I can't help but think they're just schilling the sites they link to. Glitch "hosts hundreds of simple web apps—everything from Tetris clones to databases and to-do lists—written using Javascript. " Wow, hundreds? Github and npm will be so jealous.

    1. Re:Why do we need to? by AHuxley · · Score: 1

      To find the data. That big image or media file that is displayed but might not always save.

      --
      Domestic spying is now "Benign Information Gathering"
  5. You can't have that and javascript by cfalcon · · Score: 1

    You can't make it work with javascript. You can write a simple language, like HTML, that is meant to handle most cases of the net. You can then add to that language whenever a new thing becomes needed.

    But instead, if you insist on having a general purpose language that you write your fucking webpages in, of COURSE it will end up being as complex as code. Because it IS code.

    As long as javascript is tolerated, this will become more and more of a problem. Webpages aren't just "apps": they are, on average, each a program larger than DOOM I, on average.

    And this problem isn't just limited to javascript- any time you want to treat the web like it hosts programs for you to run instead of data for you to view, you will hit this barrier.

    1. Re:You can't have that and javascript by Anonymous Coward · · Score: 1

      You can write a simple language, like HTML

      HTML is a document format, not a language.

      HTML is best suited for the kind of documents you would typically create in Microsoft Word.
      Unfortunately people started using it for graphic layout since no other suitable format was widely supported.

    2. Re: You can't have that and javascript by Anonymous Coward · · Score: 0

      The L in HTML does stand for "Language" ...

    3. Re: You can't have that and javascript by Anonymous Coward · · Score: 0

      The L in HTML does stand for "Language" ...

      Pretentiously so, IMHO.

    4. Re: You can't have that and javascript by Zero__Kelvin · · Score: 1

      It is a misnomer. HTML version is specified by a DTD. DTD stands for DOCUMENT Type Description.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    5. Re: You can't have that and javascript by Anonymous Coward · · Score: 0

      XML can also be defined by a DTD but it's still a markup LANGUAGE.

    6. Re: You can't have that and javascript by hord · · Score: 1

      HTML has a grammar and can be parsed using standard techniques applied to other "languages". It is tokenized and structured. By any definition it is a language. A DTD specifies a type of HTML document which is more akin to an encoding. The document is encoded in HTML conforming to a specification designated by the DTD document which is itself an XML-encoded document.

    7. Re:You can't have that and javascript by Anonymous Coward · · Score: 0

      > HTML is a document format, not a language.

      They're not mutually exclusive, but one could argue the DTD/DOM is the document format.

      HTML is definitely not a programming language, but those aren't the only type of computer language.

  6. Old news by chromaexcursion · · Score: 1

    In 2002 I was working on improving the performance of our demo web site.
    I started doing what came to be called AJAX. One of my co-workers did a view source of the website I developed, and got 3 lines with the launch of the .js file.
    He stared in astonishment as the site ran on generated html from the javascript. The page loads were blindingly fast, because there wasn't actually a server request. All the work was being done in the browser with javascript.
    The world has come a long way since then.

    You can't learn javascript with view source.

    1. Re:Old news by Anonymous Coward · · Score: 0

      Yep, I was pretty astonished when I first saw a co-worker write a few lines of code and the entire page started changing before my eyes.

      It is far too late now to undo the damage of Web 2.0.

      The road to hell is paved with callbacks.

    2. Re:Old news by Anonymous Coward · · Score: 0

      The world has come a long way since then.

      It really hasn't.

      You can't learn javascript with view source.

      YOU might not be able to, but someone might.

  7. It's Not Just The Source by Anonymous Coward · · Score: 0

    So many of the new "cool" websites are unreadable. Their primary goal is to provide a colorful framework for advertising. Content is secondary. You're lucky to find 5 lines of meaningful text spread across 3 pages of advertising, "related links" and flashing nonsense.

    The added complexity increases the attack surface for malware and does nothing for the user. Whenever you see new whiz-bang presentation formats, you know you're in for disappointment.

    Why would anyone expect the source to comprehensible?

  8. Dudes an idiot by Anonymous Coward · · Score: 0

    ofc view source gets you garbage, use fiddler or a trace with tls decryption to see what's going on

  9. It still works exactly as before by somenickname · · Score: 5, Insightful

    The "View Source" functionality still works exactly as before. Except better. In Firefox, when I mistakenly hit Ctrl-Shift-C (which I do often), it brings me into an interactive "View Source" like functionality that is essentially a debugger. It's not [completely] the fault of webpage makers that the stuff under the hood is effectively gobbly-gook: That's just how the web looks now.

    I'm not really sure what this summary is implying. That we should roll back the web to hand written HTML with blink tags so that kids can understand it? Fuck that. Get your kid a Raspberry Pi and as many $5 peripherals as they want. That's WAY more interesting than web programming and leads to understanding how things work instead of copy/pasting shitty HTML.

    1. Re:It still works exactly as before by Anonymous Coward · · Score: 0

      I'm not really sure what this summary is implying.

      That the code behind web pages has turned to gobbledygook, too complicated to learn from. In the same vein, we need to roll software in general back to the point where it could be shared in printed magazines so that we could learn from typing in pages and pages of BASIC or assembler.

      (I don't disagree that there's been a huge amount of sludge buildup in web pages and that learning from View Code was once useful, but if we were to enforce a de-sludging we would lose a lot of the functionality that we take for granted today.)

    2. Re:It still works exactly as before by Trogre · · Score: 1

      The most excellent Style Editor tab lets you play with the style and have it change whatever page you're looking at in realtime. A great way to learn CSS.

      --
      "Nine times out of ten, starting a fire is not the best way to solve the problem." - my wife
    3. Re:It still works exactly as before by Anonymous Coward · · Score: 1

      I'm not really sure what this summary is implying. That we should roll back the web to hand written HTML with blink tags so that kids can understand it?

      This "hand written HTML" has the bonus that your web site is suddenly one tenth of its size and works well with a computer from fifteen years ago. (I still use one!)

      Oh, and it loads and renders in tenth of the time too.

    4. Re:It still works exactly as before by Anonymous Coward · · Score: 0

      It's not [completely] the fault of webpage makers that the stuff under the hood is effectively gobbly-gook: That's just how the web looks now.

      "That's just how the web looks now" is hand waving that obscures the source of the real problem: people putting together systems without understanding how the underlying components are built or function. Abstractions allows anyone to build applications today, and more and more critical systems are falling into this development model.

      Abstractions are both a blessing and a curse. If used well with discipline, and maintained to meet specific design goals - it can be a force multiplier that allows you to build something once and use it again everywhere. Without the abstractions of higher level languages, and components, we would still be programming assembly language to do everything today. The drawback comes when people only know the abstractions, there is no control of how and when to use them, and they proliferate without any checks and balances to their development and use.

    5. Re:It still works exactly as before by Anonymous Coward · · Score: 0

      That's just how the web looks now.

      You are part of the problem.

  10. disreputable by Anonymous Coward · · Score: 0

    Any writer who users "coders" to describe programmers immediately falls into disrepute.

  11. View Source for circa-1999 Google.com by theodp · · Score: 5, Informative

    Google.com Apr 22, 1999
    <center>
    <img src="/web/19990422191353im_/http://www.google.com/google.jpg" alt="Google! (Beta version)">

    <table border="0">
    <tr>
    <td>
    <form name="f" method="GET" action="/web/19990422191353/http://www.google.com/search">
    <center>Search the web using Google<br></center>
    <center><input type="text" name="q" value="" size="40" framewidth="4"><br></center>
    <center><input type="submit" value="Google Search">
    <input type="submit" name="sa" value="I'm feeling lucky"><br></center>
    </form>
    </td>
    </tr>
    </table>

    <a href="more.html">More Google!</a><br>

    <p><font size="-1">Copyright ©1999 Google Inc.</font>
    </center>

    1. Re:View Source for circa-1999 Google.com by Anonymous Coward · · Score: 0

      alt="Google! (Beta version)"

      Nothing changes

    2. Re:View Source for circa-1999 Google.com by gustygolf · · Score: 5, Funny

      Three <center> tags when a single one would do.

      Google was as bloated as ever back then too, I see.

      --
      "Slow Down Cowboy! It's been 58 minutes since you last successfully posted a comment" -- slashdot, driving users away.
    3. Re:View Source for circa-1999 Google.com by thegarbz · · Score: 3, Funny

      It was in Beta

    4. Re:View Source for circa-1999 Google.com by thegarbz · · Score: 1

      looks good but i cant find the button to log in to my account.

    5. Re:View Source for circa-1999 Google.com by roccomaglio · · Score: 1

      Probably for IE compatibility. There was so much redundant code to maintain IE compatibility during those years.

    6. Re:View Source for circa-1999 Google.com by Anonymous Coward · · Score: 0

      Why would you need an account for a search engine?

    7. Re:View Source for circa-1999 Google.com by thegarbz · · Score: 1

      Huh? Since when is Google a search engine? It looks like a portal to a world of apps to me.

      But on the search topic one of the great things about logging into search is results are intelligently shared across devices. It makes it very easy to search for an address in Google maps on the desktop and then step into the car and see it as a quick suggestion for navigation on a different device.

    8. Re:View Source for circa-1999 Google.com by Anonymous Coward · · Score: 0

      Ahhh the good 'ol days. When the internet was a wealth of information, an encyclopedia if you will. Instead of the over-social, ad-tracking, auto-playing video infestation it has become.

    9. Re:View Source for circa-1999 Google.com by Anonymous Coward · · Score: 0

      > Huh? Since when is Google a search engine? It looks like a portal to a world of apps to me.

      You misspelled "marketing information gathering and user data tracking service."

    10. Re:View Source for circa-1999 Google.com by Anonymous Coward · · Score: 0

      You're wasting your time arguing with a Google fanboi and pro-corporate shill.

    11. Re:View Source for circa-1999 Google.com by Lost+Race · · Score: 2

      Google.com Apr 22, 1999

      That is a thing of beauty.

      Compare to 2017: view-source:https://www.google.com/

    12. Re:View Source for circa-1999 Google.com by Lost+Race · · Score: 1

      Whoa, Slashdot bungled that URL for me. Copy/paste the anchor text, ignore the href.

  12. User/customer comes first by Anonymous Coward · · Score: 0

    And needs to be dazzled by a slick website that performs on a huge array of screen dimensions and platforms. Making it easy for someone to study/learn what's been done is not even a consideration. In fact just the opposite could be argued: what if it is your competitors doing that view-source, better obfuscate it.

  13. Oh, the article is an ad... by Kellamity · · Score: 1

    Da fuk is this article about? View source and more importantly Inspect lets me rip most websites fully apart, see how stuff works, steal their code, and often send posts bypassing their client side scripts because it IS so tinkerable. Anglular sites in particular with the controllers exposed, you can see everything. When I see something cool on a sight I look at the source and see how they did it, it's never hard. Pretty print helps.

    If you view source on a site I wrote and the javascript looks like gibberish to you, tough tits, you can learn how to code on pluralsight or stack exchange. If you like my jQuery go to Github and download my repo.

  14. ... is copy-pasted using View Source by jtara · · Score: 0

    No, the Javascript on most sites is just copy-pasted using View Source.

    View Source is part of what is WRONG with the web.

    It was never intended for wanna-be developers to copy-paste (STEAL) code from other sites. It was an early debug tool, long since superseded by decent inspection debut tools present in every desktop browser.

    If you are going to copy-paste code from other sites, AT LEAST use the inspection tools!

    But if you find anything you can easily read, you know you picked a lousy site to crib from, because a GOOD site will minify the JS, often into a single file. It will be incomprehensible. Not to hide it from you, but because it is efficient. If you can read the JS, you stumbled across a site that doesn't give a damn about efficiency.

    There are plenty of good, open-source, published Javascript libraries and plugins, as somebody pointed out in a thread below. Troll GitHub, not website sources!

    1. Re:... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      You know the debug tools can also de-minify right?

    2. Re:... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Can they de-minify white boy cocks?

    3. Re:... is copy-pasted using View Source by Dog-Cow · · Score: 2

      What web server doesn't gzip the HTTP stream these days? Concatenating into a single file makes sense to avoid multiple connections or requests, but minifying doesn't.

    4. Re:... is copy-pasted using View Source by Trogre · · Score: 1

      Really, they can add comments back?

      --
      "Nine times out of ten, starting a fire is not the best way to solve the problem." - my wife
    5. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Let me guess, you're asking for a friend...

      AC = Atom-sized C***

    6. Re:... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Try it and report back

    7. Re:... is copy-pasted using View Source by sjames · · Score: 1

      But if you find anything you can easily read, you know you picked a lousy site to crib from, because a GOOD site will minify the JS, often into a single file.

      OR you found that rare gem of a site that uses just enough JavaScript to get the job done rather than piling layer upon layer like a cargo cult just to call one function.

    8. Re: ... is copy-pasted using View Source by Zero__Kelvin · · Score: 1

      Concatenating into a single file would be the worst design decision you could make. It would cause All libraries to be reloaded for every page of the site. You should learn about web development rather than pretending you know about it on Slashdot. Start with finding out about HTTP2 and how it works, for example.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    9. Re:... is copy-pasted using View Source by SQLGuru · · Score: 1

      No, keep them as different files, but use a CDN. That way, your browser doesn't have to reload jQuery each time it goes to a new page or a new site. Even for private libraries, each file can be cached but one really large file that is specific to a page doesn't help when you go between pages of your site.

    10. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Yeah, I was asking for you, friend.

    11. Re: ... is copy-pasted using View Source by trg83 · · Score: 1

      Only if you don't make use of the well-supported caching mechanisms inherent in HTTP. Or fail to create a single page application (e.g. if all pages of your site are loading the same libraries, is it really a site or just a web application?). You throw a lot of stones for someone who doesn't seem to understand modern web development techniques.

    12. Re: ... is copy-pasted using View Source by Zero__Kelvin · · Score: 1

      Caching doesn't do shit when each page is a concatenation of unique content plus common conent. That's the whole point. Did you even think before you posted?

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    13. Re: ... is copy-pasted using View Source by trg83 · · Score: 1

      I didn't give much thought to my post, because my years of experience making applications to serve millions of weekly users through a global CDN means this is all second-nature to me. In many cases, one minified file can serve all the JavaScript dependencies of your entire site while doing client-side templating and dynamic content retrieval from external HTTP/REST services. A page is a dead concept on the web.

    14. Re: ... is copy-pasted using View Source by Zero__Kelvin · · Score: 1

      You should have given it some thought. You would realize how stupid you sound right now. I said the idea was stupid. You agreed with me. Eventually, you'll figure that out.

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    15. Re: ... is copy-pasted using View Source by Desler · · Score: 1

      But unless every site uses that same concatenated minified file you get no caching benefit. That's the part you seem to be missing.

    16. Re: ... is copy-pasted using View Source by trg83 · · Score: 1

      Your reading comprehension is so poor you think I agreed with you when I did not.

    17. Re: ... is copy-pasted using View Source by trg83 · · Score: 1

      That's one of the tradeoffs that goes into deciding whether you want to use a public or private CDN as well. Do you accept the downtime of hosts not under your influence or control or do you not? Do you accept that their content which you reference will always be what you referenced at the time you created the dependency (think defacing or just loss of data due to incompetence)? Do you want to be pushed around if the maintainer of the content starts pulling it due to a legal battle or a petty disagreement?

      The post I was replying to originally said:

      It would cause All libraries to be reloaded for every page of the site

      Which is an absolutely ridiculous statement. Whether I want my caching strategy to improve the load time of unrelated sites on the Internet is strictly my business. Being too dumb to set up caching on your own web site is an entirely different matter.

    18. Re: ... is copy-pasted using View Source by Zero__Kelvin · · Score: 1

      You heard it here first folks! trg83 thinks making caching impossible by concatenating page content and support libraries together so the libraries get reloaded every time is a great idea!

      --
      Guns don't kill people; Physics kills people! - John Lithgow as Dick Solomon on Third Rock From The Sun
    19. Re: ... is copy-pasted using View Source by Darinbob · · Score: 1

      A single file makes it harder to use noscript also, as your choices are then to allow it all or allow nothing.

    20. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Only among 'professionals' who have ruined the Web for everyone else with their endless building on a protocol that was never meant to be abused this way.

      Pages are the core of HTTP. Ignore that at your own peril.

    21. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      All the baseless dick-measuring credentials in the world don't make your obviously wrong statement any less wrong. Zipping each page content and libraries up as described above is poor choice because then you cannot cache shared resources, each page is a single invidual blob.

    22. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      You must be trolling. Nobody is as stupid as you're pretending.

    23. Re: ... is copy-pasted using View Source by Anonymous Coward · · Score: 0

      Hi trg83!!!!

  15. We need to go back to simplicity. by green1 · · Score: 5, Insightful

    If you want "view source" to be useful, you need to go back to coding with simplicity in mind.

    The original post talks about viewing the source of the google homepage and getting an incomprehensible slurry. But why? What does that actually accomplish? The page is one text entry box, and 2 buttons, plus a graphic above it. There is ZERO excuse for it being over 47,000 characters (not counting all the other stuff it pulls in). But this isn't at all rare on today's web. This is also why so many pages are so horrendously slow to load, it's all scripts and links to other files and domains, even the simplest websites use absolutely incredible amounts of bandwidth, and yet do no more than could be done in 1/100th the size or less, and be human readable.

    99.99999% of these sites aren't huge for any good reason, they're just horribly inefficient.

    1. Re:We need to go back to simplicity. by amoeba1911 · · Score: 1

      Agreed. The reason they're horribly inefficient is because programmers don't understand how to use javascript, so they end up using massive frameworks and libraries to do even the most basic things. http://vanilla-js.com/

    2. Re:We need to go back to simplicity. by AHuxley · · Score: 1

      Todays web has to push the ads.
      Ensure the ad is displayed.
      Ensure the click gets paid for and that no user is even thinking of attempting to "surfing" for free by blocking some scripts or the ad.

      If the browser is not showing the ad, the user is informed that they have to whitelist the site.
      Try and turn off or block scripts in the browser and the content will not show.
      Older browsers are told how to find a new browser that will support ads been displayed.
      The hard part is to get the site to demand whitelisting but then also not show content if scripts are not working.
      That constant testing of all browsers gets complex.

      --
      Domestic spying is now "Benign Information Gathering"
    3. Re:We need to go back to simplicity. by somenickname · · Score: 2, Insightful

      99.99999% of these sites aren't huge for any good reason, they're just horribly inefficient.

      99.99999% of all software "isn't huge for any good reason". Except for the fact that the developers decided to not use assembly so they could actually, I dunno, complete a project in a sane amount of time.

      Have a look at MenuetOS. It's written completely in assembly, fits on a single floppy and provides a lot of the useful functionality that a modern desktop does. It's insanely fast and easy to understand (if you don't mind jamming 100 lines of assembly into your head to grok an if statement). Yet, no one (probably not even the developers) uses it as their primary desktop. It's an awesome project but, it's certainly never going to overtake any other OS in users.

      You can stand on the shoulders of giants (or, in the case of the web, Trolls) or you can re-invent the wheel over and over. Thankfully, the modern software industry has mostly chosen correctly on this point. We are able to build nice things because the people before us have built nice foundations for us to build upon.

      I'll let you get back to writing your custom XML parser...

    4. Re:We need to go back to simplicity. by green1 · · Score: 1

      The vast majority of the time, there was no reason to use javascript, or ANY script.

      Most pages are still static content. Static content doesn't require scripts.

    5. Re:We need to go back to simplicity. by Desler · · Score: 1

      if you don't mind jamming 100 lines of assembly into your head to grok an if statement

      That must be some shitty assembly to need 100 lines to do something that can be done in 2 or 3 statements.

    6. Re:We need to go back to simplicity. by green1 · · Score: 5, Informative

      We're not talking assembly here, we're talking HTML. HTML is far easier to understand than the garbage most "developers" use these days, while keeping the page TINY by comparison. Assembler on the other hand is much harder to understand and program in.

      If you're writing a few lines of static content, there's no excuse to take as much as a few megabytes of code to do it.

      This is actually the opposite of your example, all the extra code makes it more difficult to write, not easier, and it has the added issue of providing ZERO benefit, and often major drawbacks. For instance, if you just put raw HTML text on a page, it will format to every browser ever made, it will nicely fill the window, regardless of the size. But instead, developers put in all sorts of extraneous code to format it to specific window sizes, and the end result tends to be that it looks horrible on all of them (don't you just love the pages that only allow you to use 1/4 of the width of your screen for content with the other 3/4 being vast empty space, and yet you have to scroll for days to find the bottom?)

    7. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      Javascript doesn't want to be understood. When it emerged from the firmament, it said, "Here there isn't a flavor of me that won't bite." It was only within parallel dimensions of the multiverse that it could be found with a developer's sanity in mind.

    8. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      if ( (args[i][k]>0) && (args[i][j]<0) )

      Do that in three assembly statements.

    9. Re:We need to go back to simplicity. by imidan · · Score: 1

      Tangentially related, the needless complexity tends to make sites more fragile. I used to work at a place (during this decade) where we periodically had to go on a web site and fill out a form related to our work hours. The form was super simple in concept: it had a radio button array, a text box, and a submit button. It also didn't work in Chrome, and there was a big warning at the top advising users to use Internet Explorer or FireFox to access the page.

      This is content that has been supported by HTML for 20 years (!) or so, but whatever dope developed the page did it so badly that its function became browser dependent. It evoked the bad old days of 'This page optimized for Netscape Navigator' and similar mantras.

    10. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      Im always surprised the number of sites that show up as white blank nothing when I browse with Javascript disabled. Especially the majority of cms/news websites. It pains me to think how archive.org can even preserve content in that universe.

    11. Re:We need to go back to simplicity. by tlhIngan · · Score: 1

      If the browser is not showing the ad, the user is informed that they have to whitelist the site.
      Try and turn off or block scripts in the browser and the content will not show.

      It's gotten so bad that some sites aren't referencing 3rd party scripts anymore - the ad scripts are pulled by the webserver and incorporated into the page before it's sent to you. So whitelisting the site, automatically pulls in all the ads.

      Ir's probably the reason why our malware block on the firewall blocks more and more sites - because it's no longer some crappy sketchy 3rd party website offering up the malware code, it's the site itself as it proxies for the ad servers so ad blockers no longer can do a domain block.

      One popular torrent site got into a fight with a developer who write a custom set of scripts that disabled the ads (embedded in the web page so they could do popups and popunders and all sorts of other irritating things), but also inadvertently broke site functionality since it's not easy to isolate the chunks that were serving ads. Site blamed the developer for breaking the site, developer blamed the site for letting ad servers and networks have free run of their domain.

    12. Re:We need to go back to simplicity. by thegarbz · · Score: 1

      The page is one text entry box, and 2 buttons, plus a graphic above it. There is ZERO excuse for it being over 47,000 characters (not counting all the other stuff it pulls in).

      WTF, when was the last time you visited Google.com. I see a portal to the Google account, logins, view settings, access to calendar and apps, i also see a dynamically generated logo that can be interacted with.

      Look more closely.

    13. Re:We need to go back to simplicity. by AHuxley · · Score: 1

      How long before users have to select or paint over ads per site to try and get ads removed?
      Some powerful new code will be needed to get browsers working as they should on users computer to display only what a user wants.

      --
      Domestic spying is now "Benign Information Gathering"
    14. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      Abracadabra! Done.
      When I "code" ( I hate that word) sites I separate my HTML from my scripts and let the scripting engine on the site throw it all together.
      I can't help that what comes out is tossed salad, and I don't even car as long as it works.
      If noobs want to code there is nothing stopping them. Throwing together a basic site is as easy as downloading a LAMP and a basic IDE and diving in.

    15. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 1

      Agreed. Even though I am a developer, spending 8 hours per day writing C# and Javascript, my own personal site doesn't have any Javascript (no, not putting the link here, I don't want to come home to a 45 degree temperature in my bedroom, and a melted Raspberry PI on the floor).

      I have a menu that slides in from the left (Android style), images that "pop out of the page" (overlay div) when you click on thumbnails, only the pictures you view gets loaded, and it doesn't get loaded again if you click on it again, and even video. All that with HTML, CSS and zero Javascript.

    16. Re:We need to go back to simplicity. by gweihir · · Score: 1

      If you want "view source" to be useful, you need to go back to coding with simplicity in mind.

      Simplicity needs skill. In today's world, "web developers" often do not even understand the basics and have the lowest skills that just about will get the job done to some degree. Hence they rely on frameworks that may make some things "easier" to accomplish, but increase complexity massively and hide what is actually going on. The worst case I have seen is 2.5MB (!) of JavaScript to render a simple table that plain HTML would have done just as well.

      --
      Most ACs are not even worth the keystrokes to insult them. Be generically insulted by this and ignored otherwise.
    17. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      The main Google page is actually quite a bit more than what you describe. It detects if you pull it up on a mobile device and suggests that you install the appropriate app. It also providing autocomplete functionality for searches. The "Doodle" is not even always static, having been entire interactive games in the past. It is also looking at what cookies are present and tracing your geographic location to give more relevant results. So that little page is doing a bit more than you might be expecting to give you the functionality that it provides.

    18. Re:We need to go back to simplicity. by thegarbz · · Score: 1

      If you're writing a few lines of static content

      When was the last time you saw a few lines of static content on the internet?

      All of this talk is the metaphorical equivalent of pining for running a computer where the UI consisted of "C:\>" with a flashing cursor underneath.

      Google is a great example. Anyone who thinks it's a picture, a text form and two buttons, hasn't actually looked very closely.

    19. Re:We need to go back to simplicity. by Kjella · · Score: 2

      This is actually the opposite of your example, all the extra code makes it more difficult to write, not easier, and it has the added issue of providing ZERO benefit, and often major drawbacks. For instance, if you just put raw HTML text on a page, it will format to every browser ever made, it will nicely fill the window, regardless of the size. But instead, developers put in all sorts of extraneous code to format it to specific window sizes, and the end result tends to be that it looks horrible on all of them

      Bullshit. It will flow, but not "nicely". For example /. is all but unreadable at 100% on my 3840x2160 monitor, I have my web browser to 300% zoom, I could read it fine at 200% too but the lines just get uncomfortably long. There's a reason newspapers invented columns. Creating anything more complex than a single flow (like header, footer, columns for menus/other items) with tables or early CSS and mixing static/dynamic content like raster graphics with flowing text was total hell from the dawn of the web to the death of IE6.

      And not because the web site designers were incompetent, I've gotten my share of gray hairs trying to make it work and it was like doing layout with oven mitts. For example, simple things like one fixed sized graphic or a single long word exceeding the dynamic column width and some browsers would go ballistic overflowing or re-flowing everything rather than clamp it. Hard-coding and testing was the only way you could make it work and even then I had mysterious deviations showing up not only in IE but Netscape/Firefox/Safari/Opera too.

      I don't want to shit on what Tim Berners-Lee did because the concept of the web and hyperlinking is brilliant. But layout was never a topic in the initial design and the crude attempts to retrofit it later would have given those who did paper layout ulcers. And not even the big layout issues, simple things like soft hyphens where you write "hyper&shy;linking" to say that hyperlinking is normally one word but hyper-<br>linking would be an acceptable way to do a line break were missing or broken until way into the 2000s.

      --
      Live today, because you never know what tomorrow brings
    20. Re:We need to go back to simplicity. by ichimunki · · Score: 1

      Having to manually specify soft-hyphens is insane. Hyphenation rules are standardized and should come for free. A very small developer tool in the browser would then allow the developer to see which words on the web page are not in the standard dictionary and provide hyphenations as a resource file for their site (or specify in their head element).

      --
      I do not have a signature
    21. Re:We need to go back to simplicity. by Kjella · · Score: 1

      Having to manually specify soft-hyphens is insane. Hyphenation rules are standardized and should come for free. A very small developer tool in the browser would then allow the developer to see which words on the web page are not in the standard dictionary and provide hyphenations as a resource file for their site (or specify in their head element).

      Actually doing it for hundreds of languages is non-trivial, mixed-language texts are a giant pain in the ass and you might want historical texts to use historical rules and for all copies to look exactly the same. This would require all clients to dynamically update language rules as they're adjusted to present a consistent final result, even offline renderers without online access or else the text would look different. In my opinion this should be done by the development tool/CMS/web server and the client only render the HTML text as-is, though I suppose you could have some meta tags as fallback. And from an efficiency standpoint that would only need to happen once instead of each time the page is rendered, if there are some odd rules about use in idioms or in different meanings of a word it could be more complicated than a simple dictionary lookup. I did not mean that you'd normally write them by hand, I agree that would be silly.

      --
      Live today, because you never know what tomorrow brings
    22. Re:We need to go back to simplicity. by tepples · · Score: 1

      If your concern is about server CPU power consumption, could you post a link to a Cloudflare cache of your site?

    23. Re:We need to go back to simplicity. by tepples · · Score: 1

      At some point in the tracking blocking cat-and-mouse game, it becomes less complex to just put up a paywall.

    24. Re:We need to go back to simplicity. by green1 · · Score: 1

      If you have to look very closely to tell that it's not static content, then it doesn't deserve 47KB to render.

    25. Re:We need to go back to simplicity. by tepples · · Score: 1

      That must be some shitty assembly to need 100 lines to do something that can be done in 2 or 3 statements.

      if ( (args[i][k]>0) && (args[i][j]<0) )

      How much of that is the if statement, and how much is evaluation of its condition expression?

      Do that in three assembly statements.

      I hand-compiled your if statement to 14 instructions in 6502 assembly language. It's not 3, but it's not 100 either.

      ; assuming args is a global or static array of 128 or fewer
      ; pointers to signed byte arrays, that is, int8_t *args[];
       
      ; step 1: calculate tmpptr = args[i]
      ; tmpptr is a 2-byte variable on zero page
      lda i
      asl a
      tax
      lda args,x
      sta tmpptr+0
      lda args+1,x
      sta tmpptr+1
       
      ldy k
      lda (tmpptr),y ; A = args[i][k]
      beq args_i_k_equals_zero
      bpl else_clause
      args_i_k_equals_zero:
       
      ldy j
      lda (tmpptr),y ; A = args[i][j]
      bmi else_clause

    26. Re:We need to go back to simplicity. by way2slo · · Score: 1

      Thank you green1, I was about to post the same thing but with an emphasis on how HTML _is_ the easy on-ramp for curious amateurs that Thompson is talking about.

      And further, having a fancy View Source that allows amateurs to copy code they do not fully understand is dangerous as it could compromise their server and expose any traffic hosted by it should they use that copied code.

    27. Re:We need to go back to simplicity. by thegarbz · · Score: 1

      If you have to look very closely to tell that it's not static content, then it doesn't deserve 47KB to render.

      Let me rephrase my original point: Even Stevie Wonder wouldn't confuse Google's landing page for static content. Anyone who hasn't been living in a cave without power since 1997 will know that the Google landing page is the main portal to user's accounts. Anybody with functioning eyeballs can see that Google's landing page isn't actually just the landing page, but rather the complete search interface which dynamically changes as soon as you interact with it.

      Quite frankly it's an impressive feat that it ONLY takes 47KB to render.

    28. Re:We need to go back to simplicity. by audiokat · · Score: 1

      If you want "view source" to be useful, you need to go back to coding with simplicity in mind.

      The original post talks about viewing the source of the google homepage and getting an incomprehensible slurry. But why? What does that actually accomplish? The page is one text entry box, and 2 buttons, plus a graphic above it. There is ZERO excuse for it being over 47,000 characters (not counting all the other stuff it pulls in).

      Let's not conflate _visual_ simplicity with functional simplicity because the google homepage is not simple as described. The image is not a simple image, it's either the logo or a doodle that gets updated on various days or times. The text box is a regular text box until one starts typing or clicks the mic icon to speak a search, then it changes to a predictive search and starts showing results to get users to where they want to go more quickly. The top bar is not just decoration, it's links to other google apps and a user/login widget.

      But this isn't at all rare on today's web. This is also why so many pages are so horrendously slow to load, it's all scripts and links to other files and domains, even the simplest websites use absolutely incredible amounts of bandwidth, and yet do no more than could be done in 1/100th the size or less, and be human readable. 99.99999% of these sites aren't huge for any good reason, they're just horribly inefficient.

      Since 99.9999% of websites cost money to build, maintain and serve to clients and since a majority of clients are interested in free content rather than paying for content, it's either selling product or services, showing ads or eating the cost to cover the cost of building and running the site. Ads are terrible and bloat out most web pages as they only care about the ad being shown and additional services require engagement from users. This results in annoying behavior for users as they've learned to ignore ads on pages or use ad blockers, so now it's an entitlement fight - but remember that content creators don't have to create content. :-)

      As well, _most_ of the little sites (blogs, etc) use some sort of CMS framework to drive it and their owners want the blog to both look nice and have engagement features like sharing, etc., which requires more assets and more downloading than "simple" sites. Not only this, but users expect websites to work and look great on any device they fancy reading webpages on, so now there must be a bunch of responsive work and extra code to handle this kind of thing nicely. Generally that means developers will use a framework like boostrap or material design to accomplish it. This increases page bloat but is offset by better caching of the library if using a CDN correctly.

      Going back to google.com, the reason there's so much code in a "simple" page is that the guts of most of the logic for displaying the page and its widgetry is now working from the web browser instead of the server. It cuts down on page reloading and speeds up how quickly they connect users with their search results. And Google's front page and searching are _not_ slow.

      TL;DR google.com is not simple and there's no such thing as free - it always costs someone something.

      --
      Why is it that it's a penny for your thoughts, but you have to put your two cents in? Somebody's makin a penny. --Steven
    29. Re:We need to go back to simplicity. by green1 · · Score: 1

      It probably also sent you several hundred times as much data as would have been needed to just do it in raw HTML.

      This is the way the web has become though. Any "professional" site is cursed with garbage like that, and there's zero excuse for it. It works on only one or two specific browsers of specific version numbers, it usually doesn't flow properly if your window isn't the exact same size as the one used by the developer, and it breaks if you look at it funny.

      I guess nobody has heard of "KISS" anymore? (Keep It Simple Stupid!)

    30. Re:We need to go back to simplicity. by J053 · · Score: 1

      (don't you just love the pages that only allow you to use 1/4 of the width of your screen for content with the other 3/4 being vast empty space, and yet you have to scroll for days to find the bottom?)

      Kinda like /. lately - the content used to fill the window, but now it's all squeezed to the left and a deeply-nested comment

      winds up
      looking
      a bit
      like
      this

    31. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      mov eax, i
      mov edx, k
      call arg_cmp

    32. Re:We need to go back to simplicity. by Anonymous Coward · · Score: 0

      step 1: you build columns into your website to work for windows users who have 1920 horizontal pixels because the os is named windows but they don't know about windows

      step 2: someone tries to read your webpage with 600 horizontal pixels and sees two inches of text in the middle with tons of hyphens

  16. customizable 3D designs on thingiverse by Wycliffe · · Score: 1

    For 3D design, all projects that are "customizable" also have the source available. I've recently started teaching myself 3D design and being able to view the source on thingiverse brings back memories of when I learned to code by using the logo turtle and viewing the source of Oregon Trail.

  17. Re:Parent is a sissy faggot by Anonymous Coward · · Score: 0

    There are plenty of forms and video hosting sites were you can fulfill your fantasies. This site is for tech porn so unless your piss is thermal paste, his ass is a CPU socket, your shit is a VPN, and his chest an ISP, you're on the wrong site buddy.

  18. SDEs by Anonymous Coward · · Score: 0

    I had never heard of Glitch or CodePen before.
          'Opens links in new tabs'
          CodePen is a social development environment...
    and I hope to never hear about them again.

  19. Cuck alert! Cuck alert!! by Anonymous Coward · · Score: 0

    Cool story, cuck, but I wasn't talking to you.

    1. Re:Cuck alert! Cuck alert!! by FilmedInNoir · · Score: 0

      Is this a concerted effort on your part to get AC comments done away with? Translation: You trying to fuck it up for the rest of us shithead?

      --
      Sig. Sig. Sputnik
  20. Nobody got into programming.. by Anonymous Coward · · Score: 0

    Yes, because nobody got into programming before the World Wide Web was a thing. And even when it was a thing, nobody got into programming until javascript was invented.</sarcasm>

  21. Score another one for Seamonkey by fustakrakich · · Score: 1

    Not only can you view source (in living color), you can make source...

    --
    “He’s not deformed, he’s just drunk!”
  22. Modelines by Anonymous Coward · · Score: 0

    Use a modeline at the top of the file, 1 line for emacs and 1 line for vi. Then everyone will be happy.

  23. SeaMonkey. by that+this+is+not+und · · Score: 1

    The SeaMonkey suite still includes a Composer component. And you can cut and paste from the browser window to the composer and preserve the underlying markup.

    There is also an 'edit' menu choice in the browser that pulls up a local copy of whatever page you are on in the Composer. The composer has view tabs to look at and fiddle with the source and snap back to the wysiwyg view.

    Seriously, do none of you even know SeaMonkey still exists? I keep wondering, because it feels almost criminal how easy it is to drag and drop and save web content using it.

  24. bulls#*t idea here... by Anonymous Coward · · Score: 0

    From a pre java script era, historical perspective kind of thing to introduce new individuals, a Web browser like app could be made that has a legacy "view source" of various Web pages

  25. it's stupid because the on ramp is easier than eve by gl4ss · · Score: 1

    it's stupid because the on ramp is easier than ever..

    if you bother to make one google for it.

    its just an advertisement

    --
    world was created 5 seconds before this post as it is.
  26. First actual suggestion by Anonymous Coward · · Score: 0

    This conversation immediately exploded into "NO" "BAD!" And "DO NOT WANT". While most of them have a point, i'd say that the internet is more tinker-friendly than ever woth websites like github et al.

    To be the first to make an actual suggestion ;
    On www.openprocessing.org participants are encouraged to creatively read, tinker and learn with each others code.

  27. More complex by Anonymous Coward · · Score: 0

    The more features and secure the requirements, the more complex It will be. Thats the evolution.

  28. Dilbert = Cubicle Bible by Tablizer · · Score: 1

    PHB's want shiny bouncy things.....besides tits

  29. Same with printing! by Anonymous Coward · · Score: 0

    Why is there no easy way to see the postscript och HP-PCL code on the printer? I guess because the "source" is not really meant for human eyes. The reason you used to be able to look at the source for the http pages was because it was trivial because the servers were stupid, not because the source was designed for you to look at and hard code. No one hard codes printer pages any more, no one should hard code their web pages.

  30. Dev Tools has Replaced View Source by NaCh0 · · Score: 1

    In a small way, Thompson is correct. But a modern web developer wouldn't view source, they would right-click Inspect the element.

    There are many reasons for this but the most basic thing a novice (or out of date old-timer) should understand is that the code you see through View Source is not necessarily what you are seeing on the rendered version.

    This is due to several reasons but the most obvious are CSS and Javascript. CSS can modify the positioning, colors, size, and general layout parameters of an item. Javascript can modify the DOM, which in plain English means it has modified the original HTML file. These modifications may well include inserting or removing parts of the original HTML document.

    The browser dev tools show how things are, not how they came across the wire. It's a major mindset change from the 1990's web.

  31. reboot! by sheramil · · Score: 1

    We need to reboot the use of the word "reboot".

    "... You've had ELEVEN REBOOTS, people! When are you going to get a stable system?"

    - Bruce Sterling, closing remarks at Reboot 12

  32. Web Based Editors by darkain · · Score: 1

    We literally have countless web based documentation, tutorials, and editors. "View Source" is no longer needed. All of the good information is readily available without needing to dig into some half-assed "dev" tool that is literally just showing the raw text without any annotation whatsoever.

    Other than testing to ensure the contents sent from the server are exactly what I expected them to be, I've never used "View Source" otherwise in years. If you REALLY want to tinker, then the modern F12 dev tools like the DOM inspector are significantly better. Being able to inline edit DOM and CSS with real time changes is far more beneficial than simply reviewing flat source files.

  33. Mandatory car analogy by Anonymous Coward · · Score: 0

    "Back in ye olde days of the car superhighway," begins Clive Thompson in It's Time to Make Cars More Tinker-Friendly, "curious newbies had an easy way to see how cars worked: Wrench & Screwdriver." But no more. "Cars have evolved into complex, full-featured vehicles," laments Thompson. "Use Wrench & Screwdriver on any car and behold the slurry of incomprehensible parts. This increasingly worries old-guard mechanics. If the car no longer has a simple on-ramp, it could easily discourage curious amateurs." What the world needs now, Thompson argues, are "new tools that let everyone see, understand, and remix today's cars. We need, in other words, to reboot the culture of Wrench & Screwdriver."

    1. Re: Mandatory car analogy by Anonymous Coward · · Score: 0

      Amatuers can build track cars from scratch or components or kits. Or buy complete cars that are wrench friendly. It's a popular way to get into the hobby of car racing and there are lots of options for what you can race for just about any budget.

    2. Re: Mandatory car analogy by Anonymous Coward · · Score: 0

      Back to JavaScript:

      Amatuers can build websites from scratch or open source libraries or frameworks. Or buy complete website that are View Source friendly. It's a popular way to get into the hobby of making web pages and there are lots of options for what you can make for just about any budget.

  34. It's like arguing C++ will die because it compiles by Anonymous Coward · · Score: 0

    Total nonsense. It's like arguing that compiled languages are bad because you can't figure out how program works after it's compiled.

  35. Source by ledow · · Score: 1

    I would not want any budding programmer to learn from commercial, especially website, source code.

    Cases in point on this very website:

    Inside its own javascript tag for one line:

    var _gaq = _gaq || [];

    Further down:

    var _gaq = _gaq || [];

    inside a larger tag.

    Literally... wtf? From variable naming to why are you doing that, to why is it in twice and re-using the same name, to why is it wrapped in a tag for ONE line, and not in a header/js file rather than THIS page's (i.e. the submit form's) source?

    Not only that, literally 95%+ of this page is similar nonsense related to ad-blockers and Google Analytics. I wouldn't want to learn from that at all.

    I could confidently program any program you could suggest. I'm not saying it would be any good, or perfect source, but I can program, and in a number of languages. Not once have I ever used a commercial store of source code, or someone's live production code to do that, because it's often just a mess.

    You learn from nicely-made libraries, where the structure is amazingly well thought-out and clean. You learn from code snippets. You quickly learn from your own mess becoming unmanageable. But you rarely learn from just random code on random websites built for the purpose of obfuscation, easy compression, and automated generation that literally nobody ever sees. And, no, having more eyes on the code won't shame people, bad code propagates, it doesn't get shamed. "Even Slashdot has a mess of shit in its source, so why am I bothering to keep my tiny 1-page website clean, nobody will care"

  36. Those days are over. by Areyoukiddingme · · Score: 0

    How soon we forget. DRM crap has been approved as a web standard. View Source is going to show you nothing but the Javascript that says invoke_by_bullshit_DRM_here() and that's it. Because MBAs have taken over the web, and somehow the shitty HTML and even shittier Javascript being spewed by servers around the world is suddenly Amazingly Valuable Secret Sauce Which Must Be Protected At All Costs. A good sized chunk of the web is going to disappear into a DRM blackhole, and the only question is how quickly will it all be comprised and turned into an infection vector.

    1. Re: Those days are over. by Anonymous Coward · · Score: 0

      Butthurt much, nerdo loser?

    2. Re: Those days are over. by Anonymous Coward · · Score: 0

      On reflection, I apologise for calling you a nerdo loser. My micropenis sometimes causes me to lash out at others.

  37. So what? by Anonymous Coward · · Score: 0

    The time for amateurs is long past. We need professionals, not dilettantes. The '90s are past and the internet is thankfully different. New era, new rules.

  38. Discourage Who? by thegarbz · · Score: 1

    Who is being discouraged? Web developers and coders coming to fact the the world isn't static text and that coding should be learnt properly and given respect?

    Certainly not content creators which have an easier time than ever to generate content now.

  39. Easily sorted in Firefox by Viol8 · · Score: 1

    Right click then choose the "Prettify Source" option. It nicely reformats the code to be more readable.

    If cntrl-shirt-c doesn't work (hello OS/X) then Tools -> Web Developer -> Debugger

    1. Re:Easily sorted in Firefox by angel'o'sphere · · Score: 1

      Under OS X it might be command-shift-C.
      And bottom line it is the developers fault anyway and not OS X, they can make the Browser react to any hotkey they want. Most likely they simply did not assign one.
      However: with the keboard control panel and some googeling you can assign any hotkey you want to any menu item of any application, even if the developrs where to dumb to do that for you.

      Instead of ditching OS X, learn to use it properly.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    2. Re:Easily sorted in Firefox by Viol8 · · Score: 1

      I use it with a PC keyboard because the mac keyboards are such a pile of wank. And PC keyboards don't have the command key (no, the windows key doesn't work).

    3. Re:Easily sorted in Firefox by angel'o'sphere · · Score: 1

      Nevertheless you should be able to bind the key you want to the command you want ...
      I'm happy with my mac keyboard, though :D

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  40. No. No, we don't. by Opportunist · · Score: 1

    We do not need the return of the copy/pasted cargo-cult programming webpages. They were cute back in the day but today, they would present a security nightmare.

    Wanna make a webpage? Effin' learn how to do it right! It's not 1990 anymore, there's literally thousands of pages dedicated to teaching you how to make your own webpage, from the basics of HTML to the intimate details of JSON and REST APIs.

    It is all there. And for free. There is literally no need anymore to copy/paste code, fiddle with it and hope that it doesn't break despite not even remotely understanding what it does. Yes, I can understand that cutting corners and being lazy is comfy, but I also understand that these are the pages that cause enormous headaches because people not understanding why something works are also the people who create the worst security problems.

    --
    We used to have a Bill of Rights. Now, with the rights gone, all we have left is the bill.
    1. Re:No. No, we don't. by Anonymous Coward · · Score: 0

      we've never left the copy/pasted cargo-cult programming of webpages
      it's just that nowadays people are copy/pasting JS instead of html and css ... the web was both much safer and much faster when people where copy/pasting html and cs instead of js

    2. Re:No. No, we don't. by Opportunist · · Score: 1

      Actually, more and more people use prepackaged frameworks and js libraries, which is actually a step forwards in terms of security. At least they are built by people that MIGHT have an idea what they're doing.

      --
      We used to have a Bill of Rights. Now, with the rights gone, all we have left is the bill.
  41. Reboot Gopher by Anonymous Coward · · Score: 0

    Lets go back to using gopher and fuck the code completely, that way it is back to what it should be really about, content.
    For those too young to know
    Port 70 rocks!

  42. Hahahaha by technomom · · Score: 1

    Those of us who are really "old guard" laugh at the notion that anyone who cut their programming teeth in the age of the web browser would consider themselves "old guard". Let them eat core dumps.

  43. Blame Apple by Anonymous Coward · · Score: 0

    When Apple kicked Adobe Flash from their devices, it led to a rise in Javascript usage and encouraged the browsers to build in the annoying features of Flash. All the animated ECMA script *cough*'goodness'*cough* found itself in the browsers natively. All those CSS/JS easing equations came from Mike Penner who wrote them for Flash Actionscript 1.0

    At least with Flash it was containable, Apple released the demon. Adobe cackles with a whimper.

  44. JS can be wrapped behind attributes by Anonymous Coward · · Score: 0

    You can replace pretty much all of the useful JS features with embedded non-scriptable actions similar in style to any generic HTML attribute assignment, or even CSS-like.
    JS forms? They've now got input verification.
    You could easily add a generic RegEx matching system so you can roll your own verification if required.
    HTML templating? It's now a frontline feature in HTML5.
    And so on.

    I like JS, but even I agree most of it needs to die.
    It's fucking trash. And worse, it is way too easy to abuse on developer or malicious sides of the debate.
    Developers that create these shitheap websites are the reason we need, relatively speaking, super-computers on chips to actually run the damn things.
    You ever saw what sites like Facebook or Youtube do to computers even just 10 years ago?
    Progress schmogress. It doesn't make up for developers being lazy cunts.
    It's trivial to make a JS templating engine that will take a compacted source code, write it out fully as a blob then assign it as an active script using virtual URLs. It was doable even before that, you just created a new script element and slapped all the data inside there and made it self-invoking, done.

    1. Re:JS can be wrapped behind attributes by hord · · Score: 1

      Most of the new features in HTML5 (like templating) require JS. I guess you could bake template processing into the client but per the spec you need JS to clone and use templates. What about "data-" attributes? You don't "need" JS, but you they were put in with the idea that you would use JS to access them. I don't think a declarative language like HTML can provide the interface we want. Like it or not, JS or some programmatic language will be available. Otherwise you'll just be wrapping C/C++ in keywords which is practically the same thing.

  45. STUPID!!!! by Anonymous Coward · · Score: 0

    There are PLENTY of open source projects on GitHub to learn from. So let me call bullshit there first.

    Second, power consumption. Google.com is downloaded probably tens of millions of times per second more or less around the clock. No conside if you didn't minimize the code as much as possible. You see white space as a few extra bytes. I see it as a few extra microwatts of power at the PC, the router, the switch, etc... every single byte of data served from home pages like Google, Amazon, xVideos, etc... counts as possible megawatts of power consumed each year.

    Then there's unnecessary processing overhead. As pages become more complex, the devices needed to process them need to be more powerful as well. This means people dispose of old devices and buy new ones to play new web games. Consider that WebAssembly as Unity for WebGL and WebAssembly are now a real thing. This will be the new flash. To use it, people will throw away hundreds of millions of phones to get faster graphics and better batteries.

    So... quit being a whiny bitch. Your points aren't wrong... they're just not thought out.

  46. Decompiling by DrYak · · Score: 1

    View source is a relic of how the internet used to be. It's not coming back and I would argue should be hidden by default in browsers. It's akin to decompiling the source of an .exe file to look at the code (which some people do) and learn how it does things. Not a good method.

    It might come as a surprise to some, but decompiling .exe files to learn was actually a very decent method at some point in the past.
    Specially at a time (e.g.: older DOS era, speaking of EXE files) when when lots of these software were mostly written in (not too much optimized) assembler.

    Decompiler where mostly re-formating the code (indentation), inserting useful comments (regarding the IO-ports used and the parameters passed to software interrupt) thank to some dataflow code tracking, and giving meaningful names to some of the variables and subroutine (if tracking reveals that a sub end-ups being registered as some hardware interrupt handler, "irq_7_audio_handler" is a bettername than "sub_146_i").

    Learned quite a few trick back then by doing exactly that (e.g.: kicking the PC speaker into PWM-mode to play digital samples).

    Not as good as having the real original code (e.g.: looking how FRACTINT did kick the VGA into Tweaked mode / Mode-X), but still quite useful.

    Though much more straight forward than looking at even earlier code (self-modifying code from the heights of 8-bit era, spilling over to some early PC era when programmer got hired there).
    Or more modern/later code (written in higher level languages then optimized the shitout of by the compiler, or carefully hand-optimized SIMD code), where only the fully commented source could make some sense.

    And the web is slowly going into that direction :
    the ting that the web designer write isn't that much related to the thing that browser sees.
    they have nice modular tree of numerous JXL object using 3rd party libraries, that will be compiled into a single flat file,
    then minified (though it's not that much useful in the modern era where everything is compresed on the flight)
    then obfuscated (that is plain mean).

    Nobody writes directy plain HTML,
    and thus you won't see human readable HTML neither.

    --
    "Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
  47. Hyper Text Markup Language by DrYak · · Score: 1

    Pretentiously so, IMHO.

    Come on. Not everything needs to be Turing-Complete.
    (as PostScript, PDF and C++'s templating engine are).

    --
    "Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
  48. Nobody can read the result of View Source anymore. by OneSmartFellow · · Score: 1



    A really simple page like the plain old Google (http://www.google.com) is now 30,000 + bytes of crap.

    That's why we all need gigabit to the home.  Web Content providers are asshats who don't even think for a second about how much totally unnecessary garbage they ship with their pages.

    Want to make yourself feel sick, analyse how much of a typical webpage is absolutely unnecessary, redundant, unused HTML (or JS, or whatever).  Count how many times the font is specified, or how many times duplicated code is used (instead of a function call).  It's just slop, lazy, stupid.  That's why I don't consider Web Programmers to be programmers at all.

  49. What is this BULL? by Anonymous Coward · · Score: 0

    If the web no longer has a simple on-ramp, it could easily discourage curious amateurs.

    Luddites are a dying breed....literally. 3 year old understand how to operate current technology better than a 75 year old. There is no "curious amatuer" anymore - that is a phrased used by an aging writer that didn't 'grow up with it'

  50. Heard this before. by Anonymous Coward · · Score: 0

    He sounds like the guy that is complaining that he can't fix his TV anymore, because it's too complex and inscrutable. Happens in every technological area over time.

  51. Interesting by thegreatbob · · Score: 1

    Corporate interests wish to turn the 'web' into a series of apps... it's sad, really.

    --
    There is no XUL, only WebExtensions...
  52. Bad news, good news.. by Junta · · Score: 1

    Bad news: most web content has outgrown the simplistic 'view source'.

    Good news: As javascript has matured, technologies like java, flash, and activex in the browser that was used in the 'good old days' to get around how useless it was have gone away, and javascript is at least source (more to come)

    Better news: Browsers now have developer tools that can enable far more capable tinkering than was dreamed of in the 'view source' days. You can dynamically screw with html, css, and javascript, adding and deleting and trying things and reverse engineering a web site in incredible ways. See how it interacts via the network tab, look at the stack trace to discover the code that is trying to interact with that server side call. Look at any piece of thing visually on the page and look at the event listeners t ochase down code, etc.

    Discouraging news: The tendency to minify will mangle code in terrible ways. The whitespace removal is reversible, but the name mangling and globbing all files together and other things are hard to overcome.

    The real terrible news: The use of 'framework of the week' tends to screw up the debug capability of those developer tools. The event listeners on a DOM element are inscrutible and the stack trace of a network call can be very tall and magically not even include the 'real' code that arranged for that interaction (hidden behind some trick like scheduling request with setTimeout to get the good stuff out of the stack for BS reasons).

    Now one could lament that it is no longer acceptable to have plain-old, unstyled, static HTML, but 'view source' doesn't factor in there, and there is at least some refreshing resurgence of static content, albeit with styling to make it 'look pretty'.

    --
    XML is like violence. If it doesn't solve the problem, use more.
  53. Explanation about Medical Imaging by Texmaize · · Score: 3, Informative

    In a few posts, there seems to be some confusion about the use of java in medical imaging. What the above poster is likely talking about is a program released by the NIH called ImageJ. https://imagej.nih.gov/ij/ It is a wonderful application that is useful for image processing and even microscopy. There is a user community that has made many add-ons to increase functionality. It is written in java because macs are thing in the medical research world, and it was easier to support one java version than separate mac and PC things. That said, it was a little disingenuous to include that in this discussion about web programming. ImageJ is not used as web plugin, but more as an on local machine program. I think his point was, if you wish away all of java, you will wish away some things people use. The thread is about wishing away java for HTML purposes. Hope this helps.

    --
    "Liberalism is a very noble idea, currently controlled by some very bad people. Be sure you do not get the two confused.
    1. Re: Explanation about Medical Imaging by KGIII · · Score: 1

      Java is not JavaScript.

      --
      "So long and thanks for all the fish."
    2. Re:Explanation about Medical Imaging by Anonymous Coward · · Score: 0

      Oh, so Javascript is written in Java?

  54. There will be better programs by plopez · · Score: 1

    When there are better programmers. And based on prior experience reading code, testing job candidates, reviewing my own. code etc. that will probably never happen. Most of them are barely better than scary. The smart ones are overly clever. The honest ones quit when they realize they are at best mediocre (such as myself). That does not leave many to choose from.

    --
    putting the 'B' in LGBTQ+
  55. It's a srcset to everybody by tepples · · Score: 1

    I've seen some places where they could have the files sizes of their images cut in half without impacting quality.

    Until you view the picture on a high-DPI monitor, at which point the images become a blurfest compared to the adjacent text. To work around this, some sites send photos at double resolution in case the user is on a Retina display or in case the user chooses Zoom. The srcset attribute is supposed to fix this but still doesn't work correctly in IE or Edge.

  56. Too much abstraction is the problem by ErichTheRed · · Score: 1

    I can't really fault web developers for building incredibly complex pages that don't lend themselves well to interpretation. This is what happens when the industry says we can't have client-side applications anymore, and tries to shoehorn rich client functionality into a browser that wasn't really designed for some of the heavy lifting it's being asked to do. Browsers used to be thin clients back the the olden days, and JavaScript wasn't designed to replace the entire functionality of a rich client. Because of this, you have FrameworkOfTheMonth, and often multiples of them, layered on top of the DOM and JavaScript parser, and the result is unreadable client-side pages.

    I think that in general, the level of abstraction and the constant jumping around to the newest shiniest stuff make it very hard for anyone who's a total newbie to come up to speed unless you really start with first principles and work your way up. Back when applications were simple, it was reasonably easy to look at source code and understand how things fit together. It still is at the abstract level, but now the Legos being glued together look more like Duplo blocks. If you are a new web developer and start your education at the framework level, you miss all the under-the-hood stuff about HTTP, network communication itself, and how the browser actually interprets your high level calls.

    What I worry about is that the industry is going to shift to a point where the only people who actually know what's working under the hood work for software companies and cloud providers. As this continues, more and more of the low-level stuff is going to get cemented down below a layer of abstraction such that you can't change anything underneath. You might say this happened with assembler, etc. and I agree, but there should be a way for new entrants in the field to actually get to the first principles rather than starting them up 10,000 levels above it.

    1. Re:Too much abstraction is the problem by Junta · · Score: 1

      Further complicating matters is the often erroneous assumption that you simply *must* use some sort of framework. Javascript has matured, and while it still is missing a lot of basic stuff (e.g. basic string formatting), it is pretty well capable.

      For example, some people are afraid of XMLHTTPRequest and will use a framework to do it for them, despite them having to do about the same amount of work, but from the browser debug window, it's a whole lot more convoluted. In fact interaction with the server side *continues* to be the first thing these frameworks are standing up to try to 'help' me with, followed closely by things like an alternative version of getElementby* functions that are slower and not really any easier to use either.

      On the flip side, if I'm making UI elements, it's not *too* terrible to manipulate divs and do CSS to make those abstract HTML elements act like UI elements, but it tends to be the most tedious thing and frameworks are in fact generally not that much to help with that part. Of course before you go off making 'UI elements', you better be damned sure that much silliness really makes sense in the specific context, and that you are not hiding some straightforward information behind too much snazziness.

      --
      XML is like violence. If it doesn't solve the problem, use more.
  57. Unlike web apps, client apps are OS-specific by tepples · · Score: 1

    or you could just develop clientside software that does the same thing

    Good luck installing a client-side .dmg on anything but a Mac. Or good luck installing a client-side .msi on anything but a Windows PC.

    1. Re:Unlike web apps, client apps are OS-specific by Desler · · Score: 1

      Because we haven't invented automated build tools to do all that work for us? Oh wait, we have.

    2. Re:Unlike web apps, client apps are OS-specific by Anonymous Coward · · Score: 0

      It's almost like we need some kind of virtual platform, one where the same code, written once, behaves identically on multiple operating systems. Some kind of JIT compiler working off of bytecode....

    3. Re:Unlike web apps, client apps are OS-specific by tepples · · Score: 1

      Good luck running an automated tool to build and test Mac executables on a computer made by anyone but Apple.

      Legally.

    4. Re:Unlike web apps, client apps are OS-specific by angel'o'sphere · · Score: 1

      What is your point?
      Why would you not want to test macOS software on a Mac?

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
    5. Re:Unlike web apps, client apps are OS-specific by tepples · · Score: 1

      My point is that in a world without web applications, a macOS application often wouldn't get released at all because not all developers have a Mac. A web application developer can get by without owning a Mac on which to test because Chrome for Mac and Firefox for Mac behave just like their counterparts on Windows and X11/Linux, and Blink is similar enough to Apple WebKit that testing in Chrome passes for testing in Safari. A native application developer cannot.

    6. Re: Unlike web apps, client apps are OS-specific by Anonymous Coward · · Score: 0

      As a Safari users, let me tell you that you're so naive. It's crap like this (poor assumptions instead of real testing) that leads to bugs.

    7. Re: Unlike web apps, client apps are OS-specific by tepples · · Score: 1

      As a Safari user, are you willing to pay extra for Safari support so that each web developer can afford a Mac on which to test a site in Safari in addition to the computer he already uses?

    8. Re:Unlike web apps, client apps are OS-specific by angel'o'sphere · · Score: 1

      Ah, that was not really obvious (to me) that you where talking about Web applications.

      Anyway, web and desktop applications are completely different beasts, even with HTML5 local storage etc.

      --
      Cost free eBook I read (by iBook/Kobo/Amazon/ObookO/Gutenberg etc.): "The Green Odyssey" by Philip Jose Farmer.
  58. because the web owes newbies.....what exactly by Anonymous Coward · · Score: 0

    So technology owes newbies an easy way to learn, so they should allow their source code - the fruit of their labor - to be made available for anyone to learn from. I wholeheartedly disagree. Easy on ramps are how technology screwed up in the 90s - too many people were given roles in technology without the proper foundation in computing and networking. I have met many folks since then who are "self taught" or learned by looking at source code - very few have the basic understoodf well and I would feel comfortable leaving them on their own to do serious work

    Newbies need to learn. Period. Looking at someone else's source code will not teach the fundamentals of "why" something was coded a particular way. And, if coded badly, the newbie learns badly.

    Go to school. Learn the basics. And if there isn't a website you can copy from (in my opinion the main reason most people look at source code) then, poor thing, you'll just have to think a bit and develop your own.

    1. Re:because the web owes newbies.....what exactly by Junta · · Score: 2

      On the flipside, while these people *think* they are making expertly crafted sites, they've in practice poorly duct taped a bunch of stuff that looks fancy at a glance, but behaves crazy and is damned near impossible for anyone to figure out what's going on.

      What's happened here is we have a whole ton of people who can do the equivalent of drywall, paint, and decoration work, but can't build foundations or framing. Complicating things is the decision makers frequently can only judge the superficial, so teams that are good at doing that structural stuff but can't make attractive front end will be passed over for teams that can make something attractive, but works terribly.

      --
      XML is like violence. If it doesn't solve the problem, use more.
  59. CDNs track users by tepples · · Score: 1

    No, keep them as different files, but use a CDN. That way, your browser doesn't have to reload jQuery each time it goes to a new page or a new site.

    And the CDN can track viewers' behavior through the Referer and If-Modified-Since headers that browsers send to the CDN when checking whether jQuery has been updated.

  60. Most HTML source is simple by PPH · · Score: 4, Insightful

    <html>
    <script type="text/javascript" src="actual_page_content.js">
    <body>
    <h1>Please turn on Javascript to view this page.</h1>
    </body>
    </html>

    --
    Have gnu, will travel.
  61. Why? by Black.Shuck · · Score: 1

    Stack Overflow, Codecademy, Sitepoint, W3 Schools, JS-beautifier, and more besides, all just a click away in a Google search.

    I'm grateful for the huge progress in browser dev-tools, but why does anyone need to view-source to get into web programming anymore?

  62. More like 'morbidly obese CODE BLOAT' by Rick+Schumann · · Score: 1

    Know what I think is utterly rediculous? Having to enable gods-be-damned javascript for a site JUST TO READ THE TEXT! This shit has to STOP.

    1. Re:More like 'morbidly obese CODE BLOAT' by Junta · · Score: 1

      There is thankfully at least some trend of using 'static site builders' to do things static, with CSS to fool people into thinking it's appropriately 'modern' despite having a sane underpinning, without doing unnaturaly things with database backends and javascript and such).

      However that trend isn't nearly so pervasive as it should be.

      --
      XML is like violence. If it doesn't solve the problem, use more.
  63. Stop it! by grumpy-cowboy · · Score: 1

    Today's developers are bunch of lazy code monkeys who doesn't know anymore how to optimize/organize code.

    Yes it's the developer's fault if :
        - he use bloated framework;
        - he produce shitty code
        - he doesn't know how to do a proper SQL query, handle the transaction and close the connection after
        - he's not able to write clean HTML code
        - he doesn't know how to use a semaphore in concurrent programming
        - ..........

    No it's not "the fault of the industry" or anyone else!
    It's YOUR/OUR FAULT!
    It's YOUR/OUR MESS!

    Programming since 1988...

    --
    Will $CURRENT_YEAR be the year of the Linux Desktop?
    1. Re:Stop it! by Junta · · Score: 1

      - he doesn't know how to do a proper SQL query, handle the transaction and close the connection after

      Do you one better, doesn't know when *not* to be using database technology at all. Throwing a database (sql or 'nosql', 'webscale' or otherwise) at every little thing is just bad form.

      --
      XML is like violence. If it doesn't solve the problem, use more.
    2. Re:Stop it! by grumpy-cowboy · · Score: 1

      Exactly! And remember to use microservices everywhere and add 1000x complexity... Because you know, Netflix do it...

      --
      Will $CURRENT_YEAR be the year of the Linux Desktop?
  64. Search customizations by tepples · · Score: 1

    Why would you need an account for a search engine?

    To save your search customizations, such as which domains to exclude from results and whether to default to verbatim mode.

  65. Fix Transpilers & culture by Anonymous Coward · · Score: 0

    Fix Transpilers to by-default save the map files allowing people to read the original code.
    Then culture-craft an expectation of leaving map files in production. I've fought for this where I work (so far so good) because it helps debugging as well.

    Finally, help get everyone on ES6 browsers & have tools code to there. It'll be less obfuscated (just restore whitespace).

  66. Needs complete redesign. by Anonymous Coward · · Score: 0

    HTML and the way web pages are written needs a complete overhaul from the ground up. It's become an incomprehensible nightmare despite the simple layouts and functionalities of the vast majority of web pages. It needs to be totally thrown away and rewritten from the ground up, and I for one will totally cheer on anyone trying to do so (despite the obvious impossibility of the task given the widespread adoption of HTML).

  67. Sounds a little dangerous ... security-wise. by NoSalt · · Score: 1

    If they are suggesting that people need to view the source of the back-end (php, python, java, etc.) then that could lead to some security concerns. Knowing exactly how a site works could make it easier for some unscrupulous individual to hack into said site.

  68. pain in the freakin butt by Anonymous Coward · · Score: 0

    big time , i'm coding an automated farm on raspberry pi , 1500 lines of code , all environemntals monitered and controlable , yet what i find most chalenging is the web interface , 4 buttons and a page full of graph lines is a freaking pain in the butt , i dont want to have to learn 4 languages to do such simple things , html , php, css , java , this is nuts

  69. Press F12 by Anonymous Coward · · Score: 0

    See that lonely little "F12" key on your keyboard? Ever wonder what it does? Press it.

    That window that just appeared? You've just unleashed a superior View Source in the form of Developer Tools.

    (Disclaimer: If you run anything other than Firefox or Chrome or anything other than Windows, you may have to find some sort of finger contorted method to open Developer Tools.)

  70. Nope! by Anonymous Coward · · Score: 0

    You revisiting the history of the web just isn't helpful. It reads more like a lament of what could have been.

    You know what? The entire history of computing could be read as a lament of what could have been. It isn't yours or mine, it's ours, and we chose, through some bizarre process that resembles nothing so much as how a slime mold moves. It shouldn't be possible but it is.

    The GP is correct, View Source is a relic of another time. Besides, is learning a website (and thereby presumably learning how to make websites), really the best way? Where are the architectural diagrams? Where are the decision documents? Where is the project definition, the scope, the budget, the JIRA?

    I'm assuming a non-trivial website, but then View Source still works fine on trivial websites.

    I've learned enterprise systems using nothing more than the source code. You do it when and if you have to, but it's still the hard way to learn. And even when completed you are still left with numerous unanswered (and unanswerable) questions.

    Learn web coding the proper way. View Source is a lousy way to learn.

    1. Re: Nope! by Anonymous Coward · · Score: 0

      Anyone suggesting you to 'learn the proper way' is a bullshit salesman. Nobody can point to or agree on the 'proper way', and everything that gets suggested is either tied to a corporation, or is a horribly out-of-date reference.

      Neither are fit for learning the technology. They teach only methods of thought and theory, which is meaningless unless the student is taught *how* to apply it. Again, this never has it.

      We need to be honest about the subjectivity of "best practices" instead of setting people up to learn only one specific way to do things.

  71. Thompson's an idiot. by Anonymous Coward · · Score: 0

    "Websites have evolved into complex, full-featured apps," laments Thompson.

    HTML / JavaScript was never meant for applications, let alone complex, fully featured ones, so he's complaining about the wrong thing. I bet he'd really whine if he ever looked at the source code of a real application.

  72. JavaScript is not the problem by Anonymous Coward · · Score: 0

    I for one think that what makes webpage source codes unreadable is not JavaScript but HTML itself.
    Imagine if a website (assume it was possible) was designed using VB6 how easy it would be to read its code and also how much easier it would be to design any kind of website/webpage.

  73. Simple Check by pikester · · Score: 1

    We need a reasonable place to start. Look at HTML5 and then run your code through:
    https://validator.w3.org

    I like to code my stuff to that.