MCPcopy Create free account
hub / github.com/TruthHun/BookStack / setProp

Function setProp

static/vuejs/vue.js:6061–6070  ·  view source on GitHub ↗
(el, name, val)

Source from the content-addressed store, hash-verified

6059var cssVarRE = /^--/;
6060var importantRE = /\s*!important$/;
6061var setProp = function (el, name, val) {
6062 /* istanbul ignore if */
6063 if (cssVarRE.test(name)) {
6064 el.style.setProperty(name, val);
6065 } else if (importantRE.test(val)) {
6066 el.style.setProperty(name, val.replace(importantRE, ''), 'important');
6067 } else {
6068 el.style[normalize(name)] = val;
6069 }
6070};
6071
6072var prefixes = ['Webkit', 'Moz', 'ms'];
6073

Callers 1

updateStyleFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected