2

I'm trying to use coffeekup as my default template

app.set 'view engine', 'coffee'
app.register '.coffee', coffeekup.adapters.express

except app.register isn't a function it looks like. whats the migration?

Funkodebat
  • 5,229
  • 3
  • 36
  • 54
  • Did you ever figure this out? – nilskp Sep 06 '12 at 15:49
  • I ended up creating my own 'loadDir' function, which loads a dir, runs it through a compiler, and either requires it or writes it to a new directory. In this case, I run it through the coffeecup compiler and stick it into a template object – Funkodebat Oct 30 '12 at 17:52
  • use the npm module `loaddir` it is pretty awesome. – Funkodebat Oct 07 '13 at 19:29

3 Answers3

2

coffeekup was Changed to 'coffeecup'

follow this link : https://github.com/gradus/coffeecup

LostCode
  • 523
  • 2
  • 6
  • 24
2

coffeecup derivative teacup has an up to date example

hurrymaplelad
  • 23,777
  • 9
  • 50
  • 72
0

You want app.engine instead of app.register -- the guide needs to be updated.

Check out the unit tests for examples: https://github.com/visionmedia/express/blob/master/test/app.engine.js

Eve Freeman
  • 30,388
  • 2
  • 79
  • 95