docpad-plugin-coffeescript
Advanced tools
Comparing version 2.2.1 to 2.2.2
@@ -1,2 +0,2 @@ | ||
// Generated by CoffeeScript 1.6.2 | ||
// Generated by CoffeeScript 1.6.3 | ||
var __hasProp = {}.hasOwnProperty, | ||
@@ -7,3 +7,2 @@ __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }; | ||
var CoffeescriptPlugin, _ref; | ||
return CoffeescriptPlugin = (function(_super) { | ||
@@ -24,6 +23,6 @@ __extends(CoffeescriptPlugin, _super); | ||
CoffeescriptPlugin.prototype.render = function(opts) { | ||
var coffee, compileOptions, file, fileFullPath, inExtension, key, outExtension, value, _ref1, _ref2; | ||
var coffee, compileOptions, file, fileFullPath, inExtension, key, literate, outExtension, value, _ref1; | ||
inExtension = opts.inExtension, outExtension = opts.outExtension, file = opts.file; | ||
if ((inExtension === 'coffee' || inExtension === 'litcoffee') && (outExtension === 'js' || outExtension === null)) { | ||
literate = false; | ||
if (((inExtension === 'coffee' || inExtension === 'litcoffee') && (outExtension === 'js' || outExtension === null)) || ((inExtension === 'md' || inExtension === 'markdown') && outExtension === 'js' && (literate = true))) { | ||
coffee = require('coffee-script'); | ||
@@ -33,3 +32,3 @@ fileFullPath = file.get('fullPath'); | ||
filename: fileFullPath, | ||
literate: coffee.helpers.isLiterate(fileFullPath) | ||
literate: literate || coffee.helpers.isLiterate(fileFullPath) | ||
}; | ||
@@ -40,3 +39,3 @@ _ref1 = this.getConfig().compileOptions; | ||
value = _ref1[key]; | ||
if ((_ref2 = compileOptions[key]) == null) { | ||
if (compileOptions[key] == null) { | ||
compileOptions[key] = value; | ||
@@ -43,0 +42,0 @@ } |
{ | ||
"name": "docpad-plugin-coffeescript", | ||
"version": "2.2.1", | ||
"version": "2.2.2", | ||
"description": "Adds support for CoffeeScript to JavaScript compilation to DocPad", | ||
@@ -5,0 +5,0 @@ "homepage": "http://docpad.org/plugin/coffeescript", |
@@ -1,5 +0,11 @@ | ||
# CoffeeScript Plugin for DocPad | ||
# CoffeeScript Plugin for [DocPad](http://docpad.org) | ||
[![Build Status](https://secure.travis-ci.org/docpad/docpad-plugin-coffeescript.png?branch=master)](http://travis-ci.org/docpad/docpad-plugin-coffeescript "Check this project's build status on TravisCI") | ||
[![NPM version](https://badge.fury.io/js/docpad-plugin-coffeescript.png)](https://npmjs.org/package/docpad-plugin-coffeescript "View this project on NPM") | ||
[![Flattr donate button](https://raw.github.com/balupton/flattr-buttons/master/badge-89x18.gif)](http://flattr.com/thing/344188/balupton-on-Flattr "Donate monthly to this project using Flattr") | ||
[![PayPayl donate button](https://www.paypalobjects.com/en_AU/i/btn/btn_donate_SM.gif)](https://www.paypal.com/au/cgi-bin/webscr?cmd=_flow&SESSION=IHj3DG3oy_N9A9ZDIUnPksOi59v0i-EWDTunfmDrmU38Tuohg_xQTx0xcjq&dispatch=5885d80a13c0db1f8e263663d3faee8d14f86393d55a810282b64afed84968ec "Donate once-off to this project using Paypal") | ||
Adds support for [CoffeeScript](http://coffeescript.org/) to JavaScript compilation to [DocPad](https://docpad.org) | ||
Convention: `.js.coffee|litcoffee` | ||
Convention: `.js.coffee|litcoffee|md|markdown` | ||
@@ -19,8 +25,12 @@ | ||
## History | ||
You can discover the history inside the `History.md` file | ||
[You can discover the history inside the `History.md` file](https://github.com/bevry/docpad-plugin-coffeescript/blob/master/History.md#files) | ||
## Contributing | ||
[You can discover the contributing instructions inside the `Contributing.md` file](https://github.com/bevry/docpad-plugin-coffeescript/blob/master/Contributing.md#files) | ||
## License | ||
Licensed under the incredibly [permissive](http://en.wikipedia.org/wiki/Permissive_free_software_licence) [MIT License](http://creativecommons.org/licenses/MIT/) | ||
<br/>Copyright © 2012 [Bevry Pty Ltd](http://bevry.me) | ||
<br/>Copyright © 2012+ [Bevry Pty Ltd](http://bevry.me) | ||
<br/>Copyright © 2011 [Benjamin Lupton](http://balupton.com) |
6655
6
40
35