frontend interview questions 2020

This repository contains a number of front-end interview questions that can be used when vetting potential candidates. It is by no means recommended to use every single question here on the same candidate (that would take hours). Choosing a few items from this list should help you vet the intended skills you require.

Frontend interview questions
  • Do you use CSS preprocessors? …
  • Explain the difference between Flexbox and CSS Grid. …
  • What is and why to use the Block Element Modifier (BEM) convention?
  • JavaScript: Explain how you can use JavaScript functions such as forEach, Map, or Reduce.

Frontend Interview Questions 2021 | Front End Developer Interview Questions And Answers |Simplilearn

What is the difference between unit tests and end-to-end tests?

There is a ton of overlap but at a high-level unit tests mean testing your actual code. Making sure that functions return expected results when given specific inputs. End-to-end tests are intended to test the website itself, not the code. They simulate clicks and scrolls and make sure the site behaves accordingly.

26. What is the difference between attribute and property?

Attributes are an element of an HTML document while properties are a part of the Document Object Model (DOM).

Example:

Here, value and type are the attributes of HTML, but when the statement is read by the browser and parses this code it will make a DOM with different properties, like accept, autofocus, accessKey, baseURI, checked, childElementCount, align, alt, childNodes, children, classList, className, attributes, and clientHeight.

Example:

What is the difference between inline and block elements?

Inline elements cannot have a height or width. Examples of inline elements include span, a, and img. Block elements get their own line and take up the full width available. Examples of block elements are div, p, and h1.

Related Posts

Leave a Reply

Your email address will not be published.