<p dir="auto">Relocated from <code class="notranslate">angular.io</code>, <a href="https://github.com/angular/angular.io/issues/562" data-hovercard-type="issue" data-hovercard-url="/angular/angular.io/issues/562/hovercard">issue 562</a></p>
<p dir="auto">angular2: 2.0.0-beta.0<br>
Safari 9.0 (10601.1.56.2)</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="EXCEPTION: ReferenceError: Can't find variable: Intl in [ ({{item.price | currency:'USD':true:'.2-2'}}) in AppComponent@7:164]
logErrorangular2.dev.js:23513
logGroupangular2.dev.js:23524
callangular2.dev.js:1144
(anonymous function)angular2.dev.js:14800
_notifyOnErrorangular2.dev.js:5795
onErrorangular2.dev.js:5699
runangular2-polyfills.js:140
(anonymous function)angular2.dev.js:5718
zoneBoundFnangular2-polyfills.js:110
lib$es6$promise$$internal$$tryCatchangular2-polyfills.js:1510
lib$es6$promise$$internal$$invokeCallbackangular2-polyfills.js:1522
lib$es6$promise$$internal$$publishangular2-polyfills.js:1493
(anonymous function)angular2-polyfills.js:242
microtaskangular2.dev.js:5750
runangular2-polyfills.js:137
(anonymous function)angular2.dev.js:5718
zoneBoundFnangular2-polyfills.js:110
lib$es6$promise$asap$$flushangular2-polyfills.js:1304
promiseReactionJob"><pre class="notranslate"><code class="notranslate">EXCEPTION: ReferenceError: Can't find variable: Intl in [ ({{item.price | currency:'USD':true:'.2-2'}}) in AppComponent@7:164]
logErrorangular2.dev.js:23513
logGroupangular2.dev.js:23524
callangular2.dev.js:1144
(anonymous function)angular2.dev.js:14800
_notifyOnErrorangular2.dev.js:5795
onErrorangular2.dev.js:5699
runangular2-polyfills.js:140
(anonymous function)angular2.dev.js:5718
zoneBoundFnangular2-polyfills.js:110
lib$es6$promise$$internal$$tryCatchangular2-polyfills.js:1510
lib$es6$promise$$internal$$invokeCallbackangular2-polyfills.js:1522
lib$es6$promise$$internal$$publishangular2-polyfills.js:1493
(anonymous function)angular2-polyfills.js:242
microtaskangular2.dev.js:5750
runangular2-polyfills.js:137
(anonymous function)angular2.dev.js:5718
zoneBoundFnangular2-polyfills.js:110
lib$es6$promise$asap$$flushangular2-polyfills.js:1304
promiseReactionJob
</code></pre></div>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="format@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15669:22
_format@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15824:43
transform@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15871:32
detectChangesInRecordsInternal
detectChangesInRecords@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8824:44
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8807:34
_detectChangesContentChildren@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8871:30
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8808:41
_detectChangesInViewChildren@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8877:30
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8811:40
detectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8796:28
detectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:4978:29
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14977:40
forEach@[native code]
tick@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14976:41
_loadComponent@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14942:16
tick@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14917:33
run@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:138:22
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5719:37
zoneBoundFn@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:111:22
lib$es6$promise$$internal$$tryCatch@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1511:24
lib$es6$promise$$internal$$invokeCallback@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1523:52
lib$es6$promise$$internal$$publish@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1494:52
http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:243:7
microtask@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5751:19
run@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:138:22
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5719:37
zoneBoundFn@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:111:22
lib$es6$promise$asap$$flush@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1305:17
promiseReactionJob@[native code]"><pre class="notranslate"><code class="notranslate">format@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15669:22
_format@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15824:43
transform@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:15871:32
detectChangesInRecordsInternal
detectChangesInRecords@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8824:44
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8807:34
_detectChangesContentChildren@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8871:30
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8808:41
_detectChangesInViewChildren@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8877:30
runDetectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8811:40
detectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:8796:28
detectChanges@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:4978:29
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14977:40
forEach@[native code]
tick@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14976:41
_loadComponent@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14942:16
tick@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:14917:33
run@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:138:22
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5719:37
zoneBoundFn@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:111:22
lib$es6$promise$$internal$$tryCatch@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1511:24
lib$es6$promise$$internal$$invokeCallback@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1523:52
lib$es6$promise$$internal$$publish@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1494:52
http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:243:7
microtask@http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5751:19
run@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:138:22
http://localhost:3000/node_modules/angular2/bundles/angular2.dev.js:5719:37
zoneBoundFn@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:111:22
lib$es6$promise$asap$$flush@http://localhost:3000/node_modules/angular2/bundles/angular2-polyfills.js:1305:17
promiseReactionJob@[native code]
</code></pre></div>
<p dir="auto">Dart has built-in <code class="notranslate">assert(cond)</code> where <code class="notranslate">cond</code> is either a bool or a function returning a bool.</p>
<p dir="auto">What do you think of adding support for it to the transpiler ?</p>
<p dir="auto">This could be linked with type assertions:</p>
<ul dir="auto">
<li>When type assertions are enabled, assert would throw on false,</li>
<li>When type assertions are disabled, assert would be removed from the code.</li>
</ul>