Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
examplesElem.addEventListener('change', function () {
if (examplesElem.value !== 'Select an example') {
examplesElem.parentNode.classList.add('loading');
const resp = fetch(examplesElem.value).then(x => x.text());
resp.then(x => jsonInput.setValue(x));
}
});