Sprockets::CircularDependencyError in Store#index

此生再无相见时 提交于 2019-11-28 19:28:51

You should remove app/assets/stylesheets/application.css.

Rimian

I had a similar problem:
Asset pipeline not precompiling sass

The circular dependency happens when the manifest file requires the tree files. Sass does this anyway so it's not necessary.

Remove:

 *= require_tree .

I was having this same problem after installing SCSS. I fixed the problem by removing the defult comments that rails places in the header. So this:

/*
 * This is a manifest file that'll be compiled into application.css, which will include all the files
 * listed below.
 *
 * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
 * or vendor/assets/stylesheets of plugins, if any, can be referenced here using a relative path.
 *
 * You're free to add application-wide styles to this file and they'll appear at the top of the
 * compiled file, but it's generally better to create a new file per style scope.
 *
 *= require_self
 *= require_tree .
*/

#wrapper {
    width: 980px;
    margin: 0 auto;
}

Became this:

#wrapper {
    width: 980px;
    margin: 0 auto;
}

Just name the application.css as "application.scss". This will solve your problem.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!