# Which library do you recommend to add OSC communication to p5js?

**URL:** <https://discourse.processing.org/t/which-library-do-you-recommend-to-add-osc-communication-to-p5js/44420>\
**Category:** Libraries\
**Created:** [May 13, 2024, 7:48am UTC](https://discourse.processing.org/t/which-library-do-you-recommend-to-add-osc-communication-to-p5js/44420 "2024-05-13T07:48:53Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![GoToLoop](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/gotoloop/32/86_2.png) [@GoToLoop](https://discourse.processing.org/u/GoToLoop)\
**Post date:** [May 15, 2024, 11:28am UTC](https://discourse.processing.org/t/which-library-do-you-recommend-to-add-osc-communication-to-p5js/44420/7 "2024-05-15T11:28:24Z")

</div>

> [@Help extending p5 and dependencies in web dev](https://discourse.processing.org/t/help-extending-p5-and-dependencies-in-web-dev/44421/3):
>
> Here’s a simple template that makes p5 globally available, but still controls when p5 is instantiated: index.html: \<script defer src=//cdn.JsDelivr.net/npm/p5\>\</script\> \<script type=module src=index.mjs\>\</script\> index.mjs: import runSketch from './sketch.mjs'; runSketch(); // Invoke this after all the rest is ready! sketch.mjs: export default function runSketch() { // Make p5.js callbacks globally visible: globalThis.preload = preload; globalThis.setup = setup; globalThis.draw = d…

---

_[View the full topic](https://discourse.processing.org/t/which-library-do-you-recommend-to-add-osc-communication-to-p5js/44420)._
