Skip to content

Commit 64fc01d

Browse files
authored
Alternate bundler: add index.d.ts types to plugin (#77144)
This allows the plugin to be used with typescript next.config.ts configs. Test Plan: import type { NextConfig } from 'next' import withRspack from '@next/plugin-rspack' const nextConfig: NextConfig = { experimental: { inlineCss: true, ppr: true, useLightningcss: true, }, reactStrictMode: true, } export default withRspack(nextConfig)
1 parent d41d035 commit 64fc01d

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed
+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import type { NextConfig } from 'next'
2+
3+
declare function NextPluginRspack(config: NextConfig): NextConfig
4+
5+
export = NextPluginRspack

packages/next-plugin-rspack/package.json

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"url": "vercel/next.js",
66
"directory": "packages/next-plugin-rspack"
77
},
8+
"types": "index.d.ts",
89
"dependencies": {
910
"@rspack/core": "npm:@rspack-canary/[email protected]",
1011
"@rspack/plugin-react-refresh": "1.0.1"

0 commit comments

Comments
 (0)