回答編集履歴
3
ソースファイルの追加
answer
CHANGED
@@ -8,4 +8,123 @@
|
|
8
8
|
|
9
9
|
# 教訓
|
10
10
|
- サイトのコピペを理解せず多量に行うと何を改変したか忘れてしまう。
|
11
|
-
- Gitのログを遡るという基本的なことを忘れていた。
|
11
|
+
- Gitのログを遡るという基本的なことを忘れていた。
|
12
|
+
|
13
|
+
# 修正後
|
14
|
+
package.json内
|
15
|
+
```
|
16
|
+
{
|
17
|
+
"name": "reservation-app",
|
18
|
+
"private": true,
|
19
|
+
"dependencies": {
|
20
|
+
"@babel/preset-env": "^7.14.7",
|
21
|
+
"@babel/preset-react": "^7.14.5",
|
22
|
+
"@babel/preset-typescript": "^7.14.5",
|
23
|
+
"@rails/actioncable": "^6.0.0",
|
24
|
+
"@rails/activestorage": "^6.0.0",
|
25
|
+
"@rails/ujs": "^6.0.0",
|
26
|
+
"@rails/webpacker": "^5.4.0",
|
27
|
+
"@types/react": "^17.0.14",
|
28
|
+
"@types/react-dom": "^17.0.9",
|
29
|
+
"bootstrap": "^4.5.3",
|
30
|
+
"jquery": "^3.6.0",
|
31
|
+
"popper.js": "^1.16.1",
|
32
|
+
"prop-types": "^15.7.2",
|
33
|
+
"react": "^17.0.2",
|
34
|
+
"react-bootstrap": "^1.6.1",
|
35
|
+
"react-dom": "^17.0.2",
|
36
|
+
"react_ujs": "^2.6.1",
|
37
|
+
"ts-loader": "^9.2.3",
|
38
|
+
"turbolinks": "^5.2.0",
|
39
|
+
"typescript": "^4.3.5"
|
40
|
+
},
|
41
|
+
"version": "0.1.0",
|
42
|
+
"devDependencies": {
|
43
|
+
"pnp-webpack-plugin": "^1.6.4",
|
44
|
+
"webpack-dev-server": "^3.11.2"
|
45
|
+
}
|
46
|
+
}
|
47
|
+
|
48
|
+
```
|
49
|
+
Gemfile
|
50
|
+
```
|
51
|
+
source 'https://rubygems.org'
|
52
|
+
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
|
53
|
+
|
54
|
+
ruby '2.7.2'
|
55
|
+
|
56
|
+
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails', branch: 'main'
|
57
|
+
gem 'rails', '~> 6.1.3', '>= 6.1.3.1'
|
58
|
+
# Use sqlite3 as the database for Active Record
|
59
|
+
gem 'sqlite3', '~> 1.4'
|
60
|
+
# Use Puma as the app server
|
61
|
+
gem 'puma', '~> 5.0'
|
62
|
+
# Use SCSS for stylesheets
|
63
|
+
gem 'sass-rails', '>= 6'
|
64
|
+
# Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker
|
65
|
+
gem 'webpacker', '~> 5.0'
|
66
|
+
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
|
67
|
+
gem 'turbolinks', '~> 5'
|
68
|
+
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
|
69
|
+
gem 'jbuilder', '~> 2.7'
|
70
|
+
|
71
|
+
# gem 'jquery-rails'
|
72
|
+
# Use Redis adapter to run Action Cable in production
|
73
|
+
# gem 'redis', '~> 4.0'
|
74
|
+
# Use Active Model has_secure_password
|
75
|
+
# gem 'bcrypt', '~> 3.1.7'
|
76
|
+
gem "activeadmin"
|
77
|
+
|
78
|
+
#cancancan
|
79
|
+
gem "cancancan"
|
80
|
+
|
81
|
+
#.env
|
82
|
+
gem "dotenv-rails"
|
83
|
+
|
84
|
+
# gem 'bootstrap', '~> 4.5.0'
|
85
|
+
|
86
|
+
# Use Active Storage variant
|
87
|
+
# gem 'image_processing', '~> 1.2'
|
88
|
+
|
89
|
+
# Reduces boot times through caching; required in config/boot.rb
|
90
|
+
gem 'bootsnap', '>= 1.4.4', require: false
|
91
|
+
|
92
|
+
#calendar
|
93
|
+
gem 'fullcalendar-rails'
|
94
|
+
gem 'momentjs-rails'
|
95
|
+
|
96
|
+
#react-rails
|
97
|
+
gem 'react-rails'
|
98
|
+
|
99
|
+
#devise
|
100
|
+
gem "devise"
|
101
|
+
|
102
|
+
|
103
|
+
group :development, :test do
|
104
|
+
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
|
105
|
+
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
|
106
|
+
end
|
107
|
+
|
108
|
+
group :development do
|
109
|
+
# Access an interactive console on exception pages or by calling 'console' anywhere in the code.
|
110
|
+
gem 'web-console', '>= 4.1.0'
|
111
|
+
# Display performance information such as SQL time and flame graphs for each request in your browser.
|
112
|
+
# Can be configured to work on production as well see: https://github.com/MiniProfiler/rack-mini-profiler/blob/master/README.md
|
113
|
+
# gem 'rack-mini-profiler', '~> 2.0'
|
114
|
+
gem 'listen', '~> 3.3'
|
115
|
+
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
|
116
|
+
gem 'spring'
|
117
|
+
end
|
118
|
+
|
119
|
+
group :test do
|
120
|
+
# Adds support for Capybara system testing and selenium driver
|
121
|
+
gem 'capybara', '>= 3.26'
|
122
|
+
gem 'selenium-webdriver'
|
123
|
+
# Easy installation and use of web drivers to run system tests with browsers
|
124
|
+
gem 'webdrivers'
|
125
|
+
end
|
126
|
+
|
127
|
+
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
|
128
|
+
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
|
129
|
+
|
130
|
+
```
|
2
webpackerのバージョンアップ
answer
CHANGED
@@ -3,7 +3,8 @@
|
|
3
3
|
- webpackでコンパイルされていたため、webpackerの設定が読み込めていなかった。
|
4
4
|
|
5
5
|
# 解決のために行ったこと
|
6
|
-
`yarn remove webpack webpack-cli`のコマンドの実施
|
6
|
+
- `yarn remove webpack webpack-cli`のコマンドの実施
|
7
|
+
- webpackerのバージョンアップ(その後、bundle install)
|
7
8
|
|
8
9
|
# 教訓
|
9
10
|
- サイトのコピペを理解せず多量に行うと何を改変したか忘れてしまう。
|
1
教訓の追加
answer
CHANGED
@@ -3,4 +3,8 @@
|
|
3
3
|
- webpackでコンパイルされていたため、webpackerの設定が読み込めていなかった。
|
4
4
|
|
5
5
|
# 解決のために行ったこと
|
6
|
-
`yarn remove webpack webpack-cli`のコマンドの実施
|
6
|
+
`yarn remove webpack webpack-cli`のコマンドの実施
|
7
|
+
|
8
|
+
# 教訓
|
9
|
+
- サイトのコピペを理解せず多量に行うと何を改変したか忘れてしまう。
|
10
|
+
- Gitのログを遡るという基本的なことを忘れていた。
|