What are the values printed by the following two logs?
var a = 1
function fn (a) {
console.log(a);
a = 3
}
fn()
console.log(a);
Output result: undefined 1
The first printed a function does not pass actual parameters, so the printed parameter is undefined
Printing the second a is the value of var a = 1, the function a is assigned to the formal parameter but not to the global a (proximity principle)
$nextTick can be called in create
C3's var function
This method can be used if the attribute value is used in multiple places
The earliest browsers do not support the definition of css variables, so use less, sass (capability to provide variables)
语法:
1. 定义:--css变量名:css变量值
2. 使用:var(--css变量名)
作用域:
1. 局部变量 =》 .类名 { }
2. 全局变量 =》 :root { }
H5 new attributes
Elements are centered horizontally and vertically
git
C3 added
The difference between v2 and v3, which one is better
Vue life cycle
Vuex refreshes the page data and there is no how to solve it
holy grail layout
How to solve cross domain
The difference between uniapp development applet and vue development PC side
The difference between e.target and currenttarget
The difference between foreach and map
How does foreach force exit
v-model syntactic sugar
How to change the component using v-model without input and vaule (model)
How to delete the second element of the array
The method of judging the array
The difference between hash and history
instanceof
Object.prototype.toString.call() can get different types of objects
Array.isArray() is used to determine whether the passed value is an array, and returns a Boolean value The constructor attribute of
the instance points to the constructor, through the constructor attribute It can be judged whether it is an array
prototype chain? Which prototype chains have been used in daily use
common browsers
version compatible
configure webpack
The difference between npm and yarn
Event loop mechanism
es6
promise
The difference between react and v3
The final point of the prototype chain
common browsers
The difference between cookie, localstorage, and sessionstorage
How to do browser compatibility
Where are less and sass better than css
talk about cdn
Summary: On the technical side, I interviewed five or six companies, and my favorite questions are the addition of h5, c3, and es6, the difference between vue2 and vue3, and the difference between localstorage and sessionstorage
Open question:
A plan for the last five years
Have you read any technical books recently?
What do you do if the product manager's demand is unreasonable?
If you are a leader, what is your specific job like?
What to do if the project is about to go live and you only finished 10% of it (you can’t finish it by yourself, others don’t have time to help you)
Why choose the front end
what strengths do you think you have
Why come to **(city)
html, css, js which do you think you learn better
Continuously updating....