Release v0.2.0

This commit is contained in:
Roman Hotsiy 2016-01-20 17:09:02 +02:00
parent 9d26d9b426
commit d385589d3a
5 changed files with 5444 additions and 12 deletions

5413
demo/rebilly.json Normal file

File diff suppressed because it is too large Load Diff

27
dist/redoc.full.js vendored
View File

@ -8178,21 +8178,39 @@ $__System.register('1a', ['2', '3', '4', '5', '6', '7', '8', '10', '12', '13', '
throw error;
});
}
}, {
key: 'autoInit',
value: function autoInit() {
var specUrlAttributeName = 'spec-url';
var dom = new BrowserDomAdapter();
var redocEl = dom.query('redoc');
if (!redocEl) return;
if (dom.hasAttribute(redocEl, specUrlAttributeName)) {
var url = dom.getAttribute(redocEl, specUrlAttributeName);
Redoc.init(url);
}
}
}, {
key: 'dispose',
value: function dispose() {
var dom = new BrowserDomAdapter();
var el = dom.query('redoc');
var parent = el.parentElement;
var nextSibling = el.nextElementSibling;
var parent = undefined;
var nextSibling = undefined;
if (el) {
parent = el.parentElement;
nextSibling = el.nextElementSibling;
}
Redoc.appRef && Redoc.appRef.dispose();
if (Redoc.appRef) {
Redoc.appRef.dispose();
Redoc.appRef = null;
// Redoc dispose removes host element, so need to restore it
el = dom.createElement('redoc');
el.innerText = 'Loading...';
parent.insertBefore(el, nextSibling);
parent && parent.insertBefore(el, nextSibling);
}
}
}]);
@ -55466,6 +55484,7 @@ $__System.register('1', ['14', '1a9'], function (_export) {
window.Redoc = Redoc;
enableProdMode();
Redoc.autoInit();
}
};
});

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long