Skip to content

Conversation

@JackDra
Copy link

@JackDra JackDra commented Nov 30, 2021

Summary

For some reason, I was getting a formatting error when building and previewing the docs.
Looked into the parsing, and got it working by replacing the regex with just a line split.
I was working on windows, so maybe its a file read utf-8 issue...?

Traceback

Error: 01-getting-started missing frontmatter
    at file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/index.json-905369c5.js:21:15
    at Array.map (<anonymous>)
    at get (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/index.json-905369c5.js:15:31)
    at render_endpoint (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:94:26)
    at async resolve (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:1257:56)
    at async respond (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:1240:12)
    at async fetch (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:736:28)
    at async load (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/__layout-69fd640b.js:58:20)
    at async load_node (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:819:14)
    at async respond$1 (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:941:22)
SyntaxError: Unexpected number in JSON at position 1
    at JSON.parse (<anonymous>)
    at Proxy.<anonymous> (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:801:31)
    at async load (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/__layout-69fd640b.js:58:20)
    at async load_node (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:819:14)
    at async respond$1 (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:941:22)
    at async render_page (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:1070:20)
    at async resolve (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:1257:104)
    at async respond (file:///E:/coding/svelte-cubed/.svelte-kit/output/server/chunks/app-6dccf0a2.js:1240:12)
    at async visit (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:167:20)
    at async visit (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:293:6)
> 500 /docs/getting-started (linked from /)
Error: 500 /docs/getting-started (linked from /)
    at file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:86:11
    at visit (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:222:5)
    at async visit (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:293:6)
    at async prerender (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:303:6)
    at async Object.prerender (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:368:4)
    at async adapt (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected]/node_modules/@sveltejs/adapter-static/index.js:13:4)
    at async adapt (file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/chunks/index4.js:393:2)
    at async file:///E:/coding/svelte-cubed/node_modules/.pnpm/@[email protected][email protected]/node_modules/@sveltejs/kit/dist/cli.js:896:5ELIFECYCLECommand failed with exit code 1.

@vercel
Copy link

vercel bot commented Nov 30, 2021

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/svelte/svelte-cubed/9cvqZX7UEvdZaREoqYBZM7e7kJKT
✅ Preview: https://svelte-cubed-git-fork-jackdra-fix-docsbuild-svelte.vercel.app

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant