How to use the @microsoft/api-extractor.Extractor.loadConfigAndInvoke function in @microsoft/api-extractor

To help you get started, we’ve selected a few @microsoft/api-extractor examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github esfx / esfx / scripts / docs.js View on Github external
async function apiExtractor(docPackage) {
    const result = Extractor.loadConfigAndInvoke(path.resolve(docPackage, "api-extractor.json"), {
        localBuild: true,
    });
    if (!result.succeeded) {
        throw new Error(`api-extractor failed for ${docPackage}`);
    }
}
exports.apiExtractor = apiExtractor;