emberjs / ember-string

Ember addon with String-related utilities
https://github.com/emberjs/rfc-tracking/issues/26
MIT License
6 stars 15 forks source link

Missing htmlSafe, and isHtmlSafe Redux #297

Open jherdman opened 2 years ago

jherdman commented 2 years ago

This is not entirely a duplicate of #235 per se, but possibly related.

I had a production app break recently with a deprecated import { htmlSafe } from '@ember/string' usage. Though this import is deprecated, it's not slated for removal until Ember v4. We tracked the problem down to ember-data v3.24 using @ember/string v1 which is being used in prod instead of Ember Source's.

Is it possible to add these missing functions with a deprecation warning and backport?

jeradg commented 2 years ago

Here's a minimal reproducible example of the bug mentioned by @jherdman.

https://github.com/jeradg/ember-prod-test-spike/commit/1a24746f184bccfa93ebe69f0e13717779da3271

ef4 commented 2 years ago

https://github.com/emberjs/ember-string/issues/235#issuecomment-1061413761

kategengler commented 1 year ago

I added versions of these methods that error with explanation in https://github.com/emberjs/ember-string/pull/367