Unable to run jquery code


I'm trying to run jquery code. For test on how to do it, I'm trying with this simple code:


I've created the page structure inside bootstrap studio, then created a button using custom code:

< button > Click me to hide paragraphs < /button >

and then inserted de jquery code in another custom code component:

< script > $(document).ready(function(){ $("button").click(function(){ $("p").hide(); }); }); < /script >

Here is the published site: https://jquerytest.firebaseapp.com/ the code doesn´t work!

What I´m doing wrong?

I guess I missing something very basic here, so I apologize for that!

Thanks in advance!!!

enter image description here