background
I wanted to find an internship during the summer vacation. I happened to see the senior’s internal promotion, so I sent my resume without sincerity to the past. After more than a week, I received a telephone interview email (I am very suspicious that the senior’s face is bigger).
The problem
Here are just a few key points to record (I remember…).
React and Vue
The same
- use
Virtual DOM
- componentization
The difference between
React
useJSX
Render the page,Vue
Use a simple templateReact
notMVVM
And theVue
Yes, it has two-way data binding, allowing interpolationReact
Can only be used insetState
Modify the state,Vue
Can be directly modifieddata
React Native
withWeex
Promise
Promise
It’s essentially a state machine. eachpromise
It can only be one of three states:pending
,fulfilled
或rejected
. State transitions can only bepending
->fulfilled
orpending
->rejected
. The state transition is irreversiblethen
The method can be the samepromise
Call several timesthen
Method must return onepromise
. There is nothing in the specification explicitly to return a new onepromise
I’m going to reuse the old onepromise
(i.e.return this
), most implementations return a new onepromise
And reuse the old onespromise
It is possible to change the internal state, which is also against the specification- Value through
I also asked for the implementation, so I just said nextTick()
I only answered some of the above questions… Feel their level is still not enough
Prototype chain
For example: when looking for a member on an Object, if no member is found, continue to follow proto, if no member is found, then error (until object. prototype) balabala…
inheritance
Prototype chain
// B inherits A
B.prototype = new A()
Copy the code
Class
class B extends A{
constructor(props) {
// Call the constructor that implements the parent class
super(props); }}Copy the code
Undifined and Null
These are the two basic types of Js.. balabala..
When do these two things happen?
Undipay is not valued.. When you define a variable but do not assign a value, or things like variable promotion balabala..
Null in my opinion is a pointer to Object.. Because Typeof Null = Objectbalabala…
Interviewer: When will Null appear?
I TM unexpectedly did not answer.. At that time, my heart was a chill, then I thought Null is not the reference type of no assignment yao..
Have you read any source code
Read React setState and Node setImmediate… But considering the level of their own problems here on a brush over.. Then the mouth owe a sentence feel read source code for their own stage help, the interviewer also asked why, I finally not easy round back 23333
The new Html5 and Css3 features you use
HTML5
Audio, Video, Canvas, datalist..
Canvas is widely used. It has been used to imitate the promotion video animation Datalist of Strawberry Music Festival. It is often used in lazy loading.
CSS3
Selector, Animation, Transition, Transform…
Then let me describe seeing an animation and how to do it.. balabala..
I don’t think anyone can answer all the… Basically still say oneself use more
conclusion
The interview in
After meeting for about 40-50 minutes or so, the technical point self-feeling pulled about 80%, did not answer also try to pull a little (except some of their own really have not heard). The technical aspect of the feeling question is not very wide (maybe because I am an intern), the original aspect of the question is more.. I didn’t ask about Css and React, which I’m good at. I didn’t ask about browser and Http. Overall, the interview was not difficult. May consider that I am only a sophomore to practice 😂
Our side
First phone interview… The whole nervous, the brain intermittently temporary blank, many of their own will not perfect the answer is very sorry, they will want to show that did not ask also a little regret, there are a few awkward silence (afraid of the air suddenly quiet), no accident should be cool QAQ.
But think of their sophomore year there is still time to remedy, hurriedly put this blog out to reflect on their own, we encourage each other ~
Some supplement
- This article seems to have omitted most of the questions (I really can’t remember)
- Later, the Leader asked me many questions related to the project, but please look at the next one
- This article has recorded only the ones I remember that I thought were valuable (and actually thought I could write about)
- The interviewer was good
- This article is more suitable for small meng new internship
- This article is updated in real time with my memory..
The results of
I promised to reply within a week, but I haven’t got it yet. I think it’s cold. I feel very bad about my attitude, including the interviewer being late before the interview, which makes my impression on Sohu discounted