- Renamed auth-service to iam-service across various files for consistency. - Updated deployment workflows, database migration scripts, and documentation to reflect the service name change. - Enhanced bilingual documentation for clarity on the new service structure and usage. - Removed outdated references to auth-service in scripts and configuration files to streamline the project structure.
30 lines
621 B
Markdown
30 lines
621 B
Markdown
# @goodgo/logger
|
|
|
|
Centralized logging utility using Winston.
|
|
|
|
## Usage
|
|
|
|
```typescript
|
|
import { logger, createLogger } from '@goodgo/logger';
|
|
|
|
// Use default logger
|
|
logger.info('Application started');
|
|
logger.error('Error occurred', { error: err });
|
|
|
|
// Create custom logger
|
|
const customLogger = createLogger({
|
|
level: 'debug',
|
|
serviceName: 'iam-service',
|
|
enableFile: true,
|
|
logDir: './logs',
|
|
});
|
|
```
|
|
|
|
## Configuration
|
|
|
|
- `level`: Log level (error, warn, info, debug)
|
|
- `serviceName`: Service identifier
|
|
- `enableConsole`: Enable console output
|
|
- `enableFile`: Enable file logging
|
|
- `logDir`: Directory for log files
|