loopbackio / loopbackio/strong-error-handler

Customize HTML templates

Open
#3 5 comments 0 reactions 1 assignee View on GitHub

@davidcheung is already working on this.

Since May 12, 2016.

feature help wanted needs-priority
Dominant language
JavaScript
Stars
38
Forks
36
Avg merge
1d 12h
Merged PRs (30d)
11

Description

Customize html templates in strong-error-handler, see https://github.com/strongloop/loopback/issues/1650#issuecomment-161920555 for details.

Configuration options:

``` js
// 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

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.