Skip to content
This repository has been archived by the owner on May 25, 2018. It is now read-only.

Hamlbars causes an illegal nesting error #61

Open
LandonSchropp opened this issue Jul 11, 2014 · 4 comments
Open

Hamlbars causes an illegal nesting error #61

LandonSchropp opened this issue Jul 11, 2014 · 4 comments

Comments

@LandonSchropp
Copy link

Here's what I've done:

  1. I added Hamlbars to the Gemfile: gem 'hamlbars', '~> 2.1'. We're already using handlebars_assets.
  2. I created a new file file at app/assets/javascripts/test.js.hbs.hamlbars.
  3. I added this to that file: %p Testing.

When I open the project in my browser, I get the following error:

throw Error("Haml::SyntaxError: Illegal nesting: nesting within plain text is illegal.\n  (in /Users/landonschropp/Development/quve/app/assets/javascripts/test.js.hbs.hamlbars)")

I've also tried removing everything from the test file and I still get the same error.

In case there's a conflict, these are all of the asset gems we're using:

gem 'sass-rails', '~> 4.0.0'
gem 'uglifier', '>= 1.3.0'
gem 'coffee-rails', '~> 4.0.0'
gem 'haml-rails'
gem 'handlebars_assets'
gem 'gon'
gem 'autoprefixer-rails'
gem 'roadie'
gem 'redcarpet'
gem 'hamlbars', '~> 2.1'

gem 'jquery-rails'
gem 'jquery-ui-rails'
gem 'videojs_rails'
gem 'pickadate-rails', "~> 1.2.0"
gem 'datejs-rails'
@KurtPreston
Copy link

+1

@hopsor
Copy link

hopsor commented Jul 25, 2014

@LandonSchropp @KurtPreston

I was having the same problem but renaming the file to just test.hamlbars did the trick.

@LandonSchropp
Copy link
Author

@hopsor If you just do .hamlbars, how do you compile the raw Handlebars output?

@hendrikstier
Copy link

Are there any news on this issue?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants