# treating observablejs as javascript library in react

**URL:** <https://talk.observablehq.com/t/treating-observablejs-as-javascript-library-in-react/7896>\
**Category:** Help\
**Created:** [April 30, 2023, 1:13pm UTC](https://talk.observablehq.com/t/treating-observablejs-as-javascript-library-in-react/7896 "2023-04-30T13:13:48Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![strangeattractor](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/strangeattractor/32/7709_2.png) [@strangeattractor](https://talk.observablehq.com/u/strangeattractor)\
**Post date:** [April 30, 2023, 1:13pm UTC](https://talk.observablehq.com/t/treating-observablejs-as-javascript-library-in-react/7896/1 "2023-04-30T13:13:48Z")

</div>

Hey, i really like using Observable in quarto via the ojs chunks and would like to do something similar in react. I know it is possible to embed observable notebooks but is there any way to use observablejs like a javascript library i.e. write and import ojs modules in local files?

---

<div class="post-metadata">

**Author:** ![Cobus](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.observablehq.com/cobus/32/9670_2.png) [@Cobus](https://talk.observablehq.com/u/Cobus)\
**Post date:** [May 1, 2023, 2:51pm UTC](https://talk.observablehq.com/t/treating-observablejs-as-javascript-library-in-react/7896/2 "2023-05-01T14:51:00Z")

</div>

Not that I am aware of. The [embedding](https://observablehq.com/@observablehq/embeds) code provided by Observable uses the Runtime and the Inspector to execute compiled JS code and render it in a DOM element. What tools like Quarto are doing goes beyond that, including a compiler etc.

Perhaps others in the community have experimented with this, though.
