EvoCalculator.Client2/next.config.js
Chika a978969aa1 antd: support react 18
fix empty InputNumber value bug
2022-05-19 15:20:32 +03:00

49 lines
973 B
JavaScript

const withPlugins = require('next-compose-plugins');
const withLess = require('next-with-less');
const withGraphQL = require('next-plugin-graphql');
/** @type {import('next').NextConfig} */
const nextConfig = {
reactStrictMode: false,
eslint: {
ignoreDuringBuilds: true,
},
compiler: {
styledComponents: true,
},
async rewrites() {
return [
{
source: process.env.NEXT_PUBLIC_URL_CRM_GRAPHQL_PROXY,
destination: process.env.URL_CRM_GRAPHQL_DIRECT,
},
];
},
experimental: {
modularizeImports: {
lodash: {
transform: 'lodash/{{member}}',
preventFullImport: true,
},
},
},
};
const plugins = [
[
withLess,
{
lessLoaderOptions: {
lessOptions: {
modifyVars: {
'primary-color': process.env.NEXT_PUBLIC_COLOR_PRIMARY,
},
},
},
},
],
[withGraphQL],
];
module.exports = withPlugins(plugins, nextConfig);