Unfortunate gotcha with JavaScript's `charAt()` function: if you call `charAt()` with a value that cannot be converted to a number, `charAt()` will always return the first character.
Learn more 👉 masteringjs.io/tutorials/fun…#JavaScript#CodeNewbie
If the answer is 42, perhaps the question is "What is 101010 in decimal?" 🤔
That's what our binary to decimal converter is for 👉 masteringjs.io/tutorials/too…#JavaScript
Want to know where a function is called from without using a debugger?
Create a new Error object and print out the stack trace.
We do this probably 20x/day
#JavaScript#CodeNewbie
The `Promise.race()` function is great for implementing custom timeouts on async ops
For example, here's some code we wrote to make Bull.js initial connection time out if it can't connect after 10s
More about promises 👉 masteringjs.io/tutorials/fun…#JavaScript#CodeNewbie