Last active
January 16, 2019 14:23
-
-
Save ms314006/3f0d97f7ca4825d93d612e57a14553bb to your computer and use it in GitHub Desktop.
javascript
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
let data = {} | |
//使用 async 將 ajax 請求改為同步。 | |
$.ajax({ | |
url: '', | |
async: false, | |
success: (status)=>{ | |
data = status | |
} | |
)} | |
//data為statue | |
console.log(data) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment