Template process for jade #23

Merged
merged 3 commits into from Jun 1, 2012

Projects

None yet

3 participants

@outaTiME
Contributor

Hi pal,

I add support to templating process at jade locals (in options.data), great to took data from grunt and passit to jade templates.

take a look ^^

@tkellen
Member
tkellen commented May 31, 2012

Ariel--

Thanks for your submission!

I don't actually use this task, @errcw could you weigh in here?

@outaTiME
Contributor
outaTiME commented Jun 1, 2012

oups, i dont known ... (?!?!)

@errcw errcw commented on an outdated diff Jun 1, 2012
tasks/jade.js
@@ -22,6 +22,16 @@ module.exports = function(grunt) {
dest = this.file.dest,
data = options.data;
+ // add template process for grunt templates
+ if (typeof data !== "undefined") {
+ Object.keys(data).forEach(function (key) {
+ var value = data[key];
+ if (typeof value === 'string') {
@errcw
errcw Jun 1, 2012 Contributor

use " quotes (consistency)

@errcw
Contributor
errcw commented Jun 1, 2012

Looks fine to me.

@outaTiME
Contributor
outaTiME commented Jun 1, 2012

Yay, im update quotes, sorry ...

@tkellen
Member
tkellen commented Jun 1, 2012

Okay, if you make a passing test for this and update the documentation I'll gladly merge.

@outaTiME
Contributor
outaTiME commented Jun 1, 2012

cool, np !

Ariel Falduto
afalduto@gmail.com

On Jun 1, 2012, at 1:10 PM, Tyler Kellen wrote:

Okay, if you make a passing test for this and update the documentation I'll gladly merge.


Reply to this email directly or view it on GitHub:
#23 (comment)

@outaTiME
Contributor
outaTiME commented Jun 1, 2012

Job done ^^

@tkellen
Member
tkellen commented Jun 1, 2012

Thanks Ariel!

@tkellen tkellen merged commit af5ce9d into gruntjs:master Jun 1, 2012
@outaTiME
Contributor
outaTiME commented Jun 1, 2012

Cool, if you want to checkout ... i have one more grunt plugin that can be included at contrib ...

https://github.com/outaTiME/grunt-replace

Ariel Falduto
afalduto@gmail.com

On Jun 1, 2012, at 3:58 PM, Tyler Kellen wrote:

Thanks Ariel!


Reply to this email directly or view it on GitHub:
#23 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment