fix: set nodeModulesDir to manual (#3493)
Hopefully a less invasive fix for #3378 --------- Co-authored-by: Marvin Hagemeister <hello@marvinh.dev>
This commit is contained in:
co-authored by
Marvin Hagemeister
parent
f82bd7e63d
commit
f7a2422e93
@@ -8,11 +8,13 @@ import {
|
||||
} from "@deno/loader";
|
||||
import * as path from "@std/path";
|
||||
import * as babel from "@babel/core";
|
||||
import babelReact from "@babel/preset-react";
|
||||
import { httpAbsolute } from "./patches/http_absolute.ts";
|
||||
import { JS_REG, JSX_REG } from "../utils.ts";
|
||||
import { builtinModules } from "node:module";
|
||||
|
||||
// @ts-ignore Workaround for https://github.com/denoland/deno/issues/30850
|
||||
const { default: babelReact } = await import("@babel/preset-react");
|
||||
|
||||
const BUILTINS = new Set(builtinModules);
|
||||
|
||||
interface DenoState {
|
||||
|
||||
@@ -2,12 +2,14 @@ import type { Plugin } from "vite";
|
||||
import * as babel from "@babel/core";
|
||||
import { cjsPlugin } from "./patches/commonjs.ts";
|
||||
import { jsxComments } from "./patches/jsx_comment.ts";
|
||||
import babelReact from "@babel/preset-react";
|
||||
import { inlineEnvVarsPlugin } from "./patches/inline_env_vars.ts";
|
||||
import { removePolyfills } from "./patches/remove_polyfills.ts";
|
||||
import { JS_REG, JSX_REG } from "../utils.ts";
|
||||
import { codeEvalPlugin } from "./patches/code_eval.ts";
|
||||
|
||||
// @ts-ignore Workaround for https://github.com/denoland/deno/issues/30850
|
||||
const { default: babelReact } = await import("@babel/preset-react");
|
||||
|
||||
export function patches(): Plugin {
|
||||
let isDev = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user