It is about time we start thinking of real alternatives to JS in the browser.

What is wrong with TKinter on the web?
JavaFX? Even Windows Forms dude!

I am sick of the darn following:
- Webpack, Parcel
- React, Angular, Vue
- Typescript, babel
- Polyfills
- undefined
- Maintainability
- BlaBla does not have a constructor
- <any>


  • 3
    I don't think the issue is JS as much as it is the hype. As a personal general rule: I don't like using JS for ui design at work.

    I kuch greatly prefer server side rendering, and each view holds the state it needs through some basic ajax functionality, you can get pretty fucking far with just vanilla js with as much dependency as axios for handling the requests. you have the "component" being rendered by whatever server side language you use and then if it needs such state functionality you can hook them up per page through a js file (obviously minified) or something like that.

    I have set the test to do the same thing between Angular, React, and Vue, they really are not bad, but learning and fighting them can take ages.

    As soon as someone automatically reaches for a frontend framework when starting a project I already think they lost the fight
  • 4
    To some degree people are already leaning that way. Microsoft has been working on shipping win forms via wasm, you can compile a significant number of languages to it.

    The thing to pay attention to is that whatever solution is going to be survivable is going to need a cross platform story, a large engineering community behind it and a path forward that to whatever extent is feasible doesn't have first and second class citizens.
  • 1
    @AleCx04 Exactly what is in my mind. The hype sometimes causes a lot of stress as everyone at work and online just talks about it and how good it is without even considering alternative approaches to the problem.
  • 3
    Maybe ditch the web entirely?
  • 1
    @SortOfTested I would love that and keep looking into their blazor project because c# is just pure joy as a language
  • 0
    @SortOfTested Survivable is a different story of stress 🙂💔.
  • 2
    That's going to fail outside the bubble. Sanderson isn't capable of making decisions necessary to get it adoption in the broader market. It's also had far too much "pay no attention to the man behind the mirror" going on since the beginning; big promises, under delivery, massive package size, performance issues and limitations in UI that just don't exist elsewhere and have no simple remediation.

    F# and fable are much nicer, have almost none of the issues, but sadly get almost no attention.
  • 0
    @electrineer Seriously thinking about it. The only thing stopping me is the amount of effort over the past three years and keeping my job.
  • 1
    @SortOfTested oooooh i did not know about that one, i'll check it out. I have close to 0 knowledge of doing anything substantial with F# though
  • 1
    I'm up for something other than JS, but then what is it?

    All that shit you list... is gonna still exist if you just swap out a language as folks try to figure out how to make web apps, deal with layouts, SEO...

    JavaScript didn't make that, and the next thing isn't likely to 'solve' all of that.
  • 2
    .Net needs a significant modularization update to replace the mono runtime in wasm. The biggest impediment to broadscale adoption is and will remain having to put a 3mb payload that explodes into 60-100MB from app start into a browser. This crushes mobile devices.
  • 0
    If not Blazor.
  • 1
    @SortOfTested dear lord that is bad. So my dream to use c# for everything is kinda sorta on a hold for now then. Shame, the language is really a joy to use. But that is me just fangirling over everything Anders Hejlsberg
  • 4
    Def. Typescript is excellent as well, sans a few rough edges. The man is brilliant.
  • 1
    You could give Flutter a try in case you prefer Dart over JS
  • 4
    Just because you know Java/Python doesn't mean it should be used everywhere, Web is doing great with JS, much better than any alternative would be able to do. Maybe you should expand your stack if you want to do web development.
  • 2
    F# to the rescue!

    Also, WASM, or just Elm if you want an fs lang that's waaaayyy better than JS.

    But: F# to the rescue! (I'm glad someone brought it up already)
  • 2
  • 5
    But I’m gonna disappoint you. If you want seo, there is no alternative to just html because that’s how it works. Also if you want accessibility (and you want it if you believe in human rights), forget about anything but html and js.

    If you only develop browser games then sure fine go with wasm. If not, you have NO OPTIONS. Try some compiled stuff like clojurescript
  • 1
    @theabbie Already been doing that for quite a while with Plain JS and/or Vue (Which I know more than both Java and Python). I was just quite frustrated at reading the shit ton of documentation about tooling I have to read every time.
  • 2
    @aj7397 Plain JS is more than enough for everything you need, unless your whole Job is about Web Development, you don't need Any UI tools.
  • 1
    Using hammer for screws and rake for sweeping the snow of your porch!??

    Each problem has its solution and each project has requirements - use tools that best fit the requirements of the damn project.

    Why I should use C# for that? cause its delight to write it?If i need friggin dashboard and some d3 charts to analyse the friggin data would rather use html + js fetch + d3 lib instead, even better some SSR and just serve the data for the frontend.

    ELM? I was on the conference where some guy had lecture something like 'how elm tought me to love web development'. Whole lecture was about how haskel is great and everybody should use it for everything forever until the end of time. Then he showed us what it looks like when you have to write down simple select with two options.

    83 friggin lines of code to compile to what effectively was 5 lines in html, same in any JS framework. Horrible DX!

    Don't pitch your language preference as the best solution until you know what are the requirements.
  • 1
    @devJs oooh, butthurt js fanboy, butthurt much?
  • 3
    @100110111 not really, I prefer Typescript for web projects, for games C#, for backend python and golang.

    Use cases and requirements makes the choice not my preference tough. If customer has tight budget, use the tools that will meet the deadline without writing shitty code.

    You can be technical AF, but be realistic, it all goes down to the business case!
  • 2
    1. Static HTML with link to <app stores of your choice>

    2. Favorite Language + Webassembly
  • 3
    I think rather than getting rid of JS, we should get at the root of the problem.

    I mean, the "alternatives" you mentioned (like TKinter, JavaFX and WinForms) all have their own issues and qircks and definitely will obtain more if we use them in the web browser...

    also, SPA/MPA and SEO are not exactly products of JS entirely...

    You can also make SPA in Python and PHP...

    SEO is just a by-product of well.. search engines...
  • 2
    You mention SEO which confused me as to what that has got to do with frontend.
    But then I realize: yeah if you do everything clientside suddenly the most basic SEO like having a plain old title tag on an articlePage becomes a tooling challenge.

    My advice:
    Use serverside rendering as a base.
    The essential content should be rendered serverside as much as possible, only use JS for personalized stuff and some interactive features.

    Build proper HTML forms

    Your should be able to disable Js and still read an article, look at a product and submit your contact form.
  • 2
    @jiraTicket exactly, and if you use some layout engine other than HTML/DOM and render to canvas instead, Google won't be able to index the content and make it searchable, follow the links, etc.
  • 1
    how about we just finish making webasm into a fully functional thing so that we can compile any language for web use?
Add Comment