Add redirects for grid URL queries
This commit is contained in:
parent
c0890e6e96
commit
4d07eed3f4
1 changed files with 25 additions and 9 deletions
|
|
@ -13,19 +13,35 @@ module.exports = {
|
||||||
return [
|
return [
|
||||||
{
|
{
|
||||||
source: '/',
|
source: '/',
|
||||||
destination: '/new'
|
destination: '/new',
|
||||||
}
|
},
|
||||||
|
{
|
||||||
|
source: '/p/:shortcode/characters',
|
||||||
|
destination: '/p/:shortcode',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
source: '/p/:shortcode/weapons',
|
||||||
|
destination: '/p/:shortcode',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
source: '/p/:shortcode/summons',
|
||||||
|
destination: '/p/:shortcode',
|
||||||
|
},
|
||||||
|
{
|
||||||
|
source: '/p/:shortcode/:garbage',
|
||||||
|
destination: '/p/:shortcode',
|
||||||
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
webpack(config) {
|
webpack(config) {
|
||||||
config.module.rules.push({
|
config.module.rules.push({
|
||||||
test: /\.svg$/,
|
test: /\.svg$/,
|
||||||
use: ["@svgr/webpack"]
|
use: ['@svgr/webpack'],
|
||||||
});
|
})
|
||||||
config.module.rules[2].oneOf.forEach((one) => {
|
config.module.rules[2].oneOf.forEach((one) => {
|
||||||
if (!`${one.issuer?.and}`.includes('_app')) return;
|
if (!`${one.issuer?.and}`.includes('_app')) return
|
||||||
one.issuer.and = [path.resolve(__dirname)];
|
one.issuer.and = [path.resolve(__dirname)]
|
||||||
});
|
})
|
||||||
return config;
|
return config
|
||||||
},
|
},
|
||||||
};
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue