Sha256: 0da664a4b450092c07f7fac51430df7382d49ced86522640bfd8d0a8daffac3f
Contents?: true
Size: 552 Bytes
Versions: 1
Compression:
Stored size: 552 Bytes
Contents
# frozen_string_literal: true def package?(package) require "json" file = File.open("package.json") if File.file?("package.json") packages = JSON.parse(file.read) if file packages["dependencies"].include?(package) if packages end run "bundle add tailwindcss-rails" if package?("react") run "rm Procfile.dev" run "rm bin/dev" end rails_command "tailwindcss:install" if package?("react") run "rm Procfile.dev" run "echo 'web: bin/rails server -p 3000\njs: yarn build --watch\ncss: bin/rails tailwindcss:watch' > Procfile.dev" end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
rails-interactive-2.1.3 | lib/cli/templates/setup_tailwind.rb |