MCPcopy
hub / github.com/less/less.js / clone

Function clone

packages/less/lib/less-browser/index.js:44–52  ·  view source on GitHub ↗
(obj)

Source from the content-addressed store, hash-verified

42 const typePattern = /^text\/(x-)?less$/;
43
44 function clone(obj) {
45 const cloned = {};
46 for (const prop in obj) {
47 if (Object.prototype.hasOwnProperty.call(obj, prop)) {
48 cloned[prop] = obj[prop];
49 }
50 }
51 return cloned;
52 }
53
54 function loadStyles(modifyVars) {
55 const styles = document.getElementsByTagName('style');

Callers 2

loadStylesFunction · 0.70
loadStyleSheetFunction · 0.70

Calls 1

callMethod · 0.80

Tested by

no test coverage detected