How to get D3/SVG to work without codePen

All I’m trying to do is display a pink box using d3/svg. I’m sure I’m missing something super simple but can’t figure it out.

Here is the link to my github files: Bar Chart

Here is the link to the full webpage: Bar Chart WebPage

Why doesn’t the svg display?

Thanks in advance!

What happens if you put your <script> just above the closing of the <body> tag?

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

From concerning loading an external JavaScript file…

The script will behave as if it was located exactly where the <script> tag is located.

Yep that did the trick!

Thanks! I literally spent hours trying to get that to work ha

Yeah, it happens.
Glad you got it working.