百度提前批前端一面面经
双非本科大三 昨天下午一面 今天下午打电话说过了 明天下午二面
1.css 层叠上下文
2.let const
3.怎么用es5语法实现const
4.div盒子 宽度未知,怎么实现宽高比2:1
5.promise all重写实现失败数量限制,而不是一个失败就reject
6.浏览器输入url
7.微任务宏任务看代码输出
async function async1() {
console.log('async1 start') //2
await async2()
console.log('async1 end') //7
}
async function async2() {
new Promise(function (resolve) {
console.log('promise1') //3
resolve()
}).then(function () {
console.log('promise2') //6
})
}
console.log('script start') //1
setTimeout(function () {
console.log('setTimeout') //9
}, 0)
async1()
new Promise(function (resolve) {
console.log('promise3') //4
resolve()
}).then(function () {
console.log('promise4') //8
})
console.log('script end') //5
/*
script start
async1 start
promise1
promise3
script end
promise2
async1 end
promise4
setTimeout
*/
8.事件循环机制
9.状态码
10.304协商缓存
11.etag的缺点
上来先问了项目里面的技术难点
其他有些忘了, 一个小时视频面
写个面经保佑明天二面通过
#百度2021校招提前批##面经##校招##百度##前端工程师#
九号公司成长空间 1人发布
查看16道真题和解析