UNPKG
creamer
Version:
latest (0.3.4)
0.3.4
0.3.3
0.3.2
0.3.1
0.3.0
0.2.4
0.2.3
0.2.2
0.2.0
0.1.0
0.0.1
A flatiron plugin for dynamic coffeecup templates
twilson63/creamer
creamer
/
examples
/
mvc
/
lib
/
controllers
/
widgets.js
18 lines
(15 loc)
•
332 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
var
Widget
;
Widget
=
require
(__dirname +
'/../models/widget'
);
module
.
exports
= {
'/widgets'
: {
get
:
function
(
) {
var
_this =
this
;
return
Widget
.
all
(
function
(
err, widgets
) {
return
_this.
bind
(
'widgets/index'
, {
widgets
:
'.active'
,
widgets
: widgets }); }); } } };