Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
async function build({ cwd }) {
reporter.info(`Building components for ${meta.length} icons...`);
const ESM_DIR = path.join(cwd, 'es');
const BUNDLE_FORMATS = [
{
format: 'cjs',
directory: 'lib',
},
{
format: 'umd',
directory: 'umd',
},
];
reporter.info('Building ESM and bundle sources...');
await Promise.all(
meta.map(async info => {
const source = createModuleFromInfo(info);