JSFoo 2019

On component architecture, front-end engineering and Developer Experience (DX)

Sprinkle Javascript with StimulusJS

Submitted by Leena S N (@leenasn) on Aug 4, 2019

Section: Crisp talk (20 mins) Technical level: Intermediate Status: Confirmed & scheduled

Abstract

In this world of Microservices, I am building a Monolith app. In this world of React and Vue, am building a server-side rendered app.

However, I need Javascript. I can’t avoid that. I need some parts of the page updated dynamically. I need to show/hide certain parts of the page depending upon user actions.

I don’t want JQuery for the obvious reasons. Slow.., Heavy and then, of course, it can easily create spaghetti code.

That is when I came across Stimulus JS - a modest Javascript framework. It sprinkles Javascript to add behaviour to your HTML.

It has a controller, action and targets (i.e. the HTML elements). Moreover, it pairs well with Turbolinks. So I don’t need to do the circus of converting JSON to DOM.

I’ve been using Stimulus for over a year and its been quite good. This talk is about my experiences with Stimulus with a few examples. I will share recommendations on where it might be useful and where it is not.

Outline

  • Quick introduction about StimulusJS
  • A quick example
  • A few more examples (where I’ve used Stimulus for my product)
  • Recommendations, Pros, Cons, Further References

Speaker bio

Co-founder/CTO/Programmer @ Good Karma, Bangalore.

A pragmatic & passionate programmer, lean thinker, eXtreme Programming evangelist, hooked into Continuous Delivery. A mother of two lovely angels.

Links

Slides

https://www.slideshare.net/leenasn/sprinkle-javascript-using-stimulus-js

Comments

{{ gettext('Login to leave a comment') }}

{{ gettext('You need to be a participant to comment.') }}

{{ formTitle }}
{{ gettext('Post a comment...') }}
{{ gettext('New comment') }}

{{ errorMsg }}