0.1.3 • Published 6 years ago

ember-themed-syntax v0.1.3

Weekly downloads
4
License
MIT
Repository
github
Last release
6 years ago

npm version Build Status Ember Observer Score

ember-themed-syntax

An out-of-the-box solution for syntax highlighting with a couple of themes included

Installation

ember install ember-themed-syntax

Languages

List of supported highlight.js languages

Demo and Documentation

http://crodriguez1a.github.io/ember-themed-syntax/

Usage

The following params are accepted

  • lang: *default html* - The coding language inside the block
  • theme: *default light* - Your theme selection
  • transparent: *default false* - When set to true, a background color will not be applied
  • withBuffers: *default true* - Adds a line break to beginning and end of each block
  • code: *default ''* - Use instead of template block parameter to bind code input

Template

  {{#themed-syntax lang="htmlbars" theme="dark"}}
    {{! Some code }}
  {{/themed-syntax}}

The default theme is set to light

	{{#themed-syntax lang="htmlbars"}}
  	  {{! Some code }}
	{{/themed-syntax}}