Frontend Interview Questions For 5 Years Of Experience
Overview
This document presents a compilation of frontend interview questions tailored for candidates possessing around five years of experience. The questions span across various essential frontend technologies and concepts, aiming to evaluate the depth and breadth of the candidate's knowledge.
Interview Rounds
The interview process typically involves questions from the following categories:
HTML Interview Questions
- What is the use of the
aria-hiddenattribute? - What are some important points related to accessibility?
- Which screen reader is used for which browser for accessibility testing?
- What are web workers?
- Which HTML elements were used before HTML5 for embedding video into a website?
- What is an image map?
- What does semantic HTML mean?
- What are the new features of HTML5?
- Explain the use of meta tags in HTML.
- What are view state and session state?
- What should be preferred for storing tokens:
localStorage,sessionStorage, or cookies, and why?
CSS Interview Questions
- How to create a half circle using CSS?
- How to create a triangle using CSS?
- How to create a carousel using CSS?
- What are the benefits of using CSS preprocessors?
- How can you implement responsive images?
JavaScript Interview Questions
- What are the design patterns in JavaScript?
- What is the event loop in JavaScript?
- How to deep clone in JavaScript?
- How to flatten an array in JavaScript?
- What is debounce in JavaScript?
- Write a code to flatten the contents of an object.
- How to create a virtual DOM in JavaScript?
- What is the critical rendering path?
- What is the
freezemethod in JavaScript? - What are the SOLID principles in JavaScript?
- What is the
sealmethod in JavaScript? - What is the difference between Angular and React?
- How to watch variable changes in JavaScript?
- How to create a change detection mechanism for a JavaScript framework?
- What is functional programming in JavaScript?
- What is quick sort, and what is its time complexity?
- Explain bubble sort and insertion sort with examples.
- What is a REST API?
- How to apply conditional breakpoints in Chrome browser debugging tool?
- Why is storing JWT in a cookie safer than storing it in session storage or local storage? Is storing in a cookie 100 percent safe? What if one copies JWT from a cookie in the browser debug panel and uses it in a CSRF attack?
- What is an execution context and lexical environment in JavaScript?
- What is a generator function in JavaScript?
Angular Interview Questions
- What are custom directives in Angular, and how to create them?
- What are the security features in Angular?
- What is Storybook in Angular?
- What are the design patterns in Angular?
- What are interceptors in Angular?
- How to create a custom decorator in Angular?
- How to make multiple HTTP calls in parallel in Angular?
- What is a module in TypeScript, and how can you use it?
- How to hit an API before the loading of the
appComponent? - If there is a package (or say library) that is not available through NPM, then how would you use it in your Angular application?
- How to optimize an Angular application using the
OnPushchange detection strategy? - What are the types of forms available in Angular? Explain with syntax.
- How to improve Angular app performance?
- What is AuthGuard in Angular?
- Explain
switchMap,mergeMap,forkJoin,combineLatest,concatMap,exhaustMap. What would happen if any of the requests fails inswitchMap,mergeMap, orforkJoin? - What is dependency injection?
- How do you handle errors in RxJS observables?
- How do you implement backpressure in RxJS?
- Can you explain what is the purpose of using schedulers in RxJS, and give an example of a common scheduler?
- What is the difference between a pipeable operator and a patch operator in RxJS?
- What is the difference between AOT and JIT?
- How do you use the
retry()operator in RxJS, and what is its purpose? - What is Angular change detection and how does it work?
- What is zone.js in Angular?
- How to dynamically create form fields with FormArray in Angular?
- What is ngZone in Angular?
- Can an event triggered in a parent cause change detection in a child with the
OnPushstrategy in Angular? - Can an event triggered in a child cause change detection in a parent with the
OnPushstrategy in Angular? - How to optimize an Angular application?
- Explain pure and impure pipes in Angular?
- How to test an Angular Service?
- Explain
ngAfterContentInithooks? - Explain
ngAfterViewInithook with example? - Difference between
ngAfterContentInitandngAfterViewInit?
Git Interview Questions
- What is tagging in Git?
- What is rollback in Git?
- What is the
git bisectcommand? - What is the use of Reflog in Git?
- How does Git handle file conflicts when merging branches?
- What are Git hooks, and how can they be used in a repository?
- Explain the concept of "cherry picking" in Git and how it can be done.
JavaScript Coding Interview Questions
- Write code to display which character is coming how many times in a given string.
- Write a function to check whether a string is a palindrome or not with the time complexity of the code.
- Given an array containing some numbers write code to that will find out the missing numbers in the array's range.
- Write code to reverse all the words of a given string. For example: Input: "how are uoy" Output: "Woh era you"
- How to segregate 0s and 1s in an array in Javascript?
- Write a function to check if an anagram of a string is a palindrome or not.
- Write code to check if two strings are anagrams of each other.
- Write code to group items of an array by category.
- How to get the maximum count of consecutive 1's in an array?
- How do you write a factorial code in JavaScript?
- Given an integer array, find the subarray with the largest sum, and return its sum.
- How to merge two sorted arrays in JavaScript?
- How do you check if a value is a prime number?
- How to reverse a string in JavaScript using recursion?
Key Takeaways
The questions highlight the need for a strong foundation in core frontend technologies. Candidates should demonstrate practical experience in applying these technologies to solve real-world problems. A solid understanding of JavaScript fundamentals, combined with experience in a modern framework like Angular and proficiency in version control systems like Git, are crucial for success.
Original Source
This experience was originally published on medium. Support the author by visiting the original post.
Read on medium