Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
// @ts-check
const path = require('path');
const { apiExtractorVerifyTask, apiExtractorUpdateTask } = require('just-scripts');
const configPath = path.resolve(process.cwd(), 'config/api-extractor.json');
exports.verifyApiExtractor = apiExtractorVerifyTask(configPath, undefined);
exports.updateApiExtractor = apiExtractorUpdateTask(configPath, undefined);
option,
argv,
tscTask,
eslintTask,
apiExtractorVerifyTask,
apiExtractorUpdateTask,
cleanTask,
} = require('just-scripts');
const libPath = path.resolve(process.cwd(), 'lib');
const srcPath = path.resolve(process.cwd(), 'src');
option('production');
option('clean');
option('ci');
task('apiExtractorVerify', apiExtractorVerifyTask());
task('apiExtractorUpdate', apiExtractorUpdateTask());
task('apiDocumenter', () => {
require('child_process').execSync(
'npx @microsoft/api-documenter markdown -i temp -o docs/api',
{stdio: 'inherit'},
);
});
task('eslint', () => {
return eslintTask();
});
task('copyFlowFiles', () => {
return copyTask(['src/**/*.js'], '.');
});
task('copyPngFiles', () => {
option,
argv,
tscTask,
eslintTask,
apiExtractorVerifyTask,
apiExtractorUpdateTask,
cleanTask,
} = require('just-scripts');
const libPath = path.resolve(process.cwd(), 'lib');
const srcPath = path.resolve(process.cwd(), 'src');
option('production');
option('clean');
option('ci');
task('apiExtractorVerify', apiExtractorVerifyTask());
task('apiExtractorUpdate', apiExtractorUpdateTask());
task('apiDocumenter', () => {
require('child_process').execSync(
'npx @microsoft/api-documenter markdown -i temp -o docs/api',
{stdio: 'inherit'},
);
});
task('flow-check', () => {
require('child_process').execSync('npx flow check', {stdio: 'inherit'});
});
task('eslint', () => {
return eslintTask();
});