You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Feature Request:
I understand that Wasabi is inspired by Sinatra and Express.js, but those are based on dynamic languages. Since this is Kotlin we are talking about, I wonder if any kind of support for type-safe params is planned?
By type-safe params I mean route params, query params, and body. Preferably by binding to an object. For example maybe something along the lines of:
data class ProjectID(val customerId: String, val projectId: String)
data class ProjectData(val name: String, ...)
server.put('/customer/:id/:project', {
val projectId = request.bindParams<ProjectID>();
val projectDetails = request.bindBody<ProjectData>();
});
Perhaps it's even possible to use annotations.
I understand this is somewhat SpringMVC-esque and not exactly the Sinatra way, but perhaps some lightweight version is still suitable? It makes sense to provide some type-safety if applying the Sinatra paradigm to a type safe language
Feature Request:
I understand that Wasabi is inspired by Sinatra and Express.js, but those are based on dynamic languages. Since this is Kotlin we are talking about, I wonder if any kind of support for type-safe params is planned?
By type-safe params I mean route params, query params, and body. Preferably by binding to an object. For example maybe something along the lines of:
Perhaps it's even possible to use annotations.
I understand this is somewhat SpringMVC-esque and not exactly the Sinatra way, but perhaps some lightweight version is still suitable? It makes sense to provide some type-safety if applying the Sinatra paradigm to a type safe language
(I believe NancyFX may be relevant example)
The text was updated successfully, but these errors were encountered: