Giter VIP home page Giter VIP logo

html5-rails's People

Contributors

errm avatar felixclack avatar jdutil avatar kucaahbe avatar luxflux avatar sporkd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

html5-rails's Issues

not working

used these gem on my application and It was working on IE like on chrome and firefox and opera too ,,,it was great ,,till I updated my ruby version to 1.9.3 and I found always encoding error ,,,and the gem not working ,,,I returned back to ruby 1.8.7 and i followed all steps for these gem but still not working on ...do you know what is the problem

cant generate html5:install

hi.. im new with rails
and when i generate html5:install i got this

Users/ME/.rvm/gems/ruby-1.9.2-p320/gems/compass-h5bp-0.1.1/lib/compass/h5bp.rb:5:in `module:H5bp': uninitialized constant Compass::Frameworks (NameError)

i dont have any experience with rails but i just want to write with haml compass and sass

how to fix this?

undefined method `html_tag' for #

I read bug #19 it does seem the same but the fix isn't working

In rails 4.0 i get exactly the same problem. When i change the an application controller it works, but when i don't change anything it breaks.

In rails 4.0 the removed the assets groups, maby that breaks it again? I created a new rails 4.0 project and it works like a charm... So it seems there is something woring with my project or a dependency...

i tried 20 way's of list the gems but non of them seem to be working or fix the problem.

Any suggestions or test i could do?

my list looks like this:

gem 'sass-rails', '> 4.0'
gem 'coffee-rails', '
> 4.0'
gem 'compass-rails', '> 1.1.3'
gem 'compass-h5bp'
gem 'html5-rails', "
> 0.1.0"
gem 'haml', "~> 4.0.5"
gem 'haml-rails'

gem 'jquery-rails', "~> 3.0.0"
gem 'jquery-ui-rails'
gem 'jquery-cookie-rails'

Adding the polyfills.js to the assets-pipeline

Hey there,

First, I would like to thank you for this great gem (and the previous version too)... It made upgrading my app to rails 3.1 so easy :)

While deploying my updated rails 3.1 app, I had a problem with the assets-pipeline.
I know this gem might not be production-ready yet (is it?), but It worked great with the development rails-env.

After digging deep, I found out that the polyfills.js was not being compiled on the production-env (which is not needed on the dev-env of course).

I had to add the following to config/environments/production.rb file to make it work:

  config.assets.precompile += %w( polyfills.js )

I hope this gets fixed or at least added to the readme to spare other folks the trouble.

html_tag(): undefined method `options' for nil:NilClass when having application.html.slim instead of haml

My SLIM file:

doctype html
- html_tag class: "no-js" do # Adds IE-specific CSS classes
  = render "head"

  body class=controller.controller_name
    = render "chromeframe"
    = render "header"

    #main role="main"
      = render "flashes"
      = yield

    = render "footer"

    -# Javascript at the bottom for fast page loading
    = render "javascripts"

Output when loading page:

undefined method `options' for nil:NilClass

#<Class:0x007fd985f61bc8>#_app_views_layouts_application_html_slim__2652867622890682822_70286116180140
app/views/layouts/application.html.slim, line 2

Any help on that? Before when I used HAML this worked perfectly.

h5bp templates missing in rails 4.0

I just installed on a Rails 4.0 application and I had to comment everything out that dealt with h5bp as that all gave me a file unreadable error and I have no partials with those names at all.

Undefined method html_tag

Hi everyone,

I'm having the exact same issue... Strange thing is that the error disappear if I modify one of my controllers and save it. It's like html5-rails helpers weren't loaded at the first time... I've temporary fixed it by adding the "html_tag" helper method in my application_helper.rb file...

Does anyone have any clue on what may be going on?

Here is the full error trace:

NoMethodError in Pages#home

Showing /home/user/RailsWorkspace/MyWebsite/app/views/layouts/application.html.erb where line #3 raised:

