1.0.1 • Published 2 years ago
@cat1989/web-apis v1.0.1
web-apis
Build secure REST APIs
class PeopleController extends ControllerBase {
@httpGet()
getAll() {
return [
new People('Ana'),
new People('Felipe'),
new People('Emillia'),
]
}
}
class People {
name: string;
constructor(name: string) {
this.name = name
}
}
curl http://localhost/people
[{"name":"Ana"},{"name":"Felipe"},{"name":"Emillia"}]