build: drop @types/webpack-env in favor of webpack/module types (#48015)
* build: drop @types/webpack-env in favor of webpack/module types Co-authored-by: David Sanders <dsanders11@ucsbalum.com> * chore: improve type when assigning to global.require Co-authored-by: David Sanders <dsanders11@ucsbalum.com> --------- Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: David Sanders <dsanders11@ucsbalum.com>
This commit is contained in:
parent
095ae30f6d
commit
cea5034019
10 changed files with 24 additions and 25 deletions
|
@ -204,7 +204,7 @@ delete process.appCodeLoaded;
|
|||
if (packagePath) {
|
||||
// Finally load app's main.js and transfer control to C++.
|
||||
if ((packageJson.type === 'module' && !mainStartupScript.endsWith('.cjs')) || mainStartupScript.endsWith('.mjs')) {
|
||||
const { runEntryPointWithESMLoader } = __non_webpack_require__('internal/modules/run_main');
|
||||
const { runEntryPointWithESMLoader } = __non_webpack_require__('internal/modules/run_main') as typeof import('@node/lib/internal/modules/run_main');
|
||||
const main = (require('url') as typeof url).pathToFileURL(path.join(packagePath, mainStartupScript));
|
||||
runEntryPointWithESMLoader(async (cascadedLoader: any) => {
|
||||
try {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue