4
0
forked from crowetic/commerce
commerce/next.config.js

49 lines
1.1 KiB
JavaScript
Raw Normal View History

2020-10-26 10:49:21 -03:00
module.exports = {
images: {
2020-10-21 22:02:02 -05:00
sizes: [320, 480, 820, 1200, 1600],
2020-10-22 20:59:45 -05:00
domains: ['cdn11.bigcommerce.com'],
},
2020-10-24 16:10:31 -05:00
experimental: {
i18n: {
locales: ['en-US', 'es'],
defaultLocale: 'en-US',
},
2020-10-24 10:34:36 -05:00
},
2020-10-13 18:52:02 -05:00
rewrites() {
return [
2020-10-26 11:51:59 -05:00
{
source: '/:locale/search',
destination: '/search',
},
{
source: '/:locale/search/:path*',
destination: '/search',
},
2020-10-13 18:52:02 -05:00
{
source: '/search/designers/:name',
destination: '/search',
},
{
source: '/search/designers/:name/:category',
destination: '/search',
},
2020-10-26 11:08:20 -05:00
// Search
2020-10-13 18:52:02 -05:00
{
// This rewrite will also handle `/search/designers`
source: '/search/:category',
destination: '/search',
},
2020-10-14 19:23:42 -05:00
{
source: '/checkout',
destination: '/api/bigcommerce/checkout',
},
2020-10-22 18:02:41 -05:00
// The logout is also an action so this route is not required, but it's also another way
// you can allow a logout!
{
source: '/logout',
destination: '/api/bigcommerce/customers/logout?redirect_to=/',
},
2020-10-13 18:52:02 -05:00
]
},
2020-10-26 10:49:21 -03:00
}