ActionController::RoutingError(没有路由匹配 [GET]“/serviceworker.js”):

nat*_*teM 2 ruby ruby-on-rails service-worker ruby-on-rails-6

安装好的导轨6.0.3。Ran rails new [app],启动服务器,加载主页,服务器日志显示此路由错误。有任何想法吗?这是我没有碰过的路线文件。

Rails.application.routes.draw do
  # For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html
end
Run Code Online (Sandbox Code Playgroud)

nat*_*teM 5

进入 Chrome 的开发工具 > 应用程序 > 清除存储解决了我的问题。