glimmerjs / glimmer-vm

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Update deprecation to assert with helpful error

mixonic opened this issue · comments

GlimmerVM has a codepath to issue deprecations for when an argument-less helper is passed with no arguments:

id: 'argument-less-helper-paren-less-invocation',

In Ember loose mode templates this syntax results in an invocation, however the behavior was deprecated in Ember 3.x https://deprecations.emberjs.com/v3.x/#toc_argument-less-helper-paren-less-invocation and has been changed to a throw in Ember 4.0 emberjs/ember.js#19843.

Here in GlimmerVM the deprecation should be converted to a dev-time assertion. This would allow for a better error message than the one throws in Ember as of this writing. The prod-mode behavior for this syntax may also change.