Following some discussions on Discord it is still not entirely clear what the way forward should be. I'm attempting to write down the current situation here and would welcome comment on how this is supposed to be changed:
- if
@ember/jquery is not used
- if
jquery-integration is not set
- the build shows a warning about either setting the flag or using the addon, otherwise same situation as
jquery-integration: enabled
- if `jquery-integration is enabled
Ember.$ shows a deprecation for Ember.$
import $ from 'jquery'; shows a deprecation for Ember.$
this.$() shows a deprecation for this.$()
- if `jquery-integration is disabled
Ember.$ throws an error
import $ from 'jquery'; throws an error
this.$() throws an error
- if
@ember/jquery is used
- if `jquery-integration is enabled
Ember.$ ??? (not tested)
import $ from 'jquery'; works without deprecation warning
this.$() shows a deprecation for this.$()
- if `jquery-integration is disabled
Ember.$ throws an error
import $ from 'jquery'; works without deprecation warning
this.$() throws an error
/cc @rwjblue @chancancode @simonihmig
Following some discussions on Discord it is still not entirely clear what the way forward should be. I'm attempting to write down the current situation here and would welcome comment on how this is supposed to be changed:
@ember/jqueryis not usedjquery-integrationis not setjquery-integration: enabledEmber.$shows a deprecation forEmber.$import $ from 'jquery';shows a deprecation forEmber.$this.$()shows a deprecation forthis.$()Ember.$throws an errorimport $ from 'jquery';throws an errorthis.$()throws an error@ember/jqueryis usedEmber.$??? (not tested)import $ from 'jquery';works without deprecation warningthis.$()shows a deprecation forthis.$()Ember.$throws an errorimport $ from 'jquery';works without deprecation warningthis.$()throws an error/cc @rwjblue @chancancode @simonihmig