Skip to content

Instantly share code, notes, and snippets.

@marcoshenrique-dev
Created September 19, 2020 17:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save marcoshenrique-dev/15a263be94f21c6dc293f35abf4f5707 to your computer and use it in GitHub Desktop.
Save marcoshenrique-dev/15a263be94f21c6dc293f35abf4f5707 to your computer and use it in GitHub Desktop.
const express = require('express');
const app = express();
const redis = require('ioredis');
const client = new redis();
app.post(('/') , async (req,res) => {
const result = await client.set('teste', 'Valor');
res.send(result);
console.log(result);
} );
app.listen(3000 , () => {
console.log('server started');
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment