mirror of
https://github.com/Stone-Red-Code/website.git
synced 2026-09-06 07:56:11 +02:00
change path.join to path.posix.join ensuring path uses / not \
fixes the-programmers-hangout/website#214
This commit is contained in:
committed by
Jean-Philippe Sirois
parent
236f84db8c
commit
b0e6fbcd67
+3
-3
@@ -102,7 +102,7 @@ const createResources = async ({ createPage, graphql }) => {
|
|||||||
// create home page for each resources
|
// create home page for each resources
|
||||||
resources.forEach((resource) => {
|
resources.forEach((resource) => {
|
||||||
createPage({
|
createPage({
|
||||||
path: path.join("resources", resource),
|
path: path.posix.join("resources", resource),
|
||||||
component: resourceHome,
|
component: resourceHome,
|
||||||
context: {
|
context: {
|
||||||
resourceType: key,
|
resourceType: key,
|
||||||
@@ -114,7 +114,7 @@ const createResources = async ({ createPage, graphql }) => {
|
|||||||
|
|
||||||
query.data.allFile.edges.forEach(({ node }) => {
|
query.data.allFile.edges.forEach(({ node }) => {
|
||||||
createPage({
|
createPage({
|
||||||
path: path.join("resources", node.relativePath),
|
path: path.posix.join("resources", node.relativePath),
|
||||||
component: resourcePage,
|
component: resourcePage,
|
||||||
context: {
|
context: {
|
||||||
file: node.relativePath,
|
file: node.relativePath,
|
||||||
@@ -147,7 +147,7 @@ const createArchives = async ({ createPage, graphql }) => {
|
|||||||
|
|
||||||
return result.data.allFile.edges.forEach(({ node }) => {
|
return result.data.allFile.edges.forEach(({ node }) => {
|
||||||
createPage({
|
createPage({
|
||||||
path: path.join("archives", node.relativePath),
|
path: path.posix.join("archives", node.relativePath),
|
||||||
component: archive,
|
component: archive,
|
||||||
context: {
|
context: {
|
||||||
file: node.relativePath,
|
file: node.relativePath,
|
||||||
|
|||||||
Reference in New Issue
Block a user