Skip to content

Loading…

Provide a convenience method for setting `customStyle` and calling `updateStyles` #1915

Closed
sorvell opened this Issue · 0 comments

1 participant

@sorvell
Owner

Polymer provides a customStyle object which can be used to set css custom properties. To apply these values, updateStyles must be called. Since this is typically done in lockstep, there should be a 1 step option, e.g.:

this.updateStyles({'-foo': 'red'});
// short for
this.customStyles['--foo'] = 'red';
this.updateStyles();
@sorvell sorvell self-assigned this
@sorvell sorvell referenced this issue from a commit
@sorvell sorvell Fixes #1851: Include `customStyle` in the style host cache key so tha…
…t changes to customStyle are recognized.

Fixes #1915: Include a `customStyleProperties` argument to `updateStyles` for convenience.
6bc360d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.