Last active
November 27, 2016 00:48
-
-
Save raphaelpor/d37c2ce4e7872caa8bcebc13ceedb7bd 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 fitch from 'fitch'; | |
const config = { | |
body: { cat: 'grumpy' }, | |
cache: 'no-cache', | |
mode: 'no-cors', | |
params: { | |
categ: 10, | |
type: 5, | |
}, | |
} | |
fitch.post('http://localhost:8080/cats', config) | |
.then(response => { | |
console.log(response.data); | |
}) | |
.catch(err => { | |
console.log(err.message); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment