Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 2 additions & 9 deletions templates/components/api-server/template/server/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,10 @@ var boot = require('loopback-boot');

var app = module.exports = loopback();

// boot scripts mount components like REST API
// Bootstrap the application, configure models, datasources and middleware.
// Sub-apps like REST API are mounted via boot scripts.
boot(app, __dirname);

// -- Mount static files here--
// All static middleware should be registered at the end, as all requests
// passing the static middleware are hitting the file system
// Example:
// var path = require('path');
// app.middleware('files', loopback.static(
// path.resolve(__dirname, '../client')));

app.start = function() {
// start the web server
return app.listen(function() {
Expand Down