forked from kasuie/remio-home
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnext.config.mjs
52 lines (48 loc) · 966 Bytes
/
next.config.mjs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/*
* @Author: kasuie
* @Date: 2024-05-20 16:08:41
* @LastEditors: kasuie
* @LastEditTime: 2024-06-02 19:49:21
* @Description:
*/
/** @type {import('next').NextConfig} */
import nextPWA from "next-pwa";
const isProd = process.env.NODE_ENV === "production";
const withPWA = nextPWA({
dest: "public",
register: true,
skipWaiting: true,
disable: !isProd,
});
const nextConfig = {
output: "standalone",
eslint: {
ignoreDuringBuilds: true,
},
webpack: (config, { isServer }) => {
if (!isServer) {
config.resolve.fallback = {
fs: false,
};
}
return config;
},
images: {
minimumCacheTTL: 60,
remotePatterns: [
{
protocol: "https",
hostname: "cdn.staticaly.com",
},
{
protocol: "https",
hostname: "cdn.jsdelivr.net",
},
{
protocol: "https",
hostname: "pixiv.re",
},
],
},
};
export default withPWA(nextConfig);