redoc/demo/main.js

14 lines
357 B
JavaScript
Raw Normal View History

2015-11-04 22:31:10 +03:00
;(function() {
'use strict';
2016-01-23 01:00:28 +03:00
var schemaUrlForm = document.getElementById('schema-url-form');
2015-11-04 22:31:10 +03:00
var schemaUrlInput = document.getElementById('schema-url-input');
2016-01-23 01:00:28 +03:00
schemaUrlForm.addEventListener('submit', function(event) {
2016-01-24 20:01:17 +03:00
event.preventDefault();
2015-11-04 22:31:10 +03:00
Redoc.init(schemaUrlInput.value);
2016-01-24 20:01:17 +03:00
return false;
2015-11-04 22:31:10 +03:00
})
//window.redocDebugMode = true;
2015-11-04 22:31:10 +03:00
})();