feat(docs): add mkdocs

This commit is contained in:
Jef LeCompte
2020-12-07 00:18:43 -05:00
parent bc2272e59a
commit 243109a4ff
53 changed files with 1112 additions and 644 deletions
+11 -4
View File
@@ -20,7 +20,9 @@ const prettyJson = winston.format.printf((info) => {
export const logger = winston.createLogger({
format: winston.format.combine(
winston.format.colorize(),
winston.format.metadata({fillExcept: ['level', 'message', 'timestamp']}),
winston.format.metadata({
fillExcept: ['level', 'message', 'timestamp']
}),
prettyJson
),
level: config.logLevel,
@@ -129,7 +131,9 @@ export const Print = {
'✖ ' +
buildProductString(link, store, true) +
' :: ' +
chalk.yellow(`PRICE ${link.price ?? ''} EXCEEDS LIMIT ${maxPrice}`)
chalk.yellow(
`PRICE ${link.price ?? ''} EXCEEDS LIMIT ${maxPrice}`
)
);
}
@@ -180,7 +184,8 @@ export const Print = {
},
productInStock(link: Link): string {
let productString = `Product Page: ${link.url}`;
if (link.cartUrl) productString += `\nAdd To Cart Link: ${link.cartUrl}`;
if (link.cartUrl)
productString += `\nAdd To Cart Link: ${link.cartUrl}`;
return productString;
},
@@ -204,7 +209,9 @@ function buildSetupString(
color?: boolean
): string {
if (color) {
return chalk.cyan(`[${store.name}]`) + chalk.grey(` [setup (${topic})]`);
return (
chalk.cyan(`[${store.name}]`) + chalk.grey(` [setup (${topic})]`)
);
}
return `[${store.name}] [setup (${topic})]`;