Tep8
提供: wikipokpok
準備
create application
% rails new . --css=tailwind --javascript=esbuild --database=postgresql
% bin/bundle add tailwindcss-rails
% bin/rails tailwindcss:install
% bin/setup
% rails generate scaffold NameList name:string kana:string head:boolean line:integer buddhist_name:string alive:boolean birth:string death:string g_age:string memo:text generation:string
validates :name, presence: true
t.string :name, null: false
% bin/rails db:drop db:create db:migrate
% bin/rails test:system
% bin/dev
テストデータ
テストデータと開発データの同期
# db/seeds.rb puts "\n== Seeding the database with fixtures ==" system("bin/rails db:fixtures:load")