Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Possibility to block and entire <script>block? #42

Open
cryothic opened this issue Jul 4, 2023 · 3 comments
Open

Possibility to block and entire <script>block? #42

cryothic opened this issue Jul 4, 2023 · 3 comments
Labels
enhancement New feature or request

Comments

@cryothic
Copy link

cryothic commented Jul 4, 2023

Is it possible to block an entire <script> block like this?

If I add a block like this:
<script type="javascript/blocked"> (function(){ alert("loaded"); })() </script>
it isn't executed. But when I call .unblock() this whole block disappears.
We're working with a CMS where we don't know what scripts the author will add to a page.

@elbywan
Copy link
Owner

elbywan commented Jul 11, 2023

Hey @cryothic,

Is it possible to block an entire <script> block like this?

Unfortunately no, yett is meant to block script blocks having a src attribute and will not restore a script contents when unblocking.

@elbywan elbywan added the enhancement New feature or request label Jul 11, 2023
@cryothic
Copy link
Author

cryothic commented Jul 11, 2023 via email

@cryothic
Copy link
Author

cryothic commented Nov 17, 2023 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants