chore: fix type

This commit is contained in:
hardfist 2024-07-24 17:50:12 +08:00
parent 7adad563d1
commit d35868b6ef
5 changed files with 3 additions and 46 deletions

View file

@ -1,16 +0,0 @@
const { StatsWriterPlugin } = require('webpack-stats-plugin')
module.exports = {
webpack: (config, options) => {
config.optimization.minimize = false;
config.optimization.moduleIds = 'named';
config.optimization.chunkIds = 'named';
config.stats = {all:true};
config.plugins.push(new StatsWriterPlugin({
filename: 'stats.json',
stats: {
all:true
}
}))
return config;
},
}

View file

@ -1,26 +0,0 @@
import Link from 'next/link'
import NextError from 'next/error'
import React from 'react'
export default class Error extends React.Component {
static getInitialProps(ctx) {
const { statusCode } = NextError.getInitialProps(ctx)
return { statusCode: statusCode || null }
}
render() {
return (
<div>
<div id="errorStatusCode">{this.props.statusCode || 'unknown'}</div>
<p>
<Link href="/" id="errorGoHome">
go homewkkwjkjj
</Link>
</p>
</div>
)
}
}
Error.getInitialProps = (props) => {
return {}
}

View file

@ -29,7 +29,7 @@ export const base = curry(function base(
// original source, including columns and original variable names.
// This is desirable so the in-browser debugger can correctly pause
// and show scoped variables with their original names.
config.devtool = false;
config.devtool = 'eval-source-map'
}
} else {
if (

View file

@ -1164,6 +1164,7 @@ export default class HotReloaderWebpack implements NextJsHotReloaderInterface {
// mod,
// chunk.runtime
// )
const hash = mod.identifier()
if (
mod.layer === WEBPACK_LAYERS.reactServerComponents &&
@ -1172,7 +1173,7 @@ export default class HotReloaderWebpack implements NextJsHotReloaderInterface {
chunksHashServerLayer.add(hash)
}
chunksHash.add(mod.identifier())
chunksHash.add(hash)
// Both CSS import changes from server and client
// components are tracked.

View file

@ -2,5 +2,3 @@ packages:
- 'packages/*'
- 'bench/*'
- 'packages/next-swc/crates/next-core/js'
- 'examples/next-css'
- 'examples/netlify-blog'