Breakpoint in Rails app

泪湿孤枕 提交于 2019-12-11 07:23:56

问题


I've been told by Mason Wendell that I can use Breakpoint in my application without Compass.

I have gem 'breakpoint', '2.4.1' in my Gemfile and @import "breakpoint" in my application.css.sass but it fails to locate Breakpoint.

Mason stated "Just get your import paths to find the _breakpoint.scss partial and you should be all set.".

I'm a bit confused about how to actually do this.

Any ideas?


回答1:


There are two styles of using Sass dependencies:

  1. Fetch with RubyGems, apply with a pathless @import 'breakpoint';, made possible by Compass.
  2. Fetch manually with Bower into a subfolder within your project folder, apply with a relative @import 'bower-components/breakpoint/stylesheets/breakpoint'.

There is a way to import Sass dependencies with a pathless @import of a RubyGems-installed dependency and without Compass: put the directory of where RubyGems stores Breakpoint into Sass' load_paths parameter. But you should consider this a workaround rather than a normal workflow.



来源:https://stackoverflow.com/questions/24963153/breakpoint-in-rails-app

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