Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/express-helper/express-helper

Express helper
https://github.com/express-helper/express-helper

express express-utils mvc-pattern

Last synced: about 1 month ago
JSON representation

Express helper

Awesome Lists containing this project

README

        

# expressjs-helper

This library is a utility library that runs on top of express and is lightweight,
but supports many convenient functions for using express.

```bash
npm i expressjs-helper
```

Only [TypeScript](https://www.typescriptlang.org/) is supported.

## How to use

```typescript
// controller/TestController.ts
@RestController()
export class TestController{

@Get("/hello")
get(){
return "helloWorld";
}
}

// app.ts
const app: Express = express();
const port = 8000;

app.use(expressHelper());
app.use(expressHelperEndpoint());

app.listen(port, () => {
console.log(`Server is running on http://localhost:${port}`);
});
```