【发布时间】:2013-09-04 16:29:31
【问题描述】:
我正在尝试使用安装 zurbs 基础框架
我已经安装了这个 gem: zurb-基础(4.3.1)
从我的项目中,我做到了:
compass install foundation
我明白了:
No such framework: "foundation"
实际如何使用已安装的框架?
【问题讨论】:
标签: sass zurb-foundation compass-sass
我正在尝试使用安装 zurbs 基础框架
我已经安装了这个 gem: zurb-基础(4.3.1)
从我的项目中,我做到了:
compass install foundation
我明白了:
No such framework: "foundation"
实际如何使用已安装的框架?
【问题讨论】:
标签: sass zurb-foundation compass-sass
命令是:
compass install -r zurb-foundation foundation
如果您已经安装了 zurb-foundation,那么使用基础创建新项目的命令是:
compass create <project-name> -r zurb-foundation --using foundation
如果您正在使用 Foundation 和 sass 处理已经存在的项目,则需要根目录中的 config.rb 文件:
require 'zurb-foundation'
# Require any additional compass plugins here.
# Set this to the root of your project when deployed:
http_path = "/"
css_dir = "stylesheets"
sass_dir = "sass"
images_dir = "images"
javascripts_dir = "javascripts"
# You can select your preferred output style here (can be overridden via the command line):
# output_style = :expanded or :nested or :compact or :compressed
# To enable relative paths to assets via compass helper functions. Uncomment:
# relative_assets = true
# To disable debugging comments that display the original location of your selectors. Uncomment:
# line_comments = false
# If you prefer the indented syntax, you might want to regenerate this
# project again passing --syntax sass, or you can uncomment this:
# preferred_syntax = :sass
# and then run:
# sass-convert -R --from scss --to sass sass scss && rm -rf sass && mv scss sass
preferred_syntax = :scss
确保您在顶部有require 'zurb-foundation'。当我有一个已经存在的项目时,这就是为我解决的问题。
【讨论】:
compass:Gem::LoadError on line ["2064"] of c: Unable to activate susy-2.1.2, because sas s-3.2.19 conflicts with sass (~> 3.3.0) Run with --trace to see the full backtrace 安装 susy 时出现此错误
以下命令应该会有所帮助,文档here 中也有说明。
在“创建您的第一个项目”下找到。
$ compass create <project-name> -r zurb-foundation --using foundation
我应该注意这是创建一个新项目
如果它正在添加到现有项目中,也许你错过了:
【讨论】: