Skip to content

n00ki/modern_rails_starter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Modern Rails Starter 🚀

Modern Rails Starter is an opinionated, fully configured template for developing modern web applications using Rails 6. Pre-Configured with Hotwire (Turbo & StimulusJS), TailwindCSS, ViewComponent, Devise, Pundit, Sidekiq, Pagy and many other great tools, you can use this template to kickstart your own reactive web applications.

This template is based almost exclusively on the amazing contributions of Andy Leverenz & Chris Oliver. Please consider supporting their work.

Prerequisites

  • rbenv (recommended) / RVM / chruby *(optional)
  • Ruby (>= 2.5)
  • Rails (>= 6.0) - gem install rails
  • Bundler - gem install bundler
  • Yarn - brew install yarn or Install Yarn
  • Redis - brew install redis or Install Redis
  • Hivemind / Foreman *(optional) - gem install hivemind

🔨 Toolbox (Included, pre-configured gems & tools)

General:

Development:

Getting Started

The easiest way to get started is to clone the repository, create a new rails app and pass the template file through:

# Get the latest snapshot from GitHub
git clone https://github.com/noamsun/modern_rails_starter.git modern_rails_starter

# Navigate to your projects directory and create a new app
rails new my_app -d <postgresql, mysql, sqlite3> -m /path/to/modern_rails_starter/template.rb

# Change directory
cd my_app

# Run your Rails application

# In Development:
hivemind Procfile.dev

# In Production:
hivemind Procfile

Once created, what do i get?

  • TailwindCSS Support (using Webpack), configured for Inter font.
  • Flexible authentication with Devise & user impersonation with devise_masquerade (a new name field already migrated in, which maps to the first_name and last_name fields in the database (thanks to the name_of_person gem).
  • Pre-baked, devise-compatible Turbo & StimulusJS (Hotwire )support.
  • ViewComponent Support. This template installs the gem and generates a test component (and a preview).
  • Simple, efficient background processing with Sidekiq and whenever.
  • Object oriented authorization with Pundit.
  • Friendly IDs out-of-the-box. This template installs the gem and runs the associated generator. check friendly_id's documentation for more information about integrating it with your own models.
  • Faster pagination with Pagy. This template installs the gem and creates a default config file.
  • Ready-to-use ActiveStorage and mini_magick.
  • Developer happiness guaranteed with great tools like pry-rails, faker and annotate.
  • Enhanced boilerplate views using TailwindCSS (thanks to Andy Leverenz).
  • Hivemind/Foreman Support (environment-based Profciles)
  • Git initialization out-of-the-box.
  • PurgeCSS configuration.
  • Custom defaults for button and form elements (by Andy Leverenz).

Stop procrastinating, start building! 💪

About

An opinionated, fully configured template for developing modern web applications using Rails 6

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published