-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin preferences not persisted with correct key #238
Comments
@NullVoxPopuli was the intention to move to use class name eg |
nay, the manually specified string name was intended to be used exactly to protect against minified class names in production |
Any thoughts on where / how it might have come unstuck, or maybe it was never using the manually-specified name property string? |
use static pluginName not the class name to avoid preferences being saved with minified ClassName keys see issue #238 for more details
use static pluginName not the class name to avoid preferences being saved with minified ClassName keys see issue #238 for more details
Could have the universal-ember org adopt this addon to have more vis / attention |
ohh, that would be very positive, I think! |
@joelamb what do you think? I think the repository would benefit greatly if it could be adopted by e.g. universal-ember |
Plugin preferences should be saved with the key defined in the name property of the class
references:
API documentation
Plugin Interface
The two failing tests in this PR, point to plugin preferences being saved with the Class name (
klass.name
) as a key, rather than the value of thename
property defined on the Class.This is an issue, because this key is minified in production code, so the preference keys end up being persisted with minified, single-character keys.
This is brittle, since we cannot guarantee the value of the minified Class name, and hence any previously saved user preferences will be lost, if the key changes.
The test output is not particularly helpful in the Checks
But what it's trying to say is:
The expected plugin keys are defined with the name property for 'Column Reordering' here
and for 'Column Visibility' here
The text was updated successfully, but these errors were encountered: