Lazy Load Form Fields In Rails Using StimulusReflex

This page summarizes the projects mentioned and recommended in the original post on dev.to

Our great sponsors
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • SaaSHub - Software Alternatives and Reviews
  • Octokit

    Ruby toolkit for the GitHub API

  • Some important things in this reflex. One, since our partial requires a form object, we use ActionView::Helpers::FormBuilder to create a form for a user building an initial repository. Since it requires a view_context, we leverage a delegate to access it from the controller. Two, the Octokit client requires a user authentication token, so we add delegate to the connection so we can access the current_user. Three, rather than triggering a full page morph, we instead can use a selector morph so it only updates the div with id #repositories.

  • Stimulus

    A modest JavaScript framework for the HTML you already have

  • Stimulus is powerful library that lets you “sprinkle your HTML with controller, target, and action attributes”. And StimulusReflex lets you trigger server side code to do page updates. Together they are a powerful combination for Rails!

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts