Previously I use JS fetch API to send request (because I'm more familiar with it). I send a request to my server and it works, but I found that fetch API is run only on it's block scope. Other block is still run while I use "await".
Okay, then I started to give try the AJAX Object. But it doesn't work, do I missed something? thanks.
Info :
I have put the "Access-Control-Allow-Origin, headers and methods".
The server only response with die(json_encode(["status" => "success"]))