-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
138 additions
and
129 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,8 @@ | ||
# Package Management | ||
package-lock.json | ||
pnpm-lock.yaml | ||
node_modules | ||
|
||
# Dist Files | ||
dist | ||
logger.d.ts | ||
logger.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
# Package Management | ||
package-lock.json | ||
pnpm-lock.yaml | ||
node_modules | ||
|
||
# TypeScript Files | ||
tsconfig.json | ||
*.ts | ||
logger.ts | ||
|
||
# Source Files | ||
assets | ||
.gitignore | ||
dist/src | ||
.gitattributes | ||
CHANGELOGS.md | ||
eslint.config.mjs | ||
src | ||
Tests | ||
src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
# Notable Changes & Versioning | ||
All notable changes to this project will be documented in this file :3 | ||
|
||
This project adheres to [Semantic Versioning](https://semver.org/) starting `v1.0.2`. | ||
|
||
|
||
## 1.0.2 [2024-OCT-15] | ||
### Changed | ||
- Class name from `Logger` to `Logena`. | ||
|
||
### Fixed | ||
- Class methods, now they're actually accessible from the class instance. | ||
|
||
## 1.0.1 [2024-OCT-15] | ||
### Changed | ||
- Moved `logger.js` from `/dist` to project root. | ||
- Update `package.json` to reflect changes. | ||
- Lowered minimum NodeJS version to `14.0.0`, let's be fr, we don't need to be that strict. | ||
|
||
### Removed | ||
- `/dist` directory. | ||
- `/Tests` directory. | ||
- `clean.mjs` (Now runs via npm script `uglifyjs ...`) | ||
|
||
## 1.0.0 [2024-OCT-15] | ||
|
||
### Added | ||
- Initial release of the `Logger` class. | ||
- Added `terminalColors` object for terminal text styling. | ||
- Implemented `Logger` class with the following methods: | ||
- `set(config: { debug?: boolean, appName?: string, useTimestamps?: boolean, colors?: { timestamp?: keyof typeof terminalColors.textColors, appName?: keyof typeof terminalColors.textColors, message?: keyof typeof terminalColors.textColors, levels?: { info?: keyof typeof terminalColors.textColors, warn?: keyof typeof terminalColors.textColors, error?: keyof typeof terminalColors.textColors, debug?: keyof typeof terminalColors.textColors } } }): void` - Configure the logger settings. | ||
- `info(message: string | object): void` - Log an info message to the console. | ||
- `warn(message: string | object): void` - Log a warning to the console. | ||
- `error(message: string | object): void` - Log an error to the console. | ||
- `debug(message: string | object): void` - Log a debug message to the console (only if `debugMode` is enabled). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
export {}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const logger_1 = require("../logger"); | ||
logger_1.Logena.set({ | ||
appName: "LOGENA", | ||
colors: { | ||
appName: "brightGreen", | ||
timestamp: "black", | ||
}, | ||
debug: true, | ||
useTimestamps: true | ||
}); | ||
logger_1.Logena.info("This is an info message"); | ||
logger_1.Logena.warn("This is a warning message"); | ||
logger_1.Logena.error("This is an error message"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.