Anyone have any best practices for localization wi...
# ktor
j
Anyone have any best practices for localization within ktor? I'm thinking something like all my exceptions should extend some special exception that will have support for some format of resources and then use the "Content-Language" header provided by the client to return localized error messages.
m
Never thought about that, but this idea of localized exceptions is cool.
j
This pattern was somewhat inspired of how C# .NET MVC does it. While we don't want the 5xx HTTP to be localized. We do want to return 4xx error messages to client localized.
👍 1
103 Views