We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This feature provides compile-time route custom editing.
Simple example
serve "127.0.0.1", 5000: @AuthBasic post "/settings": echo username echo password ...
Also users will can write own decorators:
proc decoImpl(httpMethods: seq[string], routePath: string, statementList: NimNode) = statementList.insert( 0, newCall("echo", newLit(routePath)) ) # Register decorator in global scope at compile time static: regDecorator("MyDecorator", decoImpl)
The text was updated successfully, but these errors were encountered:
This also can used in SPA projects:
appRoutes "app": @GetUserAgent "/": tDiv: {userAgent}
Sorry, something went wrong.
add route decorators #176
6388a63
Little hint: decorators can be combined:
serve ...: @AuthBasic @MyDeco @DeleteUnnecessary @Code404 get "/": var x = 0 return "Hello, world!"
Ethosa
No branches or pull requests
This feature provides compile-time route custom editing.
Simple example
Also users will can write own decorators:
The text was updated successfully, but these errors were encountered: