Javascript Interview Questions ( 12 Polyfills ) - Promise(), Memoize(), Bind(), Reduce(), Map() etc🔥

preview_player
Показать описание

Javascript Interview Questions on building 12 of the post popular polyfills will be discussed in this video Pollyfills and Output Based Questions for them

🔗 React JS Interview Series -

➡️ Source Code -

👤 Join the RoadsideCoder Community Discord -

🔗 MERN Stack Chat App Tutorial -

🔗 JS Interview Series -

🔗 Cars24 Interview Experience -

🔗 Unacademy Interview Experience -

🔗 Tazorpay Interview Experience -

🔗 React Beginner's Project Tutorials -

#JavascriptInterview #Javascript #FrontendInterview

-------------------------------------------------------------------------

00:00 Intro
00:18 map() polyfill
03:02 filter() polyfill
05:37 reduce() polyfill
08:22 call() polyfill
12:08 apply() polyfill
13:47 bind() polyfill
17:21 once() polyfill
21:08 memoize() polyfill
26:16 promise() polyfill
46:29 debounce() polyfill
49:26 throttle() polyfill

-------------------------------------------------------------------------

⭐ Support the channel -

Special Thanks to our members -
Рекомендации по теме
Комментарии
Автор

Roadside to Dream Job - Frontend Interview Prep Course 🔥🔥

RoadsideCoder
Автор

Awesome work was looking for a video with compilation of all polyfills !!

shivankar-
Автор

@8:17 The polyfill for reduce will fail in some scenarios. For example, suppose we have an array nums = [1, 2, 0, 13], we want to calculate the product of all the numbers so we do nums.myReduce((acc, curr) => acc*curr, 1 ) which will give result as 13 instead of 0. This is happening because we check if accumulator is a falsy value ( ternary operator at line 10 ), and hence assign the current index element to the accumulator. This should only be done for index===0.

FaheemKhan-ltfe
Автор

Bro ye video hi chaiye thi interview me yhi pucha jata h plz make one for reactjs all the polyfills like all hooks custom hooks, high order, fetch etc

SohailKhan-cxgb
Автор

for(var i = 1; i <= 3; i++){
setTimeout(()=>{
console.log(i);
}, 1200);
}


Output is
4
4
4

&

for(let i = 1; i <= 3; i++){
setTimeout(()=>{
console.log(i);
}, 1200);
}


Output is
1
2
3


Why??

ajiteshmishra
Автор

From where you learnt js, react
..web dev basically ?

_dikshit
Автор

I was just studying about polyfills and you got a video. You read minds or what 😂

DebopriyoBasu
Автор

Great video, for call polyfill, we can delete fn from context object to avoid any modification to the object!

manojpathak
Автор

didnt understood the promise polyfill, , why we are using onResolve and onReject ?

AnkitSharma-wjtb
Автор

bro, make video on text suggestion after cursor and top of the input, which data is coming from json file. and this is similar to bing copilot

tanvirhasan
Автор

Thank you for uploading polyfill video & prototype video will also helpful ❤

nitsminivlogs
Автор

You did a great job, thanks for uploading Bro 🤝

Kamal-
Автор

Bhai tm yaar cars24 ka interview diye the… I'm following you since last two year and was preparing accordingly and I successfully got the interview from Cars24 and the interview was good except the question to create polyfill for "groupBy". I was having no idea about the purpose of "groupBy" and how it is used in javaScript.
You are making good content and it was my bad luck to get such question😅.

Shariq
Автор

I'm confused why these methods are being referred as polyfills?

yashsolanki
Автор

Solution will not work for falsy value.

Автор

You made a mistake in throttle and debounce Pollyfils .. actually throttling is debouncing and vice versa

shubhamsaini
Автор

Array.prototype.myMap = function(fn, thisArg){
let arrInput=this;
let res=[];

for(let i=0; i<arrInput.length;i++){
res.push(fn.call(thisArg, arrInput[i], i, arrInput))
}
return res;
}



const arrInput= [1, 2, 3, 4, 5, 6];


function multipleOfTwo(el, index, arr){
return this+el*2
}

const res= arrInput.myMap(multipleOfTwo, 'Hello');


console.log(res)

ankittyagi