Skip to content
/ rails-turbo-vue Public template

A Rails 7 app that can use Vue to render parts of views on the client side

Notifications You must be signed in to change notification settings

HonuLife/rails-turbo-vue

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CI

Rails + Turbo + Vue

Render your views with Rails and then sprinkle in client-side rendered Vue components where you want them. When Vue components are used, they are dynamically imported and mounted, keeping your app's load times fast for users by keeping js bundle sizes small.

Features

Homepage

Dev

Setup

bin/setup

Run app:

bin/dev

Run tests:

Rails tests (including system/e2e tests)

rspec

Frontend (unit and component tests with Vitest)

yarn test

Generate a new scaffold with and have the views styled with TailwindCSS

rails g scaffold
# Ex. rails g scaffold animal name:string species:string age_years:integer

Generate a view that will mount a Vue.js component

rails generate view_with_vue index|show|edit|create ROUTE_PATH
# Ex. rails g view_with_vue edit animals/llamas will create the route /animals/llamas/:id/edit with a Vue component that loads on the view for that route.

Details

Versions of key dependencies:

  • ruby@3.3.0
  • Vue@3.3.4
  • rails@7.0.6.0
  • vite@5.1.6