@emotion/utils
Advanced tools
Comparing version 0.8.0 to 0.8.1
@@ -26,3 +26,3 @@ 'use strict'; | ||
// the registered cache to know whether a style is global or not | ||
// also, note that this will be dead code eliminated in the browser | ||
// also, note that this check will be dead code eliminated in the browser | ||
true === false && context.compat !== undefined) && context.registered[context.key + "-" + insertable.name] === undefined) { | ||
@@ -29,0 +29,0 @@ context.registered[context.key + "-" + insertable.name] = insertable.styles; |
@@ -22,3 +22,3 @@ var isBrowser = true; | ||
// the registered cache to know whether a style is global or not | ||
// also, note that this will be dead code eliminated in the browser | ||
// also, note that this check will be dead code eliminated in the browser | ||
true === false && context.compat !== undefined) && context.registered[context.key + "-" + insertable.name] === undefined) { | ||
@@ -25,0 +25,0 @@ context.registered[context.key + "-" + insertable.name] = insertable.styles; |
@@ -26,3 +26,3 @@ 'use strict'; | ||
// the registered cache to know whether a style is global or not | ||
// also, note that this will be dead code eliminated in the browser | ||
// also, note that this check will be dead code eliminated in the browser | ||
isBrowser === false && context.compat !== undefined) && context.registered[context.key + "-" + insertable.name] === undefined) { | ||
@@ -36,3 +36,5 @@ context.registered[context.key + "-" + insertable.name] = insertable.styles; | ||
if (!isBrowser) { | ||
if (isBrowser) { | ||
rules.forEach(context.sheet.insert, context.sheet); | ||
} else { | ||
var joinedRules = rules.join(''); | ||
@@ -50,4 +52,2 @@ | ||
} | ||
} else { | ||
rules.forEach(context.sheet.insert, context.sheet); | ||
} | ||
@@ -54,0 +54,0 @@ } |
@@ -22,3 +22,3 @@ var isBrowser = typeof document !== 'undefined'; | ||
// the registered cache to know whether a style is global or not | ||
// also, note that this will be dead code eliminated in the browser | ||
// also, note that this check will be dead code eliminated in the browser | ||
isBrowser === false && context.compat !== undefined) && context.registered[context.key + "-" + insertable.name] === undefined) { | ||
@@ -32,3 +32,5 @@ context.registered[context.key + "-" + insertable.name] = insertable.styles; | ||
if (!isBrowser) { | ||
if (isBrowser) { | ||
rules.forEach(context.sheet.insert, context.sheet); | ||
} else { | ||
var joinedRules = rules.join(''); | ||
@@ -46,4 +48,2 @@ | ||
} | ||
} else { | ||
rules.forEach(context.sheet.insert, context.sheet); | ||
} | ||
@@ -50,0 +50,0 @@ } |
{ | ||
"name": "@emotion/utils", | ||
"version": "0.8.0", | ||
"version": "0.8.1", | ||
"description": "internal utils for emotion", | ||
@@ -5,0 +5,0 @@ "main": "dist/utils.cjs.js", |
@@ -42,3 +42,3 @@ // @flow | ||
// the registered cache to know whether a style is global or not | ||
// also, note that this will be dead code eliminated in the browser | ||
// also, note that this check will be dead code eliminated in the browser | ||
(isBrowser === false && context.compat !== undefined)) && | ||
@@ -56,3 +56,5 @@ context.registered[`${context.key}-${insertable.name}`] === undefined | ||
if (!isBrowser) { | ||
if (isBrowser) { | ||
rules.forEach(context.sheet.insert, context.sheet) | ||
} else { | ||
let joinedRules = rules.join('') | ||
@@ -69,4 +71,2 @@ if (context.compat === undefined) { | ||
} | ||
} else { | ||
rules.forEach(context.sheet.insert, context.sheet) | ||
} | ||
@@ -73,0 +73,0 @@ } |
@@ -10,2 +10,3 @@ // @flow | ||
flush(): void; | ||
tags: Array<HTMLStyleElement>; | ||
} | ||
@@ -12,0 +13,0 @@ |
Sorry, the diff of this file is not supported yet
15357
263