質問編集履歴
4
環境を編集
title
CHANGED
File without changes
|
body
CHANGED
@@ -33,7 +33,7 @@
|
|
33
33
|
|
34
34
|
以下環境設定の詳細です。
|
35
35
|
|
36
|
-
**
|
36
|
+
**config_enviroments_development**
|
37
37
|
|
38
38
|
```
|
39
39
|
Rails.application.configure do
|
3
環境の詳細を追加
title
CHANGED
File without changes
|
body
CHANGED
@@ -31,7 +31,11 @@
|
|
31
31
|
application.scssは、上記の下に全体に必要なcssが200行程あります。
|
32
32
|
|
33
33
|
|
34
|
+
以下環境設定の詳細です。
|
35
|
+
|
34
|
-
|
36
|
+
**config_enviroments**
|
37
|
+
|
38
|
+
```
|
35
39
|
Rails.application.configure do
|
36
40
|
# Settings specified here will take precedence over those in config/application.rb.
|
37
41
|
|
@@ -108,7 +112,9 @@
|
|
108
112
|
```
|
109
113
|
|
110
114
|
|
111
|
-
|
115
|
+
**config_initializers_asetts**
|
116
|
+
|
117
|
+
```
|
112
118
|
# Be sure to restart your server when you modify this file.
|
113
119
|
|
114
120
|
# Version of your assets, change this if you want to expire all your assets.
|
2
環境を追加しました
title
CHANGED
File without changes
|
body
CHANGED
@@ -30,5 +30,102 @@
|
|
30
30
|
|
31
31
|
application.scssは、上記の下に全体に必要なcssが200行程あります。
|
32
32
|
|
33
|
+
|
34
|
+
```config_enviroments
|
35
|
+
Rails.application.configure do
|
36
|
+
# Settings specified here will take precedence over those in config/application.rb.
|
37
|
+
|
38
|
+
# In the development environment your application's code is reloaded on
|
39
|
+
# every request. This slows down response time but is perfect for development
|
40
|
+
# since you don't have to restart the web server when you make code changes.
|
41
|
+
config.cache_classes = false
|
42
|
+
|
43
|
+
# Do not eager load code on boot.
|
44
|
+
config.eager_load = false
|
45
|
+
|
46
|
+
# Show full error reports.
|
47
|
+
config.consider_all_requests_local = true
|
48
|
+
|
49
|
+
# Enable/disable caching. By default caching is disabled.
|
50
|
+
# Run rails dev:cache to toggle caching.
|
51
|
+
if Rails.root.join('tmp', 'caching-dev.txt').exist?
|
52
|
+
config.action_controller.perform_caching = true
|
53
|
+
|
54
|
+
config.cache_store = :memory_store
|
55
|
+
config.public_file_server.headers = {
|
56
|
+
'Cache-Control' => "public, max-age=#{2.days.to_i}"
|
57
|
+
}
|
58
|
+
else
|
59
|
+
config.action_controller.perform_caching = false
|
60
|
+
|
61
|
+
config.cache_store = :null_store
|
62
|
+
end
|
63
|
+
|
64
|
+
# Store uploaded files on the local file system (see config/storage.yml for options)
|
65
|
+
config.active_storage.service = :local
|
66
|
+
|
67
|
+
|
68
|
+
#★以下よりgmail想定で変更2019.11.08---------------
|
69
|
+
|
70
|
+
# Don't care if the mailer can't send.
|
71
|
+
config.action_mailer.raise_delivery_errors = true #★falseから変更
|
72
|
+
config.action_mailer.default_url_options = { host: 'localhost', port: 3000 }
|
73
|
+
config.action_mailer.delivery_method = :smtp
|
74
|
+
config.action_mailer.smtp_settings = {
|
75
|
+
####################
|
76
|
+
}
|
77
|
+
#------------------------------------------------
|
78
|
+
config.action_mailer.perform_caching = false
|
79
|
+
|
80
|
+
# Print deprecation notices to the Rails logger.
|
81
|
+
config.active_support.deprecation = :log
|
82
|
+
|
83
|
+
# Raise an error on page load if there are pending migrations.
|
84
|
+
config.active_record.migration_error = :page_load
|
85
|
+
|
86
|
+
# Highlight code that triggered database queries in logs.
|
87
|
+
config.active_record.verbose_query_logs = true
|
88
|
+
|
89
|
+
# Debug mode disables concatenation and preprocessing of assets.
|
90
|
+
# This option may cause significant delays in view rendering with a large
|
91
|
+
# number of complex assets.
|
92
|
+
config.assets.debug = true
|
93
|
+
|
94
|
+
#ユーザーのブラウザでキャッシュが残っていても更新後の画像が反映される
|
95
|
+
config.assets.digest = false
|
96
|
+
|
97
|
+
# Suppress logger output for asset requests.
|
98
|
+
config.assets.quiet = true
|
99
|
+
|
100
|
+
# Raises error for missing translations
|
101
|
+
# config.action_view.raise_on_missing_translations = true
|
102
|
+
|
103
|
+
# Use an evented file watcher to asynchronously detect changes in source code,
|
104
|
+
# routes, locales, etc. This feature depends on the listen gem.
|
105
|
+
# config.file_watcher = ActiveSupport::EventedFileUpdateChecker
|
106
|
+
end
|
107
|
+
|
108
|
+
```
|
109
|
+
|
110
|
+
|
111
|
+
```config_initializers_asetts
|
112
|
+
# Be sure to restart your server when you modify this file.
|
113
|
+
|
114
|
+
# Version of your assets, change this if you want to expire all your assets.
|
115
|
+
Rails.application.config.assets.version = '1.0'
|
116
|
+
|
117
|
+
# Add additional assets to the asset load path.
|
118
|
+
# Rails.application.config.assets.paths << Emoji.images_path
|
119
|
+
# Add Yarn node_modules folder to the asset load path.
|
120
|
+
Rails.application.config.assets.paths << Rails.root.join('node_modules')
|
121
|
+
|
122
|
+
# Precompile additional assets.
|
123
|
+
# application.js, application.css, and all non-JS/CSS in the app/assets
|
124
|
+
# folder are already added.
|
125
|
+
# Rails.application.config.assets.precompile += %w( admin.js admin.css )
|
126
|
+
|
127
|
+
Rails.application.config.assets.precompile += %w( turbolinks )
|
128
|
+
```
|
129
|
+
|
33
130
|
書き方や環境の設定(アセットパイプライン?)について何かお知恵がありましたら、教えて頂けると嬉しいです。
|
34
131
|
全然、変更できず大変こまっております・・・。
|
1
application.scss追加
title
CHANGED
File without changes
|
body
CHANGED
@@ -3,7 +3,9 @@
|
|
3
3
|
application.scssファイルにほんの少しの変更を加えると、途端に全く意味不明なデザイン崩れが起こります・・・。
|
4
4
|
|
5
5
|
変更といっても、コメントアウトの文字を1文字消す
|
6
|
-
```
|
6
|
+
```
|
7
|
+
application.scss
|
8
|
+
|
7
9
|
before //ローカルの写真をアップさせない
|
8
10
|
↓
|
9
11
|
after //ローカルの写真をアップさせな
|
@@ -26,7 +28,7 @@
|
|
26
28
|
@import "reports.scss";
|
27
29
|
```
|
28
30
|
|
29
|
-
上記の下に
|
31
|
+
application.scssは、上記の下に全体に必要なcssが200行程あります。
|
30
32
|
|
31
33
|
書き方や環境の設定(アセットパイプライン?)について何かお知恵がありましたら、教えて頂けると嬉しいです。
|
32
34
|
全然、変更できず大変こまっております・・・。
|