Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

JavaScript JavaScript Loops, Arrays and Objects Tracking Multiple Items with Arrays Adding Data to Arrays

JORGE HERRANDO GARIJO
JORGE HERRANDO GARIJO
7,895 Points

File path

My li don't show up. I changed the following code in index.html:

<script src="js/helpers.js"></script> <script src="js/playlist.js"></script>

to

<script src="js/helpers.js"></script> <script src="playlist.js"></script>

Not sure if you are inside js folder after calling the first js file.

Any idea?

It works now

1 Answer

David Kanwisher
David Kanwisher
9,751 Points

your script files are called in relation to the current file you are in.

If your script link is in your HTML then you will navigate your files/folders from that HTML file.

<script src="js/helpers.js"></script> <script src="playlist.js"></script>

In this example your helpers.js file is in a folder called js, and your playlist.js file is in the same folder as your HTML file.