2021-02-26 14:09:13 +00:00
|
|
|
//
|
2021-06-24 22:24:54 +00:00
|
|
|
// This script runs the Custom Elements Manifest analyzer to generate custom-elements.json
|
2021-02-26 14:09:13 +00:00
|
|
|
//
|
2021-06-17 21:38:48 +00:00
|
|
|
import chalk from 'chalk';
|
|
|
|
import mkdirp from 'mkdirp';
|
2021-06-24 22:24:54 +00:00
|
|
|
import { execSync } from 'child_process';
|
2021-02-26 14:09:13 +00:00
|
|
|
|
2021-06-24 22:24:54 +00:00
|
|
|
mkdirp.sync('./dist');
|
2021-03-03 21:56:42 +00:00
|
|
|
|
2021-06-24 22:24:54 +00:00
|
|
|
// Run the analyzer
|
|
|
|
console.log('Generating component metadata');
|
|
|
|
execSync('cem analyze --litelement --outdir dist', { stdio: 'inherit' });
|
|
|
|
console.log(chalk.cyan(`Successfully generated metadata 🏷\n`));
|