链轮::FileNotFound无法';找不到文件';jquery';

链轮::FileNotFound无法';找不到文件';jquery';,jquery,ruby-on-rails,Jquery,Ruby On Rails,我是新手,我被困在这里 这是my application.HTML.erb错误在JavaScript包含标记中(第6行) 当我删除该行时,不会出现错误 我试着做了以下的事情,但没有成功 我重新启动了几次服务器,但最后一件事没有帮助,当我打开旧项目时,它可以工作,但任何新项目都会出现相同的错误 <!DOCTYPE html> <html> <head> <title>Appmind</title> <%= styleshee

我是新手,我被困在这里

这是my application.HTML.erb错误在JavaScript包含标记中(第6行) 当我删除该行时,不会出现错误 我试着做了以下的事情,但没有成功 我重新启动了几次服务器,但最后一件事没有帮助,当我打开旧项目时,它可以工作,但任何新项目都会出现相同的错误

<!DOCTYPE html>
<html>
<head>
  <title>Appmind</title>
  <%= stylesheet_link_tag    "application", media: "all", "data-turbolinks-track" => true %>
  <%= javascript_include_tag "application", "data-turbolinks-track" => true %>
  <%= csrf_meta_tags %>
</head>
<body>

<%= yield %>

</body>
</html>
文件内容

// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative path.
//
// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
// compiled file.
//
// Read Sprockets README (https://github.com/sstephenson/sprockets#sprockets-directives) for details
// about supported directives.
//
//= require jquery
//= require jquery_ujs
//= require turbolinks
//= require_tree .
source 'https://rubygems.org'

# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '4.0.2'

# Use sqlite3 as the database for Active Record
gem 'sqlite3'

# Use SCSS for stylesheets
gem 'sass-rails', '~> 4.0.0'

# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'

# Use CoffeeScript for .js.coffee assets and views
gem 'coffee-rails', '~> 4.0.0'

# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby

# Use jquery as the JavaScript library
gem 'jquery-rails'

# Turbolinks makes following links in your web application faster. Read more: https://github.com/rails/turbolinks
gem 'turbolinks'

# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 1.2'

group :doc do
  # bundle exec rake doc:rails generates the API under doc/api.
  gem 'sdoc', require: false
end

# Use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.1.2'

# Use unicorn as the app server
# gem 'unicorn'

# Use Capistrano for deployment
# gem 'capistrano', group: :development

# Use debugger
# gem 'debugger', group: [:development, :test]
跟踪

Rails.root: C:/aptanastudio3/appmind
Application Trace | Framework Trace | Full Trace

app/views/layouts/application.html.erb:6:in `_app_views_layouts_application_html_erb___663637225_30053304'

任何帮助都将不胜感激,谢谢

我发现当我的gem“jqueryrails”被包装在一个组中时:assets do block,那么它就不起作用了。但是我把它从积木上移除了,现在它使用了最现代的铁轨。这与您的情况不同,但我认为转换它可能会有效。

我花了一些时间,但我解决了它,我将我的jquery rails gem设置为3.0.4版,删除了application.js中的require turbolinks,然后不得不删除post.js.coffee中的预压缩程序(coffee)。我知道这个解决方案一点也不专业,但我无法找到其他解决方案,这不是一个解决方案。您是否尝试过不在gems中声明版本号?我花了一段时间才意识到,当从4.0.0升级到4.0.2(rails)时,gemfile中的许多隐式版本都坏了。是的,jquery rails gem并不是用一个版本声明的,我尝试了无数次删除gemfile.lock并运行bundle安装并重新启动服务器,检查了我在jquery链轮中的路径,一切正常,但rails仍然找不到它。您尝试过“捆绑更新”吗?