The magic of creating immutable data structures that can be manipulated with conventional JavaScript mutation…

The magic of creating immutable data structures that can be manipulated with conventional JavaScript mutation operators is to use proxies under the hood.

These convert mutations into selectively copied data. Think: structurally shared data structures like in ImmutableJS or Clojure.‬

I like this.

I like this.

If you’re a full stack developer who is reluctantly mulling over jumping into front end development, you should perhaps stop and consider this approach instead.

Unlike other front end frameworks like Angular and React etc, Stimulus isn’t about constructing the DOM from a blank page, it’s about augmenting the HTML that has already been delivered from the server. It also uses Ajax to smooth the transitions between pages of HTML without losing the ability for the server to serve full HTML page rather than just delivering JSON.

This is about going back to the web the way it was when it was all server side but Stimulus is also about smoothing out those gnarly edges that made it so shit at times. This augmentation approach is the one taken by BaseCamp. GitHub also uses a fairly similar technique to produce an elegant high scale UX.

Stimulus is lightweight and coexists nicely with things like Bootstrap and Material Design Lite without needing to rewrite their JQuery or JavaScript support libraries.

This framework is by the creators of Ruby on Rails.