pkra / mathjax-node-page

mathjax-node for pages
Apache License 2.0
42 stars 20 forks source link

Add option to pass a function for rendering error handling #79

Closed Menci closed 5 years ago

Menci commented 5 years ago

Currently this library only print the rendering error message with console.log. This PR add a option config.errorHandler to let developers do something on error, such as show stylized error message on the page.

The current behavior is preserved via the default value of config.errorHandler.

Menci commented 5 years ago

Oh, sorry. I broke something.

Menci commented 5 years ago

@pkra ping

pkra commented 5 years ago

@Menci could you rebase and add a test?

Menci commented 5 years ago

Test added. Commits merged into one and force-pushed. Conflits resolved.

pkra commented 5 years ago

Awesome -- thanks so much!