Closed RiverKy closed 2 months ago
> astro build && pagefind --site dist
3:17:39 PM [vite] Error when evaluating SSR module /Users/SkyYkb/Documents/Kais-Blog.nosync/astro.config.mjs: failed to import "astro-icon"
|- file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/@iconify/tools/lib/svg/index.mjs:1
import cheerio from 'cheerio';
^^^^^^^
SyntaxError: The requested module 'cheerio' does not provide an export named 'default'
at ModuleJob._instantiate (node:internal/modules/esm/module_job:171:21)
at async ModuleJob.run (node:internal/modules/esm/module_job:254:5)
at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:482:26)
at async nodeImport (file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/vite/dist/node/chunks/dep-BzOvws4Y.js:52954:15)
at async ssrImport (file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/vite/dist/node/chunks/dep-BzOvws4Y.js:52812:16)
at async eval (/Users/SkyYkb/Documents/Kais-Blog.nosync/astro.config.mjs:8:31)
at async instantiateModule (file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/vite/dist/node/chunks/dep-BzOvws4Y.js:52870:5)
[astro] Unable to load your Astro config
The requested module 'cheerio' does not provide an export named 'default'
Stack trace:
at ModuleJob._instantiate (node:internal/modules/esm/module_job:171:21)
at async onImport.tracePromise.__proto__ (node:internal/modules/esm/loader:482:26)
at async ssrImport (file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/vite/dist/node/chunks/dep-BzOvws4Y.js:52812:16)
at async instantiateModule (file:///Users/SkyYkb/Documents/Kais-Blog.nosync/node_modules/vite/dist/node/chunks/dep-BzOvws4Y.js:52870:5)
ELIFECYCLE Command failed with exit code 1.
The first output (that src/pages/about.astro
one) is shown when building with Cloudflare Pages. And the second one (Error when evaluating SSR module
) is shown when building locally. Not powerful enough for me to figure out what happened. Please help. Thanks.
looks kind of like #158, did you pnpm update?
pnpm update
does solve the Error when evaluating SSR module
error, while the src/pages/about.astro
error is now appearing on my computer.
Thanks.
Please check your src/config.ts
to see if any configuration items are missing.
Problem solved after adding some items in src/config.ts
. Updating Astro themes is really a tough job...
Thank you so much!
Getting this when trying to generate output.
Thank you.