You-Dont-Know-JS icon indicating copy to clipboard operation
You-Dont-Know-JS copied to clipboard

A book series on JavaScript. @YDKJS on twitter.

Results 119 You-Dont-Know-JS issues
Sort by recently updated
recently updated
newest added

> If the `myObject` object already has a normal data accessor property called `foo` directly present on it, the assignment is as simple as changing the value of the existing...

for second edition

Chapter in question: https://github.com/getify/You-Dont-Know-JS/blob/master/es6%20%26%20beyond/ch2.md#template-literals The suggestion seems to be that the template literals would be all about strings; there's only examples that result in strings, and phrases like "final string...

for second edition

In the promise-aware gen runner, to prevent the unnecessary extra tick at the beginning, change: ```js return Promise.resolve().then( function handleNext(value){ .. } ); ``` ...to: ```js return Promise.resolve( (function handleNext(value){...

for second edition

## Book: Types & Grammar ### Chapter 4: Coercion **ToNumber** subchapter says: "ToNumber for a string value essentially works for the most part like the rules/syntax for numeric literals (see...

for second edition

## Book: Types & Grammar ### Chapter 4: Coercion **ToString** subchapter says: "But as shown earlier, if an object has its own toString() method on it, and you use that...

for second edition

The snippet in the polyfill of Function.prototype.bind() : ``` this instanceof fNOP && oThis ? this : oThis ``` I cannot really understand why still need `&& oThis` even though...

for second edition

https://github.com/iDanbo/You-Dont-Know-JS/blob/master/async%20%26%20performance/ch3.md#swallowing-any-errorsexceptions ```javascript var p = new Promise( function(resolve,reject){ resolve( 42 ); } ); p.then( function fulfilled(msg){ foo.bar(); console.log( msg ); // never gets here :( }, function rejected(err){ // never...

for second edition

**Yes, I promise I've read the [Contributions Guidelines](https://github.com/getify/You-Dont-Know-JS/blob/master/CONTRIBUTING.md)** (please feel free to remove this line). I've been having lots of trouble with 3 paragraphs in this section, IMO, the whole...

for second edition

https://github.com/getify/You-Dont-Know-JS/blob/master/types%20%26%20grammar/ch2.md#strings There's a code in this section that tries to use the **Array.prototype.reverse** function to reverse a string. ``` Array.prototype.reverse.call( a ); // still returns a String object wrapper (see...

for second edition

When reading though [YDKJS: ES6 & Beyond; Chapter 2: Syntax](https://github.com/getify/You-Dont-Know-JS/blob/master/es6%20%26%20beyond/ch2.md) about [Tagged Template Literals](https://github.com/getify/You-Dont-Know-JS/blob/master/es6%20%26%20beyond/ch2.md#tagged-template-literals), I thought of the case, "what if a multi-line tagged template literal is inside of a...

for second edition