mirror of
https://github.com/MercuryWorkshop/dreamlandjs.git
synced 2025-05-15 15:10:02 -04:00
hopefully fix css hang
This commit is contained in:
parent
90d7cf7f85
commit
bd347052e9
2 changed files with 3 additions and 3 deletions
|
@ -24,7 +24,8 @@ export function css(strings, ...values) {
|
|||
let newstr = ''
|
||||
let selfstr = ''
|
||||
while (!styleElement.sheet.cssRules.length) {
|
||||
let [first, ...rest] = str.split('\n')
|
||||
let [first, ...rest] = str.split('\n');
|
||||
if (!first) break;
|
||||
selfstr += first + '\n'
|
||||
str = rest.join('\n')
|
||||
styleElement.textContent = str
|
||||
|
@ -36,7 +37,6 @@ export function css(strings, ...values) {
|
|||
}
|
||||
|
||||
styleElement.textContent = `.${uid} {${selfstr}}` + '\n' + newstr
|
||||
console.log(styleElement.textContent)
|
||||
|
||||
cssmap[str] = uid
|
||||
return uid
|
||||
|
|
|
@ -18,6 +18,6 @@
|
|||
|
||||
"noUncheckedIndexedAccess": true
|
||||
},
|
||||
"include": ["./examples/*.ts", "./examples/*.tsx", "./DreamlandJS.d.ts"],
|
||||
"include": ["./examples/*.ts", "./examples/*.tsx", "./dreamland.d.ts"],
|
||||
"exclude": ["node_modules/**/*"]
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue