kobaltedev / kobalte

A UI toolkit for building accessible web apps and design systems with SolidJS.
https://kobalte.dev
MIT License
1.22k stars 62 forks source link

Breadcrumbs component fails with an error related to i18n #248

Closed hansoksendahl closed 1 year ago

hansoksendahl commented 1 year ago

Describe the bug When using the breadcrumb component with ssr: true there is an error related to i18n.

(0 , $1DoQa$intlmessageformat) is not a constructor

To Reproduce

Expected behavior A clear and concise description of what you expected to happen.

I would expect the breadcrumb component to render as expected.

Screenshots If applicable, add screenshots to help explain your problem.

image

Desktop (please complete the following information):

Additional context This only occurs in SSR mode. If you set SSR mode to false it works as expected.

Please note I already followed the instructions for SSR rendering with kobalte.

hansoksendahl commented 1 year ago

I found the fix. You have to add @internationalized/message to the ssr.noExternal array in vite.config.ts

apollo79 commented 1 year ago

If it is not possible to fix this on kobalte's side, this should be added to the docs IMO.