-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathnext.config.js
62 lines (58 loc) · 1.59 KB
/
next.config.js
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
53
54
55
56
57
58
59
60
61
62
//const withPlugins = require("next-compose-plugins");
//const withCSS = require('@zeit/next-css')
// module.exports = withPlugins([withCSS], {
// reactStrictMode: true,
// });
// module.exports = withCSS({
// webpack: config => {
// /*config.module.rules.push({
// test: /\.(png|svg|jpg|gif)$/,
// use: ["file-loader"]
// });*/
// config.module.rules.push({
// test: /\.(jpg|png|woff|woff2|eot|ttf|svg)$/,
// //loader: 'url-loader?limit=100000'
// })
// config.module.rules.push({
// test: /\.css$/i,
// use: ['style-loader', 'css-loader'],
// });
// return config;
// },
// transpilePackages: ["@nivo"],
// experimental: { esmExternals: "loose" }
// })
module.exports = {
async rewrites() {
return [
{
source: '/api/:path*',
destination: 'http://localhost:8888/:path*' // Proxy to Backend
},
{
source: '/static/:path*',
destination: 'http://localhost:8889/assets/:path*' // Proxy to Backend
},
{
source: '/date/tender',
destination: `/date/tender/0`, // Proxy to Backend
},
{
source: '/date/award',
destination: `/date/award/0`,
},
{
source: '/units',
destination: `/units/0`,
},
{
source: '/stats/:unit*',
destination: `/stats`,
},
// {
// source: '/keyword/:keyword*',
// destination: '/search/?keyword=:keyword*' // Proxy to Backend
// }
]
}
}