nightingale-string 14.2.1 → 16.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +32 -0
- package/README.md +9 -9
- package/lib/index.js +1 -0
- package/package.json +11 -36
- package/dist/definitions/index.d.ts +0 -9
- package/dist/definitions/index.d.ts.map +0 -1
- package/dist/index-node18.mjs +0 -18
- package/dist/index-node18.mjs.map +0 -1
- package/src/.eslintrc.json +0 -30
- package/src/index.ts +0 -21
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,38 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [16.0.0](https://github.com/christophehurpeau/nightingale/compare/v15.0.0...v16.0.0) (2025-03-30)
|
|
7
|
+
|
|
8
|
+
### ⚠ BREAKING CHANGES
|
|
9
|
+
|
|
10
|
+
* drop node 18
|
|
11
|
+
|
|
12
|
+
### Features
|
|
13
|
+
|
|
14
|
+
* drop node 18 ([1b11a55](https://github.com/christophehurpeau/nightingale/commit/1b11a55dd24c9435be50519a748316079f554414))
|
|
15
|
+
|
|
16
|
+
### Bug Fixes
|
|
17
|
+
|
|
18
|
+
* fix lib exports ([5b562b2](https://github.com/christophehurpeau/nightingale/commit/5b562b245aac1aa86b728a9433f3c9d28c62fe04))
|
|
19
|
+
|
|
20
|
+
Version bump for dependency: nightingale
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
## [15.0.0](https://github.com/christophehurpeau/nightingale/compare/v14.2.1...v15.0.0) (2023-12-25)
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
### ⚠ BREAKING CHANGES
|
|
27
|
+
|
|
28
|
+
* update babel and drop browser modern version
|
|
29
|
+
|
|
30
|
+
### Features
|
|
31
|
+
|
|
32
|
+
* update babel and drop browser modern version ([5c76abc](https://github.com/christophehurpeau/nightingale/commit/5c76abc8bfb595a617fc4c8b795dae7e674ea664))
|
|
33
|
+
|
|
34
|
+
Version bump for dependency: nightingale-raw-formatter
|
|
35
|
+
Version bump for dependency: nightingale-types
|
|
36
|
+
|
|
37
|
+
|
|
6
38
|
## [14.2.1](https://github.com/christophehurpeau/nightingale/compare/v14.2.0...v14.2.1) (2023-11-05)
|
|
7
39
|
|
|
8
40
|
Note: no notable changes
|
package/README.md
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
<
|
|
1
|
+
<h1 align="center">
|
|
2
2
|
nightingale-string
|
|
3
|
-
</
|
|
3
|
+
</h1>
|
|
4
4
|
|
|
5
5
|
<p align="center">
|
|
6
|
-
String
|
|
6
|
+
Deprecated, use String from nightingale instead
|
|
7
7
|
</p>
|
|
8
8
|
|
|
9
9
|
<p align="center">
|
|
10
|
-
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/v/nightingale-string.svg?style=flat-square"></a>
|
|
11
|
-
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/dw/nightingale-string.svg?style=flat-square"></a>
|
|
12
|
-
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/node/v/nightingale-string.svg?style=flat-square"></a>
|
|
13
|
-
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/types/nightingale-string.svg?style=flat-square"></a>
|
|
10
|
+
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/v/nightingale-string.svg?style=flat-square" alt="npm version"></a>
|
|
11
|
+
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/dw/nightingale-string.svg?style=flat-square" alt="npm downloads"></a>
|
|
12
|
+
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/node/v/nightingale-string.svg?style=flat-square" alt="node version"></a>
|
|
13
|
+
<a href="https://npmjs.org/package/nightingale-string"><img src="https://img.shields.io/npm/types/nightingale-string.svg?style=flat-square" alt="types"></a>
|
|
14
14
|
</p>
|
|
15
15
|
|
|
16
16
|
## Install
|
|
17
17
|
|
|
18
18
|
```sh
|
|
19
|
-
npm install --save nightingale
|
|
19
|
+
npm install --save nightingale
|
|
20
20
|
```
|
|
21
21
|
|
|
22
22
|
## Usage
|
|
23
23
|
|
|
24
24
|
```js
|
|
25
|
-
import
|
|
25
|
+
import { StringHandler } from "nightingale";
|
|
26
26
|
```
|
package/lib/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { StringHandler } from "nightingale";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nightingale-string",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "String
|
|
3
|
+
"version": "16.0.0",
|
|
4
|
+
"description": "Deprecated, use String from nightingale instead",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"nightingale",
|
|
7
7
|
"nightingale-handler"
|
|
@@ -16,52 +16,27 @@
|
|
|
16
16
|
"homepage": "https://github.com/christophehurpeau/nightingale",
|
|
17
17
|
"type": "module",
|
|
18
18
|
"engines": {
|
|
19
|
-
"node": ">=
|
|
19
|
+
"node": ">=20.9.0"
|
|
20
20
|
},
|
|
21
|
-
"
|
|
22
|
-
"
|
|
21
|
+
"sideEffects": false,
|
|
22
|
+
"main": "./lib/index.js",
|
|
23
|
+
"types": "./lib/index.d.ts",
|
|
23
24
|
"exports": {
|
|
24
25
|
"./package.json": "./package.json",
|
|
25
|
-
".":
|
|
26
|
-
"types": "./dist/definitions/index.d.ts",
|
|
27
|
-
"node": {
|
|
28
|
-
"import": "./dist/index-node18.mjs"
|
|
29
|
-
}
|
|
30
|
-
}
|
|
26
|
+
".": "./lib/index.js"
|
|
31
27
|
},
|
|
32
|
-
"sideEffects": false,
|
|
33
28
|
"files": [
|
|
34
|
-
"
|
|
35
|
-
"dist"
|
|
29
|
+
"lib"
|
|
36
30
|
],
|
|
37
31
|
"scripts": {
|
|
38
|
-
"build": "yarn clean:build && rollup --config rollup.config.mjs && yarn run build:definitions",
|
|
39
|
-
"build:definitions": "tsc -p tsconfig.json",
|
|
40
32
|
"clean": "yarn clean:build",
|
|
41
|
-
"clean:build": "pob-babel-clean-out dist",
|
|
42
33
|
"lint": "yarn run lint:eslint",
|
|
43
|
-
"lint:eslint": "yarn ../.. run eslint --
|
|
34
|
+
"lint:eslint": "yarn ../.. run eslint --quiet packages/nightingale-string",
|
|
44
35
|
"watch": "yarn clean:build && rollup --config rollup.config.mjs --watch"
|
|
45
36
|
},
|
|
37
|
+
"pob": {},
|
|
46
38
|
"prettier": "@pob/root/prettier-config",
|
|
47
|
-
"pob": {
|
|
48
|
-
"babelEnvs": [
|
|
49
|
-
{
|
|
50
|
-
"target": "node",
|
|
51
|
-
"version": "18"
|
|
52
|
-
}
|
|
53
|
-
],
|
|
54
|
-
"entries": [
|
|
55
|
-
"index"
|
|
56
|
-
]
|
|
57
|
-
},
|
|
58
39
|
"dependencies": {
|
|
59
|
-
"nightingale
|
|
60
|
-
"nightingale-types": "14.2.1"
|
|
61
|
-
},
|
|
62
|
-
"devDependencies": {
|
|
63
|
-
"@babel/core": "7.23.2",
|
|
64
|
-
"pob-babel": "36.6.1",
|
|
65
|
-
"typescript": "5.2.2"
|
|
40
|
+
"nightingale": "16.0.0"
|
|
66
41
|
}
|
|
67
42
|
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { Handler, Level, LogRecord, Metadata } from 'nightingale-types';
|
|
2
|
-
export declare class StringHandler implements Handler {
|
|
3
|
-
readonly minLevel: Level;
|
|
4
|
-
private _buffer;
|
|
5
|
-
constructor(minLevel: Level);
|
|
6
|
-
get string(): string;
|
|
7
|
-
handle<T extends Metadata>(record: LogRecord<T>): void;
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAE7E,qBAAa,aAAc,YAAW,OAAO;IAC3C,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC;IAEzB,OAAO,CAAC,OAAO,CAAM;gBAET,QAAQ,EAAE,KAAK;IAI3B,IAAI,MAAM,IAAI,MAAM,CAEnB;IAED,MAAM,CAAC,CAAC,SAAS,QAAQ,EAAE,MAAM,EAAE,SAAS,CAAC,CAAC,CAAC,GAAG,IAAI;CAGvD"}
|
package/dist/index-node18.mjs
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import formatterRaw from 'nightingale-raw-formatter';
|
|
2
|
-
|
|
3
|
-
/* eslint-disable prefer-template */
|
|
4
|
-
class StringHandler {
|
|
5
|
-
_buffer = '';
|
|
6
|
-
constructor(minLevel) {
|
|
7
|
-
this.minLevel = minLevel;
|
|
8
|
-
}
|
|
9
|
-
get string() {
|
|
10
|
-
return this._buffer;
|
|
11
|
-
}
|
|
12
|
-
handle(record) {
|
|
13
|
-
this._buffer += formatterRaw(record) + '\n';
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export { StringHandler };
|
|
18
|
-
//# sourceMappingURL=index-node18.mjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index-node18.mjs","sources":["../src/index.ts"],"sourcesContent":["/* eslint-disable prefer-template */\nimport formatterRaw from 'nightingale-raw-formatter';\nimport type { Handler, Level, LogRecord, Metadata } from 'nightingale-types';\n\nexport class StringHandler implements Handler {\n readonly minLevel: Level;\n\n private _buffer = '';\n\n constructor(minLevel: Level) {\n this.minLevel = minLevel;\n }\n\n get string(): string {\n return this._buffer;\n }\n\n handle<T extends Metadata>(record: LogRecord<T>): void {\n this._buffer += formatterRaw(record) + '\\n';\n }\n}\n"],"names":["StringHandler","_buffer","constructor","minLevel","string","handle","record","formatterRaw"],"mappings":";;AAAA;AAIO,MAAMA,aAAa,CAAoB;AAGpCC,EAAAA,OAAO,GAAG,EAAE,CAAA;EAEpBC,WAAWA,CAACC,QAAe,EAAE;IAC3B,IAAI,CAACA,QAAQ,GAAGA,QAAQ,CAAA;AAC1B,GAAA;EAEA,IAAIC,MAAMA,GAAW;IACnB,OAAO,IAAI,CAACH,OAAO,CAAA;AACrB,GAAA;EAEAI,MAAMA,CAAqBC,MAAoB,EAAQ;IACrD,IAAI,CAACL,OAAO,IAAIM,YAAY,CAACD,MAAM,CAAC,GAAG,IAAI,CAAA;AAC7C,GAAA;AACF;;;;"}
|
package/src/.eslintrc.json
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"root": true,
|
|
3
|
-
"parser": "@typescript-eslint/parser",
|
|
4
|
-
"parserOptions": {
|
|
5
|
-
"project": "packages/nightingale-string/tsconfig.json"
|
|
6
|
-
},
|
|
7
|
-
"plugins": ["@typescript-eslint"],
|
|
8
|
-
"extends": [
|
|
9
|
-
"@pob/eslint-config-typescript",
|
|
10
|
-
"@pob/eslint-config-typescript/node"
|
|
11
|
-
],
|
|
12
|
-
"ignorePatterns": ["*.d.ts"],
|
|
13
|
-
"overrides": [
|
|
14
|
-
{
|
|
15
|
-
"files": ["**/*.test.ts", "__tests__/**/*.ts"],
|
|
16
|
-
"extends": ["@pob/eslint-config-typescript/test"],
|
|
17
|
-
"env": {
|
|
18
|
-
"jest": true
|
|
19
|
-
},
|
|
20
|
-
"rules": {
|
|
21
|
-
"import/no-extraneous-dependencies": [
|
|
22
|
-
"error",
|
|
23
|
-
{
|
|
24
|
-
"devDependencies": true
|
|
25
|
-
}
|
|
26
|
-
]
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
]
|
|
30
|
-
}
|
package/src/index.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/* eslint-disable prefer-template */
|
|
2
|
-
import formatterRaw from 'nightingale-raw-formatter';
|
|
3
|
-
import type { Handler, Level, LogRecord, Metadata } from 'nightingale-types';
|
|
4
|
-
|
|
5
|
-
export class StringHandler implements Handler {
|
|
6
|
-
readonly minLevel: Level;
|
|
7
|
-
|
|
8
|
-
private _buffer = '';
|
|
9
|
-
|
|
10
|
-
constructor(minLevel: Level) {
|
|
11
|
-
this.minLevel = minLevel;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
get string(): string {
|
|
15
|
-
return this._buffer;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
handle<T extends Metadata>(record: LogRecord<T>): void {
|
|
19
|
-
this._buffer += formatterRaw(record) + '\n';
|
|
20
|
-
}
|
|
21
|
-
}
|