Javascript SDK of WoopChain protocol
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.
 
 
sdk/scripts/rollup/getDependencies.js

13 lines
350 B

import fs from 'fs';
export function getKeys(p) {
const packageJsonFile = `${process.cwd()}/packages/${p}/package.json`;
const data = fs.readFileSync(packageJsonFile, 'utf-8');
const { dependencies } = JSON.parse(data);
const keys = dependencies
? Object.keys(dependencies).filter((d) => !/harmony/.test(d))
: [];
return keys;
}