next.config.mjs 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. /** @type {import('next').NextConfig} */
  2. import createNextIntlPlugin from "next-intl/plugin";
  3. const withNextIntl = createNextIntlPlugin();
  4. /** @type {import('next').NextConfig} */
  5. const nextConfig = {
  6. output: "standalone",
  7. reactStrictMode: false,
  8. env: {
  9. BUILD_ENV: process.env.BUILD_ENV,
  10. },
  11. transpilePackages: ["antd-mobile"],
  12. sassOptions: {
  13. quietDeps: true,
  14. prependData: `@import "./src/styles/variables.scss";`,
  15. },
  16. logging: {
  17. fetches: {
  18. fullUrl: true,
  19. },
  20. },
  21. experimental: {
  22. staleTimes: {
  23. dynamic: 0,
  24. static: 180,
  25. },
  26. scrollRestoration: true,
  27. optimizePackageImports: [
  28. "antd-mobile",
  29. "dayjs",
  30. "bignumber.js",
  31. "@lucky-canvas/react",
  32. "@number-flow/react",
  33. "framer-motion",
  34. "next-intl",
  35. ],
  36. },
  37. images: {
  38. domains: [
  39. "minio.tiktokjakjkl.icu",
  40. "bcwin.s3.sa-east-1.amazonaws.com",
  41. "192.168.0.237",
  42. "static.tiktokjakjkl.icu",
  43. ],
  44. remotePatterns: [
  45. {
  46. protocol: "https",
  47. hostname: "minio.tiktokjakjkl.icu",
  48. pathname: "*",
  49. },
  50. {
  51. protocol: "https",
  52. hostname: "images.hibigwin.com",
  53. pathname: "*",
  54. },
  55. {
  56. protocol: "https",
  57. hostname: "bcwin.s3.sa-east-1.amazonaws.com",
  58. pathname: "*",
  59. },
  60. {
  61. protocol: "https",
  62. hostname: "static.tiktokjakjkl.icu",
  63. pathname: "*",
  64. },
  65. ],
  66. },
  67. };
  68. export default withNextIntl(nextConfig);