相关疑难解决方法(0)

指南针:您必须从项目目录中编译单个样式表

前段时间我正在使用指南针从sass为项目生成样式表.

最近我回到了那个项目.我去了我的sass目录并做了"指南针观察 - 调试.:." 这会生成错误"您必须从项目目录中编译单个样式表".

我发现目录中没有config.rb.所以我重新创建了一个.它看起来像这样:

http_path = "/"
css_dir = "/css"
sass_dir = "/css"
images_dir = "/img"
javascripts_dir = "/js"
preferred_syntax = :sass
Run Code Online (Sandbox Code Playgroud)

但是,无论我在配置中输入什么值,我使用罗盘的所有尝试都会导致相同的错误.

如何让罗盘实际处理我的sass?

sass compass-sass

25
推荐指数
1
解决办法
3万
查看次数

Grunt + Compass不会创建CSS文件

使用时出现以下错误grunt compass:

"您必须从项目目录中编译单个样式表."

我用3种不同的方式尝试了它.更多下面.

我的文件夹结构:

test \
     Gruntfile.js
     package.json
     \ node_modules \
     \ _src \ (this is the root folder of my Jekyll site)
        \ config.rb
        \ index.html
        \ static/
            \ _sass \
            \ css \
            \ images \
            \ js \
Run Code Online (Sandbox Code Playgroud)

什么有效:

一切正常,无需使用grunt和使用/_src/config.rb:

#project_path = "_src/"
http_path = "/"
css_dir = "css"
css_path = "static/" + css_dir
sass_dir = "_sass"
sass_path = "static/" + sass_dir
images_dir = "images"
images_path = "static/" …
Run Code Online (Sandbox Code Playgroud)

sass node.js gruntjs compass-sass grunt-contrib-compass

4
推荐指数
1
解决办法
3896
查看次数