mirror of
https://github.com/primer/css.git
synced 2024-11-28 13:12:16 +03:00
add redirect from /objects/layout -> /objects/grid
This commit is contained in:
parent
e5c4062bf4
commit
b1a9d6d2c0
11
docs/gatsby-node.js
Normal file
11
docs/gatsby-node.js
Normal file
@ -0,0 +1,11 @@
|
||||
const redirects = {
|
||||
'/css/objects/layout': '/css/objects/grid',
|
||||
'/css/objects/layout/': '/css/objects/grid/'
|
||||
}
|
||||
|
||||
exports.createPages = ({actions: {createRedirect}}) => {
|
||||
for (const [fromPath, toPath] of Object.entries(redirects)) {
|
||||
// console.warn(`[redirect] ${fromPath} → ${toPath}`)
|
||||
createRedirect({fromPath, toPath, redirectInBrowser: true})
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user