js加载顺序
function queryConfig (callback) {
let loadNameData = function (callback) {
console.log('第1次加载')
callback.call()
}
let loadAgeData = function (callback) {
console.log('第2次加载')
callback.call()
}
loadNameData(function() {
loadAgeData(function() {
callback.call()
console.log('第4次加载')
})
})
}
function afterRender () {
console.log('第3次加载')
}
queryConfig(afterRender)