undefined method `html_tag' for #<#Class:0xb6da8610:0xb6ea6d00>

Extracted source (around line #3):

1: <!DOCTYPE html>
2:
3: <%= html_tag :class => "no-js", :lang => "fr" %>
4: <%= render "head" %>
5:
6:

Rails.root: /home/user/RailsWorkspace/MyWebsite
Application Trace | Framework Trace | Full Trace

app/views/layouts/application.html.erb:3:in _app_views_layouts_application_html_erb__672111483_90188110'
actionpack (3.2.8) lib/action_view/template.rb:145:inblock in render'
activesupport (3.2.8) lib/activesupport/notifications.rb:125:in instrument'
actionpack (3.2.8) lib/action_view/template.rb:143:inrender'
actionpack (3.2.8) lib/action_view/renderer/template_renderer.rb:59:in render_with_layout'
actionpack (3.2.8) lib/action_view/renderer/template_renderer.rb:45:inrender_template'
actionpack (3.2.8) lib/action_view/renderer/template_renderer.rb:18:in render'
actionpack (3.2.8) lib/action_view/renderer/renderer.rb:36:inrender_template'
actionpack (3.2.8) lib/action_view/renderer/renderer.rb:17:in render'
actionpack (3.2.8) lib/abstract_controller/rendering.rb:110:in_render_template'
actionpack (3.2.8) lib/action_controller/metal/streaming.rb:225:in _render_template'
actionpack (3.2.8) lib/abstract_controller/rendering.rb:103:inrender_to_body'
actionpack (3.2.8) lib/action_controller/metal/renderers.rb:28:in render_to_body'
actionpack (3.2.8) lib/action_controller/metal/compatibility.rb:50:inrender_to_body'
actionpack (3.2.8) lib/abstract_controller/rendering.rb:88:in render'
actionpack (3.2.8) lib/action_controller/metal/rendering.rb:16:inrender'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:40:in block (2 levels) in render'
activesupport (3.2.8) lib/active_support/core_ext/benchmark.rb:5:inblock in ms'
/home/user/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/benchmark.rb:295:in realtime'
activesupport (3.2.8) lib/active_support/core_ext/benchmark.rb:5:inms'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:40:in block in render'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:83:incleanup_view_runtime'
activerecord (3.2.8) lib/active_record/railties/controller_runtime.rb:24:in cleanup_view_runtime'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:39:inrender'
actionpack (3.2.8) lib/action_controller/metal/implicit_render.rb:10:in default_render'
actionpack (3.2.8) lib/action_controller/metal/implicit_render.rb:5:insend_action'
actionpack (3.2.8) lib/abstract_controller/base.rb:167:in process_action'
actionpack (3.2.8) lib/action_controller/metal/rendering.rb:10:inprocess_action'
actionpack (3.2.8) lib/abstract_controller/callbacks.rb:18:in block in process_action'
activesupport (3.2.8) lib/active_support/callbacks.rb:414:in_run640091682process_action821382574callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in __run_callback'
activesupport (3.2.8) lib/active_support/callbacks.rb:385:in_run_process_action_callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in run_callbacks'
actionpack (3.2.8) lib/abstract_controller/callbacks.rb:17:inprocess_action'
actionpack (3.2.8) lib/action_controller/metal/rescue.rb:29:in process_action'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:30:inblock in process_action'
activesupport (3.2.8) lib/active_support/notifications.rb:123:in block in instrument'
activesupport (3.2.8) lib/active_support/notifications/instrumenter.rb:20:ininstrument'
activesupport (3.2.8) lib/active_support/notifications.rb:123:in instrument'
actionpack (3.2.8) lib/action_controller/metal/instrumentation.rb:29:inprocess_action'
actionpack (3.2.8) lib/action_controller/metal/params_wrapper.rb:207:in process_action'
activerecord (3.2.8) lib/active_record/railties/controller_runtime.rb:18:inprocess_action'
actionpack (3.2.8) lib/abstract_controller/base.rb:121:in process'
actionpack (3.2.8) lib/abstract_controller/rendering.rb:45:inprocess'
actionpack (3.2.8) lib/action_controller/metal.rb:203:in dispatch'
actionpack (3.2.8) lib/action_controller/metal/rack_delegation.rb:14:indispatch'
actionpack (3.2.8) lib/action_controller/metal.rb:246:in block in action'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:73:incall'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:73:in dispatch'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:36:incall'
journey (1.0.4) lib/journey/router.rb:68:in block in call'
journey (1.0.4) lib/journey/router.rb:56:ineach'
journey (1.0.4) lib/journey/router.rb:56:in call'
actionpack (3.2.8) lib/action_dispatch/routing/route_set.rb:600:incall'
warden (1.2.1) lib/warden/manager.rb:35:in block in call'
warden (1.2.1) lib/warden/manager.rb:34:incatch'
warden (1.2.1) lib/warden/manager.rb:34:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/best_standards_support.rb:17:incall'
rack (1.4.1) lib/rack/etag.rb:23:in call'
rack (1.4.1) lib/rack/conditionalget.rb:25:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/head.rb:14:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/params_parser.rb:21:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/flash.rb:242:in call'
rack (1.4.1) lib/rack/session/abstract/id.rb:205:incontext'
rack (1.4.1) lib/rack/session/abstract/id.rb:200:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/cookies.rb:339:incall'
activerecord (3.2.8) lib/active_record/query_cache.rb:64:in call'
activerecord (3.2.8) lib/active_record/connection_adapters/abstract/connection_pool.rb:473:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:28:in block in call'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in_run573388879call299690400_callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:405:in __run_callback'
activesupport (3.2.8) lib/active_support/callbacks.rb:385:in_run_call_callbacks'
activesupport (3.2.8) lib/active_support/callbacks.rb:81:in run_callbacks'
actionpack (3.2.8) lib/action_dispatch/middleware/callbacks.rb:27:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/reloader.rb:65:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/remote_ip.rb:31:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/debug_exceptions.rb:16:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/show_exceptions.rb:56:incall'
railties (3.2.8) lib/rails/rack/logger.rb:26:in call_app'
railties (3.2.8) lib/rails/rack/logger.rb:16:incall'
actionpack (3.2.8) lib/action_dispatch/middleware/request_id.rb:22:in call'
rack (1.4.1) lib/rack/methodoverride.rb:21:incall'
rack (1.4.1) lib/rack/runtime.rb:17:in call'
activesupport (3.2.8) lib/active_support/cache/strategy/local_cache.rb:72:incall'
rack (1.4.1) lib/rack/lock.rb:15:in call'
actionpack (3.2.8) lib/action_dispatch/middleware/static.rb:62:incall'
railties (3.2.8) lib/rails/engine.rb:479:in call'
railties (3.2.8) lib/rails/application.rb:223:incall'
rack (1.4.1) lib/rack/content_length.rb:14:in call'
railties (3.2.8) lib/rails/rack/log_tailer.rb:17:incall'
rack (1.4.1) lib/rack/handler/webrick.rb:59:in service'
/home/user/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:138:inservice'
/home/user/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/httpserver.rb:94:in run'
/home/user/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/webrick/server.rb:191:inblock in start_thread'

Remove Gem dependency on compass-html5

Please remove the s.add_dependency "compass-html5", "~> 0.0.1" line for your gemspec. People may want to include it separately within the :assets group.

Thanks, D

Do I have to run `compass init --using blueprint`?

Hey there

Thanks a lot for this very useful gem. For our project, we want to use HTML5-Rails in combination with SASS/Compass and Blueprint. I'm a bit unsure what to do now.

On the SASS/Compass page is mentioned that I should simply run compass init --using blueprint, but I don't know whether this generator is also intended to run on a HTML5-Rails "gemmed" copy of Rails?

Thanks a lot for help,
Josh

undefined method `html_tag'

I'm getting the above error when trying to view my root page on a clean project install, after following the html5-rails installation instructions here. the line we seem to have the problem with is line 3 of views/layouts/application.html.erb:

<%= html_tag :class => "no-js", :lang => "en" %>

Rails Version - 3.2.6
Ruby version -ruby 1.9.2p320

My Gemfile:

source 'https://rubygems.org'

gem 'rails', '3.2.6'

gem 'sqlite3'

group :assets do
gem 'sass-rails', '> 3.2.3'
gem 'coffee-rails', '
> 3.2.1'

# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', :platforms => :ruby

gem 'uglifier', '>= 1.0.3'
gem 'compass-rails'
gem 'compass-h5bp'

end

gem 'jquery-rails'
gem 'html5-rails'

My config/routes.rb:

Blog::Application.routes.draw do
get "welcome/index"
root :to => 'welcome#index'

end

Very new to Ruby and Rails, so any help very much appreciated,

Cheers

AssetNotPrecompiledError Error in production

I've got html5-rails and compass-rails working in devlopment on rails 3.1 but when I run my app in production mode and try to visit my homepage, I get the following:

Sprockets::Helpers::RailsHelper::AssetPaths::AssetNotPrecompiledError in Home#index

polyfills.js isn't precompiled

Steps to reproduce:

1 Create new rails app with home controller, index action and set up a root route

2 Add following to Gemfile

group :assets do
  gem 'compass', "~> 0.12.alpha.0"
  gem 'sass-rails', "~> 3.1.0"
  gem 'coffee-rails', "~> 3.1.0"
  gem 'uglifier'
  gem 'compass-html5', :git => 'https://github.com/sporkd/compass-html5.git'
  gem 'html5-rails', :git => "https://github.com/sporkd/html5-rails.git"
end

3 Run rails g html5:install to create /config/compass.rb file

4 Create sass.rb file containing following code:

Rails.configuration.sass.tap do |config|
  config.load_paths << "#{Gem.loaded_specs['compass'].full_gem_path}/frameworks/compass/stylesheets"
end

5 Run RAILS_ENV=production bundle exec rake assets:precompile

6 Run unicorn -E production and visit root url

7 observe bug

The correctly minified respond-md5.min.js and modernizr-md5.min.js are present in /public/assets. The compiled js code does appear when I visit localhost:8080/assets/modernizr.min.js. The internal server error is thrown when I try to visit my homepage.

I suspect there is an error in my method.

Underscore partials

Seemingly all scss files with underscores can't be found. Renaming variables is fine but gems are a different issue.

generate html5:install throws undefined method `stylesheets_directory'

When running rails generate html5:install

/Users/kieranklaassen/Dropbox/rails/lov/lichtopverlies/config/application.rb:61:in `<class:Application>': undefined method `stylesheets_directory' for nil:NilClass (NoMethodError)
    from /Users/kieranklaassen/Dropbox/rails/lov/lichtopverlies/config/application.rb:10:in `<module:Lov>'
    from /Users/kieranklaassen/Dropbox/rails/lov/lichtopverlies/config/application.rb:9:in `<top (required)>'
    from /Users/kieranklaassen/.rvm/gems/ruby-1.9.2-p180@lov/gems/railties-3.2.0/lib/rails/commands.rb:24:in `require'
    from /Users/kieranklaassen/.rvm/gems/ruby-1.9.2-p180@lov/gems/railties-3.2.0/lib/rails/commands.rb:24:in `<top (required)>'
    from script/rails:6:in `require'
    from script/rails:6:in `<main>'

Where can I fix this?
I am updating from the old html5-boilerplate gem.

Thanks

undefined method `html_tag' while testing with rspec and spork

I'm using html_tag fine in development, staging and test environments, but it raises an error when using rspec with spork to test the controllers and render_views is used.

  ActionView::Template::Error:
       undefined method `html_tag' for #<#<Class:0x007fbdbd769440>:0x007fbdbb895d20>

I have the gem declared outside of any scope, so it is available for the test environment.

It works fine when used outside of spork (rspec --no-drb spec/whatever_spec.rb)

I've tried to manually add the helpers on the prefork and each_run blocks without any effect.

Any suggestions or workarounds?

Generator fails to run

Hello,

Today I wanted to update a rails app to 3.1. 3.
I have already been using your other gem called compass-html5-boilerplate with my old 3.0 app and it worked great.

SO after reading a bit I found this repo and tried to follow the readme instructions to generate the new files, but it fails every time with the following error:
PATH_TO_GEMS/activesupport-3.1.3/lib/active_support/dependencies.rb:240:in 'require': cannot load such file -- html5-boilerplate (LoadError)

I cloned this gem's source, ran the tests and they pass.

Do you have any idea what might be causing this problem?

Compatibility with ruby 1.8*

Hi
Would it be possible to make that gem ruby 1.8 compatible by changing the new hash syntax in generators and views by the classical syntax ?

For example replacing :
{class: "no-js", lang: "en"} by {:class => "no-js", :lang => "en"}

I can pull a request if needed.

What's "app/assets/stylesheets/application/document.css.scss" intended use?

I'm a bit unsure what's the intended use of app/assets/stylesheets/application/document.css.scss. Is it a place for the app's styles? Shouldn't they be place in individual resources_name.css files (e.g. users.css)? Or is it meant for application-wide styles (instead of messing up application.css)?

Thanks a lot for informations.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.