Created
March 11, 2020 09:42
-
-
Save kylemocode/0a01c452861fda598e1ca17876351472 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import express, { Application, Request, Response, NextFunction } from 'express'; | |
import rateLimiter from './middleware/rateLimiter'; | |
import bodyParser from 'body-parser'; | |
const app: Application = express(); | |
app.use(bodyParser.json()); | |
app.get('/', rateLimiter, (req: Request, res: Response) => { | |
res.send('test'); | |
}) | |
app.listen(5000, () => { | |
console.log('server running on port 5000'); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment