You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
584 B

const $ = require('dekko');
const chalk = require('chalk');
$('lib').isDirectory().hasFile('index.js').hasFile('index.d.ts');
$('lib/*')
.filter(
(filename) =>
!filename.endsWith('index.js') &&
!filename.endsWith('index.d.ts') &&
!filename.endsWith('.map'),
)
.isDirectory()
.filter(
(filename) =>
!filename.endsWith('style') && !filename.endsWith('_util') && !filename.endsWith('locale'),
)
.hasFile('index.js')
.hasFile('index.d.ts');
// eslint-disable-next-line no-console
console.log(chalk.green('✨ `lib` directory is valid.'));