fix(core): update

This commit is contained in:
Philipp Kunz 2020-05-23 16:55:36 +00:00
parent 9b3c92fef5
commit ecb387f59e
5 changed files with 10 additions and 4 deletions

View File

@ -0,0 +1,5 @@
export class DeesDomTools {
public static createDomTools = () => {
globalThis.deesDomTools = new DeesDomTools();
}
}

View File

@ -13,7 +13,7 @@ export const elementBasicSetup = async () => {
// lets make sure the dom is ready
const documentReady = defer();
document.onreadystatechange = () => {
const readyStateChangedFunc = () => {
if (document.readyState === 'interactive' || document.readyState === 'complete') {
console.log('elementBasicSetup: element basic setup complete')
documentReady.resolve();
@ -21,6 +21,7 @@ export const elementBasicSetup = async () => {
console.log('elementBasicSetup: document not yet ready');
}
};
document.addEventListener('readystatechange', readyStateChangedFunc);
console.log('elementBasicSetup: waiting for document to be ready');
await documentReady.promise;
console.log('elementBasicSetup: document ready!');

View File

@ -1,7 +1,7 @@
export * from './csstools.elementbasicsetup';
export * from './csstools.elementbasicstyles';
export * from './domtools.elementbasicsetup';
export * from './domtools.elementbasicstyles';
import * as breakpoints from './csstools.breakpoints';
import * as breakpoints from './domtools.breakpoints';
export {
breakpoints