Works in codepen, Not on localhost

Newbie here. I have JS code that uses various APIs to pull in and display data from USGS and NOAA data servers. It all works in Codepen. But when I display the site via localhost, the HTML and CSS work, but the JS is stopping at the API fetch.
Would appreciate any insights.

Code: https://docs.google.com/document/d/1dDl6tWe07KeaDN_ui51RCjFLsgwZf6oS8Ep8HbkcPXs/edit?usp=sharing

how do you know it’s stopping at the fetch? What’s it telling you?

1 Like

Looks like you are missing the javascript in your html.

Put something like this before the body end.

 <script src="script.js"></script>
</body>

It works fine for me.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.