diff --git a/example/account/index.js b/example/account/index.js index b4490e8..7bb3ebe 100644 --- a/example/account/index.js +++ b/example/account/index.js @@ -95,7 +95,7 @@ var Account = module.exports = Service.extend({ } }, - 'get::/logout': function logout(req, res) { + 'get::^/logout': function logout(req, res) { req.logout(); res.redirect('/account/login'); }, diff --git a/example/account/package.json b/example/account/package.json index a1fb0ff..03b748d 100644 --- a/example/account/package.json +++ b/example/account/package.json @@ -7,7 +7,7 @@ "cookie-parser": "^1.3.5", "express-session": "^1.11.3", "jade": "^1.11.0", - "micromono": "0.1.28", + "micromono": "0.1.x", "passport": "^0.2.2", "passport-local": "^1.0.0" } diff --git a/example/account/view/hello.jade b/example/account/view/hello.jade index dc07cfa..5c24be1 100644 --- a/example/account/view/hello.jade +++ b/example/account/view/hello.jade @@ -1,4 +1,4 @@ h2 /account/protected h3 Hello #{name}, you can not see this page unless you have logged in successfully. h4 Click to - a(href="/account/logout") Logout + a(href="/logout") Logout diff --git a/example/home/index.js b/example/home/index.js index 1f7724c..32ea76f 100644 --- a/example/home/index.js +++ b/example/home/index.js @@ -19,12 +19,12 @@ var account = new Account(); */ var Home = module.exports = Service.extend({ packagePath: __dirname, - baseUrl: '/', + baseUrl: '/home', use: { // tell micromono to use `layout` middleware at the server side // for request urls in the array. - 'layout': ['/private', '/public$', '/$'] + 'layout': ['/private$', '^/public$', '^/$'] }, route: { @@ -41,14 +41,14 @@ var Home = module.exports = Service.extend({ }); }], - 'get::/public': function public(req, res) { + 'get::^/public': function public(req, res) { res.render('page', { title: 'Home Public Page', name: 'anonymouse' }); }, - 'get::/': function index(req, res) { + 'get::^/': function index(req, res) { res.render('index'); } }, diff --git a/example/home/package.json b/example/home/package.json index 25b04eb..ad73c4d 100644 --- a/example/home/package.json +++ b/example/home/package.json @@ -12,7 +12,7 @@ "dependencies": { "body-parser": "^1.13.2", "jade": "^1.11.0", - "micromono": "0.1.28" + "micromono": "0.1.x" }, "devDependencies": { "jspm": "0.15.7" diff --git a/example/home/view/index.jade b/example/home/view/index.jade index 26a0e32..3e266f7 100644 --- a/example/home/view/index.jade +++ b/example/home/view/index.jade @@ -2,7 +2,7 @@ h3 Index Page of Home Service ul li - a(href="/private") Home Private Page + a(href="/home/private") Home Private Page li a(href="/public") Home Public Page li diff --git a/example/io/package.json b/example/io/package.json index 089b315..7d91337 100644 --- a/example/io/package.json +++ b/example/io/package.json @@ -3,7 +3,7 @@ "version": "0.1.0", "dependencies": { "jade": "^1.11.0", - "micromono": "0.1.28", + "micromono": "0.1.30", "socket.io": "1.3.6" }, "jspm": { @@ -14,9 +14,9 @@ "socket.io-client": "github:socketio/socket.io-client@^1.3.6" }, "devDependencies": { - "babel": "npm:babel-core@^5.8.24", - "babel-runtime": "npm:babel-runtime@^5.8.24", - "core-js": "npm:core-js@^1.1.4" + "babel": "npm:babel-core@5.8.29", + "babel-runtime": "npm:babel-runtime@5.8.29", + "core-js": "npm:core-js@1.2.3" } } } diff --git a/example/server/package.json b/example/server/package.json index 83b552f..b120cf3 100644 --- a/example/server/package.json +++ b/example/server/package.json @@ -13,7 +13,7 @@ "express": "^4.13.1", "jade": "^1.11.0", "jspm": "^0.15.7", - "micromono": "0.1.28" + "micromono": "0.1.x" }, "micromono": { "publicURL": "/public" @@ -26,9 +26,9 @@ "socket.io-client": "github:socketio/socket.io-client@^1.3.6" }, "devDependencies": { - "babel": "npm:babel-core@^5.1.13", - "babel-runtime": "npm:babel-runtime@^5.1.13", - "core-js": "npm:core-js@^0.9.4" + "babel": "npm:babel-core@5.8.29", + "babel-runtime": "npm:babel-runtime@5.8.29", + "core-js": "npm:core-js@1.2.3" } } }