From the course: Building a React Project with Google Bard and the PalM2 API

Unlock the full course today

Join today to access over 24,100 courses taught by industry experts.

Displaying clean markdown

Displaying clean markdown

- [Instructor] Palm can handle table output. So if I type in a query right here, "table of top 20 dogs by longevity and energy" what we're going to get is a table that is in the markdown format. So it'd be really nice to be able to see that in a nicely formatted HTML way. In order to do that we're going to need to load up a couple of modules. So I want to make sure that I'm in the client folder. So I'll do a press and work in directory, here. And I am in the client, so I'm going to need to install a couple of modules. I'm going to install one called marked, which can take care of markdown conversion. And I'm also going to include another one called dompurify. This is just a safety module that will convert HTML to make sure that it is clean HTML and there're no code injections or anything weird in the HTML. So I'll get those too. Let's go ahead and clear that out. And once I have that installed then I'm…

Contents