Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reply with images #27

Closed
musashi-garami opened this issue Jun 2, 2023 · 4 comments
Closed

Reply with images #27

musashi-garami opened this issue Jun 2, 2023 · 4 comments
Labels
enhancement New feature or request

Comments

@musashi-garami
Copy link
Contributor

Feature request

Being able to display actual markdown would be cool, nice to have image links in the docs mdx files, and then ask gpt to try include markdown image links where appropriate.

I can get GPT to include the ![Alt text](URL or file path) images, but the response isn't actually displaying markdown.

@musashi-garami musashi-garami added the enhancement New feature or request label Jun 2, 2023
@musashi-garami
Copy link
Contributor Author

Anyone have any luck with being able to do this ? I've tried getting the a,i to add the <img tag into it's replies, but it's still just text.
Is this something that's possible?

@gregnr
Copy link
Contributor

gregnr commented Jul 19, 2023

Hey @musashi-garami, agreed it would be great to support markdown in this project. In the mean time, feel free to check out how we do this in the Supabase docs/dashboard using ReactMarkdown:

https://github.com/supabase/supabase/blob/5d457bdc7567db9a73a02a3d10e984a641f6cc3d/packages/ui/src/components/Command/AiCommand.tsx#L418-L435

@musashi-garami
Copy link
Contributor Author

Ok that looks perfect! But I'm struggling to install react-markdown. I normally use NPM but I see this builds with PNPM and vercel is not building, I'm assuming due to incorrect pnpm-lock.yaml file ? But I'm not experienced with PNPM, I installed latest PNPM, I tried to PNPM install react-markdown but didn't work.. so I NPM install react-markdown, but with my limited understanding it appears the pnpm-lock.yaml is not adding react-markdown as a dependency (which is failing the vercel build)

@musashi-garami
Copy link
Contributor Author

Nevermind, looks like PNPM wasn't working in VS code terminal due to windows permissions, i ran in admin powershell and it installed properly.

Then another build error, was passing {completion} as a children prop to react-markdown (as their docs describe) but ESLint rules is not happy with that so passed {completion} between the react markdown tags

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants