Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
return chain(routes.map(x => () => scrape(x).then(print))).then(arr => {
proc.kill();
chrome.close();
server.close();
log.log('Shutdown local server\n');
let sfx = arr.length > 1 ? 's' : '';
let num = colors.italic().bold().green(arr.length);
log.success(`Export complete!\nGenerated ${num} page${sfx} 🙌🏼`);
}).catch(err => {
console.log('> error', err); // TODO
const printServerInstructions = config => {
const urls = webpackDevServerUtils.prepareUrls('http', config.serverHost, config.serverPort);
console.log(`${kleur.cyan().bold(`
/££££££££
|_____ ££
/££/ /££££££ /££££££ /££££££
/££/ /££__ ££ /££__ ££ |____ ££
/££/ | ££ \\ ££| ££ \\ ££ /£££££££
/££/ | ££ | ££| ££ | ££ /££__ ££
/££££££££| ££££££/| £££££££/| £££££££
|________/ \\______/ | ££____/ \\_______/
| ££
| ££ React Components
|__/`)}
${kleur.italic('You can now view your style guide in the browser')}
${kleur.bold('Local:')} ${urls.localUrlForTerminal}
`);
if (urls.lanUrlForTerminal) {
console.log(`${kleur.bold('On your network:')} ${urls.lanUrlForTerminal}
`);
}
};
function main() {
if (!existsSync(PACKAGE_ROOT)) {
throw new Error(`${PACKAGE_ROOT}, doesn't exists`)
}
log(kleur.italic('Migration initialized 👀...'))
log(kleur.gray('path to Package:'), PACKAGE_ROOT)
updatePackageJson()
updateTsConfig()
updateTsLintConfig()
updateConfigDir()
updateScriptsDir()
updatePrettierIgnore()
log(kleur.cyan('DONE ✅'))
}
function main() {
if (!existsSync(PACKAGE_ROOT)) {
throw new Error(`${PACKAGE_ROOT}, doesn't exists`)
}
log(kleur.italic('Migration initialized 👀...'))
log(kleur.gray('path to Package:'), PACKAGE_ROOT)
updatePackageJson()
updateTsConfig()
updateTsLintConfig()
updateConfigDir()
updateScriptsDir()
updatePrettierIgnore()
log(kleur.cyan('DONE ✅'))
}
function main() {
if (!existsSync(PACKAGE_ROOT)) {
throw new Error(`${PACKAGE_ROOT}, doesn't exists`)
}
log(kleur.italic('Migration initialized 👀...'))
log(kleur.gray('path to Package:'), PACKAGE_ROOT)
updatePackageJson()
updateTsConfig()
updateTsLintConfig()
updateRcFiles()
updatePrettier()
updateConfigDir()
updateScriptsDir()
updateVSCodeDir()
log(kleur.cyan('DONE ✅'))
log(kleur.inverse().cyan('Make sure run yarn, to update yarn.lock 🤙'))
}
import kleur from 'kleur'
import { list, identity } from './util'
const defaultOptions = {
code: kleur.yellow,
blockquote: kleur.gray().bgWhite().italic,
html: kleur.gray,
heading: kleur.green().bold,
firstHeading: kleur.magenta().underline().bold,
hr: kleur.reset,
listitem: kleur.reset,
list: list,
table: kleur.reset,
paragraph: identity,
strong: kleur.bold,
em: kleur.italic,
codespan: kleur.yellow,
del: kleur.dim().gray().strikethrough,
link: kleur.blue,
href: kleur.blue().underline,
text: identity,
unescape: true,
emoji: true,
width: 80,
showSectionPrefix: true,
reflowText: false,
tab: 4,
tableOptions: {}
}
export default defaultOptions
function main() {
if (!existsSync(PACKAGE_ROOT)) {
throw new Error(`${PACKAGE_ROOT}, doesn't exists`)
}
log(kleur.italic('Migration initialized 👀...'))
log(kleur.gray('path to Package:'), PACKAGE_ROOT)
updatePackageJson()
updateTsConfig()
updateTsLintConfig()
updateRcFiles()
updatePrettier()
updateConfigDir()
updateScriptsDir()
updateVSCodeDir()
log(kleur.cyan('DONE ✅'))
log(kleur.inverse().cyan('Make sure run yarn, to update yarn.lock 🤙'))
}