basic

command
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 27, 2024 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Overview

This is an example of the most basic use of the github.com/ttd2089/stahp package.

The business logic of the application is encapsulated in an app type and the route targets are its methods.

Request parsing and response writing is handled inline where the routes are instantiated. A more realistic use of the package would include DI, generic parser builders, declarative validation, middleware, etc., but the purpose of this example is to show the core functionality of the package with no distractions.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL