New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adds a couple of ES6 related questions (partly addresses #421) #440
Conversation
These are great questions. Especially the one about That being said, I am wondering if the preceding question |
You have a valid point : ) However Anyway, could be rephrased or completely removed, up to you : ) |
@Powell-v2 my reference to In short, will this still be the |
Probably not, who knows. How about rephrasing: "What is the latest standard for accessing the list of arguments passed to a function and how it compares to other approaches?" |
I guess, as an interviewer, I would never ask that question as there is too much room for debate. Again, I assume that this is in reference to the I guess I have a personal preference for more direct questions as not to let the interviewee flail.
Great question. Maybe something along this line of questioning that reveals the dev's knowledge of passing in an array to a function. |
What I had in mind was the 'rest syntax' which eliminates the need to convert
vs.
|
Right. I had assumed that you were referencing the |
3d00d9b
to
f38adb5
Compare
94bafea
to
73a94a1
Compare
Indeed. I'm glad we discussed this : ) Commit has been updated - I removed 1st question. |
🥇 |
Here is an addition to JS section: 4 questions about latest ES6 standard.
1. What is the most modern approach to accessing the list of arguments passed to a function?
This question identifies if candidate is aware of rest syntax, which is the modern standard for handling parameters passed to a function. Explaining what is the problem with
arguments
, imo, should count as bonus points.2. What are the benefits of using
spread syntax
and how is it different fromrest syntax
?If a candidate knows in which cases to opt for spread syntax, it means that he/she is writing more concise, cleaner code (e.g. replacing apply). Knowing the difference is really important since both syntaxes look exactly the same, but the aims are different.
3. How can you share code between files?
This one tests candidate's knowledge about ES6 modules, which is an essential part of modern day web development.
4. Why you might want to create static class members?
The purpose is to elicit an explanation of "static vs. private", plus common use case for static class methods.