Danielle McLean wrote:

variables declared
using `let` or `const` would be scoped to the individual `if` or `while`
statement, rather than the containing block. In other words, the above syntax
would be equivalent to the following currently-valid form I ended up writing:

    {
      const oldValue = _.get(object, 'some.long.path');
      if (oldValue) object.some.long.path = transform(oldValue);
    }

What about `else` blocks, would the variables be available in them as well?

- Bergi

_______________________________________________
es-discuss mailing list
[email protected]
https://mail.mozilla.org/listinfo/es-discuss

Reply via email to