Comments (15)
Hey Brad,
I don't really know why the split_stylesheet_link_tag
helper for some reason isn't loaded/available in your app. It is defined here: https://github.com/zweilove/css_splitter/blob/master/app/helpers/css_splitter/application_helper.rb and loaded here: https://github.com/zweilove/css_splitter/blob/master/lib/css_splitter/engine.rb#L9-L13 I have to dig a little deeper to figure out what could be wrong here.
As a workaround/quickfix I would recommend you simply do the include yourself, manually writing the code that the helper would produce. Something like this:
= stylesheet_link_tag "application", :media => "all"
/[if IE lte IE 9]
= stylesheet_link_tag "application_split2", :media => "all"
Let me know if that works for you in the meantime and I will get back to you once I know more about why the helper could not be loaded.
from css_splitter.
thanks, i already tried that.
i think the current project im working on now is more then that because i
found a counter to count my selectors and its less then 4095 so the
css_splitter shouldn't even be a factor, im thinking the css isn't loading
in ie9 properly due to either the bootstrap sass gem overwriting some of
the predefined styles.
we ended up getting control of a project from our outsourced team and they
totally botched this project up so im trying to run through the entire
pipeline.
i even tried bless just as a second potential option but neither have
worked which is why i think it has something to do with the bootstrap gem
itself, your really supposed to predefine some of your default elements
before the bootstrap gem to prevent the bootstrap from overwriting some of
your styles but that isn't what the previous owners of this project did.
ehhh.... this has been kind of frustrating and ive been dealing with it for
the last 2 days.
but i don't think it has anything to do with your gem.
thanks for your help.
have a good weekend.
brad
On Fri, Mar 15, 2013 at 5:28 PM, Jakob Hilden [email protected]:
Hey Brad,
I don't really know why the split_stylesheet_link_tag helper for some
reason isn't loaded/available in your app. It is defined here:
https://github.com/zweilove/css_splitter/blob/master/app/helpers/css_splitter/application_helper.rband loaded here:
https://github.com/zweilove/css_splitter/blob/master/lib/css_splitter/engine.rb#L9-L13I have to dig a little deeper to figure out what could be wrong here.As a workaround/quickfix I would recommend you simply do the include
yourself, manually writing the code that the helper would produce.
Something like this:= stylesheet_link_tag "application", :media => "all"
/[if IE lte IE 9]
= stylesheet_link_tag "application_split2", :media => "all"Let me know if that works for you in the meantime and I will get back to
you once I know more about why the helper could not be loaded.—
Reply to this email directly or view it on GitHubhttps://github.com//issues/11#issuecomment-14985903
.
Thanks,
Brad Kahl
Software Developer
M 540.314.8352
from css_splitter.
@bkahl Did you put this gem in the assets
group in your Gemfile
? If I do that, I get the same problem.
It works for me to move this gem out of assets
group.
from css_splitter.
@linjunpop That's a very good point. I added a little note to the README. Do you think that will make things more clear? ecde6b0
@bkahl Please let us know if that fixed your problem.
from css_splitter.
@bkahl any feedback? Can this issue be closed?
from css_splitter.
hey @jhilden, sorry for the late response and not closing this out, but yes, this issue is solved, therefore, I'm closing it out. thanks for your help!
from css_splitter.
@bkahl can you confirm that the issue cam from having the gem in the assets group? I've suddenly hit this (after 3 weeks of having it in production, working) on a branch where I've added active-admin. I'm still investigating but It would be nice to know if your problem was different as well and how you fixed it. Thanks.
from css_splitter.
Don't really know what the issue could be here, but from personal experience I would recommend rails_admin
over active_admin
. Maybe that won't give you any issues.
from css_splitter.
I'm running into this same issue, with the gem outside the assets group
from css_splitter.
@muskosan can you provide some more details on used versions (gem, rails, ruby, ...), error messages, etc.?
from css_splitter.
Sure,
Error:
undefined method `split_stylesheet_link_tag' for #<#Class:0x007fe20d023a40:0x007fe2069c42b8>
gem v .0.4.0.
Rails 3.2.19
ruby 2.1.3p242 (2014-09-19 revision 47630) [x86_64-darwin13.0]
Using the helper isn't a necessity, though it would be nice.
from css_splitter.
hmm. seems like this part is not working for you: https://github.com/zweilove/css_splitter/blob/master/lib/css_splitter/engine.rb#L9-L13
(maybe it's not working for rails3)
you can always include the helper manually in your ApplicationController
from css_splitter.
I found that when using Pow as my local Rack server, I had to restart it to get this error to go away.
from css_splitter.
I had the same issue running on ruby 2.2.2p95 and Rails 4.2.3 application.
I had to include helper CssSplitter::ApplicationHelper
in the ApplicationController
and that worked for me.
from css_splitter.
Thanks @jefigo, thank did the trick! For me this is caused by using the ember-cli-rails gem. When I remove the gem, it works fine.
from css_splitter.
Related Issues (20)
- Gem just seems to duplicate original CSS HOT 23
- Update gems (Middleman compatibility) HOT 15
- split2 file is always empty HOT 9
- Rails 4 work? HOT 29
- Issue with Key frames HOT 13
- IE9 not displaying full stylesheet HOT 2
- Rubygems.org with 0.4.0 HOT 4
- fail to precompile HOT 8
- Request to release 0.4.1 HOT 2
- undefined method `bytesize' for nil:NilClass HOT 8
- Sass::SyntaxError: @charset may only be used at the root of a document. HOT 4
- Sass::SyntaxError: Invalid CSS after " }": expected selector or at-rule, was "}" HOT 15
- Single rule with > 4095 selectors not split HOT 3
- Different splitter output in development and prod HOT 9
- NoMethodError: undefined method `register_bundle_processor' for nil:NilClass HOT 8
- circular dependency thrown in version 0.4.4 during asset precompile from minimal Rails app HOT 5
- Rails 3 sprockets engine issue HOT 3
- Sprockets v3.7.0 deprecations HOT 7
- Question about test case HOT 5
- sass问题
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from css_splitter.