前端面试每日3+2(第34天)
冰洋 1/4/2020 前端100问
当你发现自己的才华撑不起你的野心时,就请安静下来学习吧!
鲁迅说过:
答案仅供参考...
# 1、(第 36 题)使用迭代的方式实现 flatten 函数
🌿【解析】🌿
参考答案 (opens new window) --- 感谢【Daily-Interview-Question】 (opens new window)
# 2、(第 37 题)为什么 Vuex 的 mutation 和 Redux 的 reducer 中不能做异步操作?
🌿【解析】🌿
参考答案 (opens new window) --- 感谢【Daily-Interview-Question】 (opens new window)
# 3、(第 38 题)(京东)下面代码中 a 在什么情况下会打印 1?
var a = ?;
if(a == 1 && a == 2 && a == 3){
console.log(1);
}
1
2
3
4
2
3
4
🌿【解析】🌿
参考答案 (opens new window) --- 感谢【Daily-Interview-Question】 (opens new window)
# 4、(第 39 题)介绍下 BFC 及其应用。
🌿【解析】🌿
参考答案 (opens new window) --- 感谢【Daily-Interview-Question】 (opens new window)
# 5、(第 40 题)在 Vue 中,子组件为何不可以修改父组件传递的 Prop
如果修改了,Vue 是如何监控到属性的修改并给出警告的。
🌿【解析】🌿
参考答案 (opens new window) --- 感谢【Daily-Interview-Question】 (opens new window)