mirror of
https://github.com/beilunyang/moemail.git
synced 2026-09-05 07:16:39 +08:00
feat: Init
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
import type { NextConfig } from "next";
|
||||
import withPWA from 'next-pwa'
|
||||
import { setupDevPlatform } from '@cloudflare/next-on-pages/next-dev';
|
||||
|
||||
async function setup() {
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
await setupDevPlatform()
|
||||
}
|
||||
}
|
||||
|
||||
setup()
|
||||
|
||||
const nextConfig: NextConfig = {
|
||||
images: {
|
||||
remotePatterns: [
|
||||
{
|
||||
protocol: 'https',
|
||||
hostname: 'avatars.githubusercontent.com',
|
||||
},
|
||||
],
|
||||
},
|
||||
};
|
||||
|
||||
export default withPWA({
|
||||
dest: 'public',
|
||||
register: true,
|
||||
skipWaiting: true,
|
||||
disable: process.env.NODE_ENV === 'development',
|
||||
// @ts-expect-error "ignore the error"
|
||||
})(nextConfig);
|
||||
Reference in New Issue
Block a user