css - What is the right way to use relative paths in less stylesheets in Rails? -
i'm upgrading rails3.1 application use asset pipeline. i'm using less-rails
gem compile assets (before using asset pipeline, more
plugin used).
a few of existing less stylesheets reference other stylesheets in @import directive relative paths. there problem arises, since lookup via relative paths doesn't work.
example:
first stylesheet: app/assets/stylesheets/shared/env.less second stylesheet: app/assets/stylesheets/shared/colours.less
the first stylesheet referencing other one:
@import "colours.less";
this fails. start working when modify reference using asset helpers:
@import asset_path("colours.less")
is way make relative paths work? mean changing lot of stylesheets references... or problem in setup of less-rails
, should work?
edit:
even using asset helpers doesn't work me. way working using paths starting in assets root, this:
@import "shared/colours.less";
after more research found ok use relative paths hence should work. found open issue less-rails
gem:
https://github.com/metaskills/less-rails/pull/64
hopefully can solve in short time.
Comments
Post a Comment