Help with JQuery on vscode

I have this JQuery block of code that I am sure it works because I implemented it on codepen and it works. The problem is I don’t know how to implement/link/reference (sorry I don’t even know the right grammar for that but I hope someone understands) it on vscode (like you do with css and js).
PLEASE help with the steps I need to follow to get the jquery code to run on my html file

jquery is a javascript library

put your jquery code in a js file, and link that in your html plus above that, import the jquery library

Put this tag into your html head, ABOVE the link to your own script:

<script src=""></script>

This link explains it further:

I have tried it but its not working…
Don’t know what I’m doing wrong.

Can you share your code? Otherwise it’s difficult to help.


    <meta charset="UTF-8">

    <meta name="viewport" content="user-scalable=0, width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">

    <title>Belle &amp; Carrie Rehabilitation Yoga Web Template</title>

    <script src=""></script>

    <script src="myown-template.js"></script>

    <link rel="stylesheet" type="text/css" href="myown-template.css">

    <script src="" crossorigin="anonymous"></script>


The jquery file is in the js file.

This looks like you’ve got the correct script tags.

Is myown-template.js in the same folder as your index.html, or in a subfolder somewhere?
If it’s in a subfolder, you need to change your src attribute to the correct path:

Does you myown-template.js do anything at all , or does it just complain about unknown jQuery Syntax?

You can test that if you console.log something in your myown-template.js file.
console.log('test') for example. Do you see it logged in your browser console?