While going through an example of await in JavaScript's References, I found that the URL provided (which led to the repo's GitHub pages) to the fetch function in getColor.js was broken. Thus, the example could not be demonstrated. I fixed this by changing the URL to https://raw.githubusercontent.com/mdn/js-examples/master/module-examples/top-level-await/data/colors.json.
edit: it seems like this issue is caused by a change in the folder name in a previous change, but the link was not updated accordingly in getColors.js. So I've changed the link to https://mdn.github.io/js-examples/module-examples/top-level-await/data/colors.json instead of the raw GitHub link
While going through an example of
await
in JavaScript's References, I found that the URL provided (which led to the repo's GitHub pages) to the fetch function in getColor.js was broken. Thus, the example could not be demonstrated. I fixed this by changing the URL to.https://raw.githubusercontent.com/mdn/js-examples/master/module-examples/top-level-await/data/colors.json
edit: it seems like this issue is caused by a change in the folder name in a previous change, but the link was not updated accordingly in getColors.js. So I've changed the link to
https://mdn.github.io/js-examples/module-examples/top-level-await/data/colors.json
instead of the raw GitHub link