add TODOs
This commit is contained in:
parent
abbb6bb634
commit
a6e1c0693c
|
@ -30,7 +30,7 @@ class FunctionModuleTemplatePlugin {
|
|||
args.push(module.exportsArgument);
|
||||
if (
|
||||
module.hasDependencies(d => {
|
||||
const depAsAny = /** @type {any} */ (d);
|
||||
const depAsAny = /** @type {TODO} */ (d);
|
||||
return depAsAny.requireWebpackRequire !== false;
|
||||
})
|
||||
) {
|
||||
|
|
|
@ -535,7 +535,7 @@ class NormalModule extends Module {
|
|||
});
|
||||
// TODO remove cast when webpack-sources types are fixed
|
||||
// CachedSource is not a Source?
|
||||
const fixedSource = /** @type {any} */ (cachedSource);
|
||||
const fixedSource = /** @type {TODO} */ (cachedSource);
|
||||
return fixedSource;
|
||||
}
|
||||
|
||||
|
|
|
@ -576,7 +576,7 @@ class Stats {
|
|||
return 0;
|
||||
})
|
||||
.map(reason => {
|
||||
const depAsAny = /** @type {any} */ (reason.dependency);
|
||||
const depAsAny = /** @type {TODO} */ (reason.dependency);
|
||||
const obj = {
|
||||
moduleId: reason.originModule ? reason.originModule.id : null,
|
||||
moduleIdentifier: reason.originModule
|
||||
|
|
|
@ -50,7 +50,7 @@ class WasmFinalizeExportsPlugin {
|
|||
)
|
||||
) {
|
||||
// 4. error
|
||||
/** @type {any} */
|
||||
/** @type {TODO} */
|
||||
const error = new UnsupportedWebAssemblyFeatureError(
|
||||
`Export "${name}" with ${
|
||||
jsIncompatibleExports[name]
|
||||
|
|
|
@ -396,7 +396,7 @@ class WebAssemblyGenerator extends Generator {
|
|||
const source = module.originalSource().source();
|
||||
// TODO remove this casts when webpack-sources is fixed
|
||||
// source() should have return type (string | Buffer)
|
||||
const sourceAsAny = /** @type {any} */ (source);
|
||||
const sourceAsAny = /** @type {TODO} */ (source);
|
||||
let bin = /** @type {ArrayBuffer} */ (sourceAsAny);
|
||||
bin = preprocess(bin);
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@ class WebAssemblyJavascriptGenerator extends Generator {
|
|||
const initParams = [];
|
||||
let index = 0;
|
||||
for (const dep of module.dependencies) {
|
||||
const depAsAny = /** @type {any} */ (dep);
|
||||
const depAsAny = /** @type {TODO} */ (dep);
|
||||
if (moduleGraph.getModule(dep)) {
|
||||
let importData = importedModules.get(moduleGraph.getModule(dep));
|
||||
if (importData === undefined) {
|
||||
|
|
|
@ -325,7 +325,7 @@ class JsonpMainTemplatePlugin {
|
|||
);
|
||||
mainTemplate.hooks.requireEnsure.tap(
|
||||
// TODO typing are broken
|
||||
/** @type {any} */ ({
|
||||
/** @type {TODO} */ ({
|
||||
name: "JsonpMainTemplatePlugin preload",
|
||||
stage: 10
|
||||
}),
|
||||
|
|
|
@ -75,8 +75,8 @@ for (const sourceFile of program.getSourceFiles()) {
|
|||
member.name.getText()
|
||||
);
|
||||
if (baseDecl) {
|
||||
const memberAsAny = /** @type {any} */ (member);
|
||||
const baseDeclAsAny = /** @type {any} */ (baseDecl);
|
||||
const memberAsAny = /** @type {TODO} */ (member);
|
||||
const baseDeclAsAny = /** @type {TODO} */ (baseDecl);
|
||||
const currentJsDoc = memberAsAny.jsDoc && memberAsAny.jsDoc[0];
|
||||
const baseJsDoc = baseDeclAsAny.jsDoc && baseDeclAsAny.jsDoc[0];
|
||||
const currentJsDocText =
|
||||
|
|
Loading…
Reference in New Issue