diff options
| author | 2023-11-03 21:25:40 +0800 | |
|---|---|---|
| committer | 2023-11-03 21:25:40 +0800 | |
| commit | 9029588590bea8b10451575c5142dcde77ecd1b5 (patch) | |
| tree | 04cf8aee56c23fd225ff19d340f7cee621d874ef /packages/turbo-tracing-next-plugin/src | |
| parent | 94071d7ce16c56641d67d488e2bac6be84ffe731 (diff) | |
| download | HydroRoll-9029588590bea8b10451575c5142dcde77ecd1b5.tar.gz HydroRoll-9029588590bea8b10451575c5142dcde77ecd1b5.zip | |
chore: delete useless files
Diffstat (limited to 'packages/turbo-tracing-next-plugin/src')
| -rw-r--r-- | packages/turbo-tracing-next-plugin/src/index.ts | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/packages/turbo-tracing-next-plugin/src/index.ts b/packages/turbo-tracing-next-plugin/src/index.ts deleted file mode 100644 index 0b75113..0000000 --- a/packages/turbo-tracing-next-plugin/src/index.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { - NodeModuleTracePlugin, - NodeModuleTracePluginOptions, -} from "@vercel/webpack-nft"; -import type { NextConfig } from "next"; - -export function createNodeFileTrace(options?: NodeModuleTracePluginOptions) { - return function withNodeFileTrace(config: NextConfig = {}) { - const createWebpackConfig = config.webpack; - config.outputFileTracing = false; - config.webpack = (webpackConfig, context) => { - const config = - createWebpackConfig?.(webpackConfig, context) ?? webpackConfig; - if (context.isServer && !context.dev) { - const plugin = new NodeModuleTracePlugin(options); - if (config.plugins) { - config.plugins.push(plugin); - } else { - config.plugins = [plugin]; - } - } - - return config; - }; - return config; - }; -} |
