{"action":"opened","issue":{"url":"https://api.github.com/repos/Romakita/ts-express-decorators/issues/460","repository_url":"https://api.github.com/repos/Romakita/ts-express-decorators","labels_url":"https://api.github.com/repos/Romakita/ts-express-decorators/issues/460/labels{/name}","comments_url":"https://api.github.com/repos/Romakita/ts-express-decorators/issues/460/comments","events_url":"https://api.github.com/repos/Romakita/ts-express-decorators/issues/460/events","html_url":"https://github.com/Romakita/ts-express-decorators/issues/460","id":362067884,"node_id":"MDU6SXNzdWUzNjIwNjc4ODQ=","number":460,"title":"[Question] Lang & traduction","user":{"login":"Tlahey","id":2856778,"node_id":"MDQ6VXNlcjI4NTY3Nzg=","avatar_url":"https://avatars1.githubusercontent.com/u/2856778?v=4","gravatar_id":"","url":"https://api.github.com/users/Tlahey","html_url":"https://github.com/Tlahey","followers_url":"https://api.github.com/users/Tlahey/followers","following_url":"https://api.github.com/users/Tlahey/following{/other_user}","gists_url":"https://api.github.com/users/Tlahey/gists{/gist_id}","starred_url":"https://api.github.com/users/Tlahey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Tlahey/subscriptions","organizations_url":"https://api.github.com/users/Tlahey/orgs","repos_url":"https://api.github.com/users/Tlahey/repos","events_url":"https://api.github.com/users/Tlahey/events{/privacy}","received_events_url":"https://api.github.com/users/Tlahey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-20T08:11:17Z","updated_at":"2018-09-20T08:11:17Z","closed_at":null,"author_association":"NONE","body":"<!-- This template it's just here to help you for write your Issue -->\r\n\r\n## Informations\r\n\r\nType | Version\r\n---|---\r\nQuestion | 4.x\r\n\r\n****\r\n\r\n## Description\r\n\r\nI would like to know if a language module is being integrated into TS.ED.\r\n\r\nThe goal would be to have a provider that can translate error messages (Exceptions nodeJs) into the user's language and integrate it into html templates.\r\n\r\nHere is an example with [i18n-express](https://www.npmjs.com/package/i18n-express).\r\n\r\n## Example \r\n\r\nOn `ServerSettings` we can configure available language and directory,\r\n\r\nREST call with Content-Language: en or fr or ...\r\n\r\nSo nodejs server know the location and set it.\r\n\r\nWe thought about several possibilities of implementation : \r\n- With a service available in all the application\r\n- With a decorator that you can configure to translate parts of the response\r\n- Provide it inside the $error handler to translate the error codes (but just for the errors and not success callback)\r\n\r\nI do not know if you have other solutions ?\r\n\r\nThanks :)"}}
{"actor":{"display_login":"Tlahey"}}