# Scripts in posts?

**URL:** <https://meta.discourse.org/t/scripts-in-posts/361009>\
**Category:** Support\
**Created:** [April 9, 2025, 6:39am UTC](https://meta.discourse.org/t/scripts-in-posts/361009 "2025-04-09T06:39:17Z")\
**Posts on this page:** 1\
**Showing post:** 12

<div class="post-metadata">

**Author:** ![supermathie](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/supermathie/32/507518_2.png) [@supermathie](https://meta.discourse.org/u/supermathie)\
**Post date:** [April 10, 2025, 9:33pm UTC](https://meta.discourse.org/t/scripts-in-posts/361009/12 "2025-04-10T21:33:53Z")

</div>

> [@Olle11](#):
>
> Can I use a theme or a theme component to add script to a post?

You could. The script itself would need to sit outside of the post, or perhaps you could have it decorate specific aspects of posts.

It’s hard to know exactly what you want without specifics.

> [@Olle11](#):
>
> How can I include ‘unsafe-inline’ in the CSP to make the script work?

This is a bad idea and you should not do it.

---

_[View the full topic](https://meta.discourse.org/t/scripts-in-posts/361009)._
