Skip to content
Myr

More work on mvc example

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 9231245 · Browse files · 7 files+53 added−5 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

7 files+53 added−5 removed

  • other:+53 added−5 removed

7 files+53 added−5 removed

modified:examples/mvc/controllers/app.js+2 added-2 removed
modified:examples/mvc/controllers/user.js+2 added-2 removed
added:examples/mvc/views/app/index.ejs+5 added
1<h1>Application Index</h1>2<p>Try visiting one of the following urls:</p>3<ul>4 <li><a href="/users">/users</a></li>5</ul>
added:examples/mvc/views/user/index.ejs+6 added
1<h1>Users</h1>2<ul>3 <% users.forEach(function(user){ %>4 <li><%- user.name %></li>5 <% }) %>6</ul>
added:examples/mvc/views/user/show.ejs+1 added
1<h1>Viewing user <%- user.name %></h1>
added:examples/mvc/views/layout.ejs+8 added
1<html>2 <head>3 <title>Express - MVC Example</title>4 </head>5 <body>6 <%- body %>7 </body>8</html>
modified:examples/mvc/mvc.js+29 added-1 removed