-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Open
Labels
Description
Add support for the optional chaining operator ?. that is available in:
- JavaScript: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Optional_chaining
- TypeScritp 3.7: https://www.typescriptlang.org/docs/handbook/release-notes/typescript-3-7.html#optional-chaining
- Latte 2.6: https://blog.nette.org/en/new-in-latte-2-6-optional-chaining-and-custom-functions#toc-optional-chaining
- PHP 8: https://www.php.net/releases/8.0/en.php#nullsafe-operator
{# Before #}
{{ foo.bar.baz is defined ? foo.bar.baz }}
{# After #}
{{ foo?.bar?.baz }}tmrkp, stof, giorgiopogliani, sstok, Freeaqingme and 78 more