3 Questions: You Don't Know JavaScript | Prime Reacts

preview_player
Показать описание
Recorded live on twitch, GET IN

MY MAIN YT CHANNEL: Has well edited engineering videos

Discord

Hey I am sponsored by Turso, an edge database. I think they are pretty neet. Give them a try for free and if you want you can get a decent amount off (the free tier is the best (better than planetscale or any other))
Рекомендации по теме
Комментарии
Автор

Every time I start to think I know javascript, I watch videos like this and realize how wrong I am

elirane
Автор

lol the chat ate him alive for getting the first question wrong, meanwhile 80% of JS devs would also get it wrong.... the "senior netflix engineer btw" in the chat was gold lol

Eeezus
Автор

Things I learned from this:
- Promise callbacks are microtasks, not tasks
- "return" in generators is valid

ventic
Автор

I remember the days when EcmaScript didn't even have proper classes. Back in my day, we used functions named in PascalCase and then prefaced calls to them with the "new" keyword.

kkiller
Автор

God, I was laughing so hard when he was wrong in the last question 😂

ucwolct
Автор

Ok thats it! Im taking javascrip proficiency out of my CV. thanks!

dipereira
Автор

"you don't know javascript"

i know, i wanna keep it that way

alastor--radiodemon
Автор

25:49 I think prime is wrong here. I am pretty sure that this is how generator functions work in almost every language. Remember that the end of the function has an implicit empty return. If returned values in generators were also included in the iteration, then this generator

function* whatever() {
for (const elem of ["fist", "second", "last"]) {
yield elem
}
}

would produce "first", "second", "last", undefined and to get the obviously intended results of "first", "second", "last" you would have to do something like

function* whatever() {
for (const elem of ["fist", "second", "last"]) {
if (elem === "last") {
return elem
} else {
yield elem
}
}
}

which is just ridiculously stupid

ruroruro
Автор

GOTO considered harmful
JS considered deadly and dangerous

adjbutler
Автор

Maybe I should learn Blazor & just run C# in the browser instead.

coder_
Автор

Every day I thank the lord for not learning Javascript as my first language (visual basic chads rise up)

MaybeADragon
Автор

I actually switched smoothly from watching Anchorman 2 to Prime. The legend continues.

sebastianwapniarski
Автор

This was fun!
IIFE - Immediately invoked function expression. I've heard it pronounced 'iffy' most of the time.

11:49 - I've definitely modified a few built-in prototypes in order to get Vue2 to work in an HTML Application / .hta file. mshta.exe uses an ancient JavaScript engine, so some monkey patching was absolutely required to get things to work at all.

ISKLEMMI
Автор

20:20 javascript does have Option, it's constructor for html <option> element

RandomGeometryDashStuff
Автор

Lydia's slides are beautifully mind-blowing, does anyone know what she uses to make them?

_evillevi
Автор

You know what would be interesting? A replay iterator that aside from next, return and throw also has a reset function. That way you don't have to keep a reference around to the original generator function. You can just reuse the current iterator. One that could also have niche usecases would be the caching replay iterator that, when reset, it doesn't have to recompute the original values, since it would have stored those values in a cache. That does defeat the purpose of generators somewhat, since they normally allow for a low memory footprint during iteration, but when caching you do still have that footprint. In such a case the only benefit would be is that you're fetching the values lazily, so you don't have to construct a full list of values before iterating over them.

rikschaaf
Автор

Senior dev vs junior interview questions

asdjzcx
Автор

Extra info about question 1. The prints for 4, 5 and 6 are sync in the javascript engine while 1 is queued in the engine. 5 is not implemented in the engine (not ecmascript) but still queues on the engines task queue. The setTimeout callback is added to the runtimes event loop and would not work at all in a pure javascript engine evaluation (it is a webAPI that requires a runtime). Writing my own super basic javascript runtime in C was great for learning how javascript runtimes work.

FanatiQS
Автор

1:56 - looking at this, tells me: JS, you're drunk. Go home!

size_t
Автор

my_obj.__proto__ = "We're all adults here, I can modify whatever I want"

tylermfdurden