I am getting an error :
Uncaught ReferenceError: d3 is not defined
for my code
<body>
<script>
const dataset = [12, 31, 22, 17, 25, 18, 29, 14, 9];
// Add your code below this line
d3.select('body').selectAll('h2')
.data(dataset)
.enter()
.append('h2')
.text('New Title');
// Add your code above this line
</script>
</body>
Your browser information:
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/79.0.3945.117 Safari/537.36.
Challenge: Work with Data in D3
Link to the challenge:
https://www.freecodecamp.org/learn/data-visualization/data-visualization-with-d3/work-with-data-in-d3