const withImages = require('next-images'); const withFonts = require('next-fonts'); const withLess = require("next-with-less"); module.exports = withImages(withFonts(withLess({ images: { domains: [ 'evo-lk.quickcode.ru', 'wow.evoleasing.ru', 'www.evoleasing.ru', 'lk.evoleasing.ru', 'evoleasing.ru', 'localhost', 'localhost:3000'], }, reactStrictMode: true, /* async headers() { return [ { source: '/api/:path*', headers: [ { key: 'Access-Control-Allow-Origin', value: '*', }, { key: 'Access-Control-Allow-Methods', value: 'POST, GET, OPTIONS', } ], }, ] }, */ async redirects() { return [ //{ //source: '/special', //destination: '/special/with_producer', //permanent: true, //}, ] }, async rewrites() { return { afterFiles: [ { source: "/contract/:number/payments", destination: "/contract", }, { source: "/contract/:number/agreement", destination: "/contract/agreement", }, { source: "/contract/:number/services", destination: "/contract/services", }, { source: "/contract/:number/documents", destination: "/contract/documents", } //{ //source: "/about/reviews/:page(\\d{1,})", //destination: "/about/reviews", //}, ], } } })));