hakimel / reveal.js

The HTML Presentation Framework
https://revealjs.com
MIT License
67.91k stars 16.65k forks source link

Question: content from headless cms #2996

Open OperationalFallacy opened 3 years ago

OperationalFallacy commented 3 years ago

👋 I'm prototyping how to build presentations that pull content from headless CMS. Is there any API in reveal.js that can help with this? Something similar to API in slides.com, https://slides.com/developers#define-api - which solves the problem theoretically since I can convert responses from headless cms to deck json. I wanted to try a simple version and run everything locally since I want to experiment with content transformations. Cheers! Roman

OperationalFallacy commented 2 years ago

I figured it out: there is no APIs unfortunately However rendering slides is pretty easy with the content pulled from any CMS.

In a react component

return(
  {slides.map(slide) => (
    <div className={style.container}>
       <Presentation slides={slides} />
    </div>
  ))}
);