Skip to content

Customize HTML templates #3

Open
@loay

Description

@loay

Customize html templates in strong-error-handler, see strongloop/loopback#1650 (comment) for details.

Configuration options:

// map of templates to use for rendering responses
views: {
  // the default view
  default: path.resolve(__dirname, 'views/error-default.jade'),
  404: path.resolve(__dirname, 'views/error-not-found.jade'),
  // etc.
},

// map of static files to send as a response
files: {
  // default: path.resolve(__dirname, 'public/error.html'),
  401: path.resolve(__dirname, 'views/error-unauthorized.html'),
  // etc.
},

Requires #5

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions