Hello,
I am having a problem using the cordova plugin advanced HTTP.
So I’m trying to log to my local API with this code
const tab = {
'pseudo' : this.pseudo,
'mdp' : this.mdp
};
this.http.setDataSerializer('json');
this.http.setHeader('localhost:8080', 'Content-Type', 'application/json');
this.http.post('http://localhost:8080/api/utilisateur/login/', tab, {}).
then(reponse => {
console.log(reponse);
})
.catch(error => {
console.log(error);
});
and the console is displaying me a anwser with status 200 but with data empty but i’m supposed to receive the token.
Hope you guys can help me !
Thanks !