‹ BackHN Continuity

Thread

Why don't more developers “use the platform”?

297 points · 314 comments · vinhnx

  1. toddmorey · · focus · HN ↗
    This got to me: > For a certain type of developer, building things yourself is just more fun

    The platform APIs were terrible. React wasn't "more fun"... it just made it possible to do things with the platform that were extremely difficult and cumbersome to get working reliably with platform APIs alone.

    To me, web components were an incredible idea poorly implemented. Most of the minimal adoption happened on top of frameworks like Lit that wrapped WCs to try to make the dev experience tolerable.

    In urban planning they have a concept called "desire paths" where if you don't put sidewalks and pathways in the right places, people invent their own. I feel like the web community has spent a lot of time and effort patching the platform.

    Now credit where credit is due: it has very much improved. And modern standards means it really is time to re-evaluate where and when you need these patches. But don't write off all that annoying and painful effort people put in to trying to making the platform deliver it's promised potential just to "building it yourself is more fun".

    1. austin-cheney · · focus · HN ↗
      > The platform APIs were terrible.

      In what way?

      After doing this for more than 20 years I have asked that question hundreds of times and the answer is almost always about aesthetics, about 95%+. Of those aesthetics based conclusions most people cannot find their own way to handle it without waiting for somebody else to write a tool that provides the answer they were looking for. Even then the answer tends to be predicated on social acceptance more than technical evaluation. That is a training or human performance problem more than a technical problem. It says a lot about an industry where the people who are able to ask these kinds of questions realize its a training problem and are willing to raise salaries and assume tech debt as opposed to fixing a human capital problem for far less money.

      At any rate there is something to be said for the developer who builds things on their own just for themselves. In many cases the result is faster, lighter, and more capable software than what they are paid to do for their employer. Their personal software isn't locked into conventions or abstractions beyond their control.

      1. zdragnar · · focus · HN ↗
        The APIs are expensive for storing state (read access on attributes) and expensive to write (so many ways to trigger reflows and paints) without a good way to batch them.

        WCs have tons of boilerplate to them, such as extra song and dance to make attributes observable. In fact, a custom element can have an attribute and a property with the same name, and they are managed separately unless you explicitly set them up to sync. It's a terrible design.

        Built-in things aren't extensible - there's no way to have a number type input that doesn't suck without doing it yourself, and then you need to opt into extra song and dance for your element to participate in form submission data.

        There's a reason popular frameworks are popular. They're good enough, you can hire people who already know them, and you benefit from the maintainers fixing bugs for you.

        1. marcus_holmes · · focus · HN ↗
          > Built-in things aren't extensible - there's no way to have a number type input that doesn't suck without doing it yourself, and then you need to opt into extra song and dance for your element to participate in form submission data.

          This is the bane of every UI out there. "I hate the inbuilt controls so I'm going to write something better that doesn't look terrible!". Then they build some half-arsed thing that doesn't do accessibility right and only works properly on an up-to-date Chrome-based browser in a US locale with javascript enabled.

          The built-in controls should always be used, not because they look pretty, but because they work the same across all websites. Users don't have to guess how this site's bespoke time-picker works (and how it doesn't). It won't fail in unexpected ways. It'll deal with your locale's date format so you don't accidentally specify the 5th of June when you meant the 6th of May.

          Not everything has to be pretty all the time. Functional works, too.

          1. zdragnar · · focus · HN ↗
            > The built-in controls should always be used, not because they look pretty, but because they work the same across all websites.

            Funny that you mention date/ time but ignored my example of the number type input, which does not work the same across all browsers.

            In any case, it proves the point I was originally making; if the built in controls were extensible, we wouldn't be in the position of reinventing the entire stack because the design team wants to be unique.

Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.