13point5 / open-artifacts-renderer

https://open-artifacts-renderer.vercel.app
17 stars 7 forks source link

Question about creating React components with shadcn ui #2

Closed pierrerognion closed 1 month ago

pierrerognion commented 1 month ago

Hello @13point5 !

First of all, I want to express my sincere appreciation for your incredible work on this project. It's truly amazing to have the ability to create artifacts with any model. I've been having a blast turning it into a sort of V0 for building React components using shadcn ui.

I've encountered some challenges while trying to create certain components, and I'd love to get your insights. Specifically, when attempting to create a calendar component, I'm receiving the following error in the console:

23-40fb8718a3be5ba2.js:1 Error evaluating component code: SyntaxError: Cannot use import statement outside a module at Function (<anonymous>) at aB (page-0ae740dfa492b4db.js:1:67870) at page-0ae740dfa492b4db.js:1:69234 at aW (fd9d1056-c2c0f0799e533287.js:1:73243) at oe (fd9d1056-c2c0f0799e533287.js:1:84684) at ol (fd9d1056-c2c0f0799e533287.js:1:85322) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:85302) at or (fd9d1056-c2c0f0799e533287.js:1:85206) at ol (fd9d1056-c2c0f0799e533287.js:1:86267)

I'm curious if you might have any thoughts on what could be causing this issue? Is there perhaps a specific way to structure the imports when creating React components in this context?

I'd be more than happy to provide any additional information or context that might be helpful in diagnosing the problem. Your guidance would be incredibly valuable as I continue exploring the capabilities of your project.

Thank you so much for your time and for creating such an innovative tool. I'm excited to learn more and potentially contribute to its development in the future!

Best regards, Pierre

13point5 commented 1 month ago

Hi @pierrerognion

Thank you for your kind message. I'm no longer actively maintaining this project so feel free to fork the repos and continue working on it. If you're looking for something that just works there's Fragments by E2B because they support more than just react apps.