{"action":"closed","issue":{"url":"https://api.github.com/repos/GrahamCampbell/Laravel-Exceptions/issues/23","labels_url":"https://api.github.com/repos/GrahamCampbell/Laravel-Exceptions/issues/23/labels{/name}","comments_url":"https://api.github.com/repos/GrahamCampbell/Laravel-Exceptions/issues/23/comments","events_url":"https://api.github.com/repos/GrahamCampbell/Laravel-Exceptions/issues/23/events","html_url":"https://github.com/GrahamCampbell/Laravel-Exceptions/issues/23","id":98186545,"number":23,"title":"Output error templates","user":{"login":"a-komarev","id":1849174,"avatar_url":"https://avatars.githubusercontent.com/u/1849174?v=3","gravatar_id":"","url":"https://api.github.com/users/a-komarev","html_url":"https://github.com/a-komarev","followers_url":"https://api.github.com/users/a-komarev/followers","following_url":"https://api.github.com/users/a-komarev/following{/other_user}","gists_url":"https://api.github.com/users/a-komarev/gists{/gist_id}","starred_url":"https://api.github.com/users/a-komarev/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/a-komarev/subscriptions","organizations_url":"https://api.github.com/users/a-komarev/orgs","repos_url":"https://api.github.com/users/a-komarev/repos","events_url":"https://api.github.com/users/a-komarev/events{/privacy}","received_events_url":"https://api.github.com/users/a-komarev/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-07-30T14:43:52Z","updated_at":"2015-07-30T14:49:59Z","closed_at":"2015-07-30T14:49:59Z","body":"It will be great to have templates customizable via `config/exceptions.php`.\r\n\r\n**ExceptionsServiceProvider.php**\r\n```\r\n$this->app->singleton(ExceptionInfo::class, function () {\r\n    return new ExceptionInfo(__DIR__.'/../resources/errors.json');\r\n});\r\n\r\n$this->app->bind(HtmlDisplayer::class, function ($app) {\r\n    return new HtmlDisplayer($app->make(ExceptionInfo::class), __DIR__.'/../resources/error.html');\r\n});\r\n```\r\n\r\nRight now I need such things:\r\n- Multi language error message for json output:\r\n\r\n`./resources/views/errors/ru/error.json`\r\n\r\n- Multi language error templates:\r\n\r\n`./resources/views/errors/ru/error.html`\r\n\r\n- Have different templates dependent of Exception:\r\n\r\n`./resources/views/errors/ru/404.html` (if Exception don't have template - use default one).\r\n\r\n- Application is separated on 2 parts: frontend & backend. Each of them got separate error templates for HtmlDisplayer (but I think this task is too complex and not so common to be included base package):\r\n\r\n`./resources/views/frontend/errors/ru/404.html`"}}