fix(core): update
This commit is contained in:
parent
bb64a8ecac
commit
94c6c5a525
@ -3,6 +3,6 @@
|
|||||||
*/
|
*/
|
||||||
export const commitinfo = {
|
export const commitinfo = {
|
||||||
name: '@designestate/dees-domtools',
|
name: '@designestate/dees-domtools',
|
||||||
version: '2.0.29',
|
version: '2.0.30',
|
||||||
description: 'tools to simplify complex css structures'
|
description: 'tools to simplify complex css structures'
|
||||||
}
|
}
|
||||||
|
@ -149,12 +149,12 @@ export class DomTools {
|
|||||||
* allows to set global styles
|
* allows to set global styles
|
||||||
* @param stylesText the css text you want to set
|
* @param stylesText the css text you want to set
|
||||||
*/
|
*/
|
||||||
public async setExternalScript(scriptLinkArg: string) {
|
public async setExternalScript(scriptLinkArg: string) {
|
||||||
await this.domReady.promise;
|
await this.domReady.promise;
|
||||||
const done = plugins.smartpromise.defer();
|
const done = plugins.smartpromise.defer();
|
||||||
const script = document.createElement('script')
|
const script = document.createElement('script');
|
||||||
script.src = scriptLinkArg;
|
script.src = scriptLinkArg;
|
||||||
script.addEventListener('load', function() {
|
script.addEventListener('load', function () {
|
||||||
done.resolve();
|
done.resolve();
|
||||||
});
|
});
|
||||||
const parentNode = document.head || document.body;
|
const parentNode = document.head || document.body;
|
||||||
|
Loading…
Reference in New Issue
Block a user