update
This commit is contained in:
+4
-7
@@ -1,10 +1,9 @@
|
||||
import {errorMessage, isFunction, loadResources} from './utils';
|
||||
|
||||
import {Loader, LoaderCallback} from '.';
|
||||
import type {Loader, LoaderCallback} from '.';
|
||||
|
||||
/* eslint-disable no-invalid-this */
|
||||
const loader: Loader = function(source) {
|
||||
this.cacheable && this.cacheable();
|
||||
const loader: Loader = function (source) {
|
||||
this.cacheable();
|
||||
|
||||
const callback = this.async();
|
||||
|
||||
@@ -17,9 +16,7 @@ const loader: Loader = function(source) {
|
||||
throw new Error(errorMessage.impossible);
|
||||
}
|
||||
|
||||
/* eslint-disable-next-line @typescript-eslint/no-floating-promises */
|
||||
loadResources(this, source, callback);
|
||||
void loadResources(this, source, callback);
|
||||
};
|
||||
/* eslint-enable no-invalid-this */
|
||||
|
||||
export default loader;
|
||||
|
||||
Reference in New Issue
Block a user