2 ms·
Is it that different? Assuming you would use '?' and ':', presumable we might see both the following then: let foo = foo()?; let bar = bar() ? this()
by kbenson 10y ago
Is it that different? Assuming you would use '?' and ':', presumable we might see both the following then:
let foo = foo()?;
let bar = bar() ? this() : that();
- ww520 10y ago? already has different forms as of now. You can do foo()?; or foo()?.bar(). People don't seem to be confused. expr ? expr : expr is just another form. The ternary form is so well known that I doubt people have problem recognizing it.