こんにちは。
現在Railsアプリにおいてerbファイルをslimに書き換えようとチャレンジしているのですが、local3000でアクセスすると下記のようなエラーが出てしまいます。
テンプレートが見つからないということなのですが、ファイルの拡張子をhome.html.erbからhome.html.slimに変えています(同名のerbファイルは同じフォルダにはありません)し、slim-railsのgemもインストール済みです。
他のファイルも全てslimにしないといけないとかそのような条件があるのでしょうか?
他のerbで書かれたページにはアクセスできるので、そのようなことはないと思うのですが。
railsのバージョンは5.1.5でrubyのバージョンは2.5.1です。
よろしくお願いします。
【エラー内容】
#home is missing a template for this request format and variant. request.formats: ["text/html"] request.variant: [] NOTE! For XHR/Ajax or API requests, this action would normally respond with 204 No Content: an empty white screen. Since you're loading it in a web browser, we assume that you expected to actually render a template, not nothing, so we're showing an error to be extra-clear. If you expect 204 No Content, carry on. That's what you'll get from an XHR or API request. Give it a shot.

回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。