$ not defined (jQuery)

Hey there,

I am trying to work with API’s via superagent. I need to find an object in a JSON object so I saw u needed array’s. My code doesn’t have any errors but the log says $ not defined. I did install jquery but still it doesn’t work. Any help?

Glitch project: https://glitch.com/~rainy-ranunculus
Search under commands and then hguilds2.js

UPDATE: Now it says $.each is not a function.

jquery is more suited to working with DOM, i.e. html structure, you likely don’t need it.

Instead try using something like …

const obj = JSON.parse(stringWithJSON)