mirror of
https://github.com/tiennm99/github-readme-stats.git
synced 2026-09-07 20:20:26 +00:00
feat: added isTemplate badge & refactored console.logs (#146)
* feat: template option added husky added for same commit disable console in test \ logger utils added env checked for log modified git ignore * changed are done as per the suggesstion * changed style and font * text color dynamic * fix border and using .bagde class as common * simplified the badge svg code through a common method * chore: updated css & fixed tests Co-authored-by: anuraghazra <hazru.anurag@gmail.com>
This commit is contained in:
co-authored by
anuraghazra
parent
03f55e809e
commit
5ed75e11be
@@ -116,6 +116,10 @@ function getCardColors({
|
||||
return { titleColor, iconColor, textColor, bgColor };
|
||||
}
|
||||
|
||||
const fn = () => {};
|
||||
// return console instance based on the environment
|
||||
const logger = process.env.NODE_ENV !== "test" ? console : { log: fn, error: fn };
|
||||
|
||||
const CONSTANTS = {
|
||||
THIRTY_MINUTES: 1800,
|
||||
TWO_HOURS: 7200,
|
||||
@@ -133,5 +137,6 @@ module.exports = {
|
||||
FlexLayout,
|
||||
getCardColors,
|
||||
clampValue,
|
||||
logger,
|
||||
CONSTANTS,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user