November 6, 2018

[Ask IH] The tiniest and yet reliable JS framework?

Hi everyone!👋

I'm currently working on the light weight app, and curious if there are any mature and still tiny js frameworks other than React/Angular/Vue?

Last time I've been working on js was more than a year ago, so I guess I need to re-learn everything again, and that's sort of pain point for me. 😅

It's a very basic web app with registration and admin panel. Nothing complicated so no need to load gazilions of modules just to make it working 🤯

Any recommendations?

Thanks in advance and have a great day!

  1. 8

    I'm a huge fan of this crazy tiny framework, it's been around literally forever and its core is super robust.

    You should check it out!

    1. 1

      Thanks Julian. I will check it out 👍

      1. 3

        Hope that you know vanilla-js is a satire on the JS frameworks. It just means that you should use plain JS and no frameworks :).

        1. 2

          Oh yeah I know 🤪, just opened the link. Literally the best ever framework

  2. 5

    Mithril.js is like a tiny Reactjs with routing included. Robust community and good support. They just put out version 2.

    1. 1

      I used to use mithril a couple of years ago, completely forgot about it. Thanks for reminding

      1. 1

        Here is a nice list, not necessarily tiny but a few are. Mercury is interesting in that you can swap out libraries for various features easily. I like the syntax for ritli.

  3. 3

    If you've written React before, check out Preact. Same API, super lightweight.

    1. 1

      Seems like it's exactly what I'm looking for. Thanks Max 🤩

      1. 1

        No worries 😄

  4. 3

    How much js do you really need? Do you really need it on a registration form?

    In my current project I'm using stimulus and it's on one side very minimalistic but also I have a clear separation between my html and javascript while still having all those data attributes in the html that give me a 100% insight into what will happen js-wise.

    1. 2

      +1, Stimulus & Turbolinks is a great combo.

    2. 2

      Seconding Stimulus. If you just need to add little bits of JS, it gives you a bit structure/conventions that makes everything a bit easier to develop.

      Use it in production in two apps.

    3. 2

      Yeah basically registration, simple admin panel and couple of forms. Never heard about stimulus, looks robust

      1. 1

        I'm using it for things like this calculator inside input fields:

        My personal goal when using js is to give extra functionality, and not just build a SPA.

  5. 2

    The guy who created inferno was hired by Facebook to work on React. :-)

    Inferno is stupidly fast.

    1. 1


  6. 2

    Glad you asked. :) Did not know about stimulus.

    BTW, is a contender in this? Comments, please.

    1. 1

      I assume mustashe.js is a sort of templating engine like jinja in python.

      1. 1

        Oh. Thanks for the reply.

  7. 2

    Nobody is forcing you to re-learn everything, you can still make money with backbone.js or jquery or whatever. Use what feels comfortable for you!

    If you want to use something modern, React and Vue are both small and good.

    1. 3

      I've used backbone for several years and wouldn't use it again. It had it's time and purpose but especially my backbone views grew like monsters with more and more functionality that I rather put into their own components. I even came up with a way to have sub views in my backbone views.

      1. 1

        I had this experience, too. Backbone is tiny compared to its newer, more popular competitors, but the result of having such a small library is that you have a lot more code in your app itself!

        1. 2

          yeah writing a lot more code is definitely what I would like avoid as much as possible 😅

  8. 1

    I am fan of these -

    1. mithril.js

    2. preactjs

    tiny and high performance!

  9. 1

    Try Polymer.js theoretically it might go to zero size if all browsers support components fully. Also it has descent component ecosystem

  10. 1

    I'm using simulacra.js for my own projects. What's unique is that it does not look like there is any UI code or templating at all, everything is just data structures and basic operations like set (=), .push, index assignment [n], .splice. Disclosure: I am the author.

    1. 1

      This looks super interesting as an easy way to add to html coming out of Wordpress or Cake PHP type server side frameworks.

  11. 1

    I'm using Vue for I found it really easy to get going, there's not much to learn, lots of plugins and the next version of Vue isn't meant to be radically different.

  12. 1

    take a look at KnockoutJS here

    it's simple and easy to learn

  13. 1

    Just putting out here

  14. 0

    I'm working with Vue and it's really easy to get set up and developing. There is a github page: that should have loads of examples that you could try out.