JesseHerrick / jekyll-angular

A Jekyll plugin to make AngularJS play nice.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Jekyll-Angular

A Jekyll plugin to make AngularJS play nice.

Why?

Unfortunately, Jekyll and Angular don't usually work well together...

<div ng-controller="foo">
  <p>{{ bar }}</p>
</div>

Gets turned into:

<div ng-controller="foo">
  <p></p>
</div>

Why? Because Jekyll interperets {{ brackets }} as Liquid. How do we fix this? This plugin.

Getting Started

Install the gem.

# Gemfile

gem 'jekyll-angular'
$ bundle install

Add the plugin to your config.

# _config.yml
plugins:
  - jekyll-angular

Use the plugin for cool Angular stuff.

<div ng-controller="foo">
  <p>{{ 'bar' | angular }}</p>
</div>

Gets processed into...

<div ng-controller="foo">
  <p>{{ bar }}</p>
</div>

About

A Jekyll plugin to make AngularJS play nice.

License:MIT License


Languages

Language:Ruby 87.2%Language:HTML 12.8%