Skip to content
This repository has been archived by the owner on Jun 5, 2019. It is now read-only.

Commit

Permalink
Creating base structure using node boilerplate (node-plates)
Browse files Browse the repository at this point in the history
  • Loading branch information
donnielrt committed Jul 31, 2012
1 parent 535b403 commit 6503d6e
Show file tree
Hide file tree
Showing 104 changed files with 17,432 additions and 0 deletions.
536 changes: 536 additions & 0 deletions .htaccess

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions 0.2.2
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[email protected] ./node_modules/express-expose
63 changes: 63 additions & 0 deletions api/about.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
exports.get = function(req, res){
return {
title : "node plates - about",
actions : [
{
rel: "Start",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Me",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Next",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "login",
method : "POST",
text : "login"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "logout",
method : "POST",
text : "logout"
}
]
}
};
55 changes: 55 additions & 0 deletions api/account.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
exports.get = function(req, res){
return {
title : "node plates - account",
actions : [
{
rel: "Start",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Me",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "logout",
method : "POST",
text : "logout"
}
]
}
};
66 changes: 66 additions & 0 deletions api/contact.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
exports.get = function(req, res){
return {
title : "node plates - contact",
contact : {
email : "[email protected]"
},
actions : [
{
rel: "Start",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Prev",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Me",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Next",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "login",
method : "POST",
text : "login"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "logout",
method : "POST",
text : "logout"
}
]
}
};
63 changes: 63 additions & 0 deletions api/github.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
exports.get = function(req, res){
return {
title : "node plates - github",
actions : [
{
rel: "Start",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Prev",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "login",
method : "POST",
text : "login"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "about",
method : "POST",
text : "logout"
}
]
}
};
64 changes: 64 additions & 0 deletions api/home.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
exports.get = function(req, res){
return {
title : "node plates - home",
articles : [],
actions : [
{
rel: "Me",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Next",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "login",
method : "POST",
text : "login"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "logout",
method : "POST",
text : "logout"
}
]
}
};
6 changes: 6 additions & 0 deletions api/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
exports.home = require('../api/home');
exports.about = require('../api/about');
exports.contact = require('../api/contact');
exports.github = require('../api/github');
exports.login = require('../api/login');
exports.account = require('../api/account');
56 changes: 56 additions & 0 deletions api/login.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
exports.get = function(req, res){
return {
title : "node plates - login",
login : {
domain: "https://127.0.0.1",
port: ":8443",
path: "login",
method : "POST",
username : { label : "username", name : "user[username]", placeholder: "Please enter a username"},
password : { label : "password", name : "user[password]", placeholder: "Please enter a password"},
button : { name: "login"}
},
actions : [
{
rel: "Start",
domain: "http://127.0.0.1",
port: ":8081",
path: "home",
method : "GET",
text : "home"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "about",
method : "GET",
text : "about"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "contact",
method : "GET",
text : "contact"
},
{
rel: "Section",
domain: "http://127.0.0.1",
port: ":8081",
path: "github",
method : "GET",
text : "github"
},
{
rel: "Section",
domain: "https://127.0.0.1",
port: ":8443",
path: "account",
method : "GET",
text : "account"
}
]
}
};
Loading

0 comments on commit 6503d6e

Please sign in to comment.