ng2-logger 16.5.8 → 16.5.10

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/README.md CHANGED
@@ -1,192 +1,192 @@
1
- ## firedev-logger (ng2-logger) ##
2
-
3
- - Part of [firedev.io](https://github.com/darekf77/firedev)
4
- - Isomorphic Logger for TypeScript and JavaScript apps.
5
- - Purpose:
6
- + usefull/elegant backend/frontend logger
7
-
8
- You can use this logger in your apps with **any**
9
- TS/JS framework.
10
-
11
- See what is going on in your app!
12
-
13
- Now chrome console logs are full of colors!
14
-
15
- ![Modules marked](screen.png)
16
-
17
- See nice server logs:
18
-
19
- ![Modules marked](server.png)
20
-
21
-
22
- To install package run:
23
- ```
24
- npm install ng2-logger --save
25
- ```
26
-
27
- First import proper version for your environment:
28
-
29
-
30
-
31
- Nodejs server (or any firedev's lib/app):
32
-
33
-
34
-
35
- ```ts
36
-
37
- import { Log, Level } from 'ng2-logger'
38
-
39
- ```
40
-
41
- or Browser:
42
-
43
-
44
-
45
- ```ts
46
-
47
- import { Log, Level } from 'ng2-logger/browser' // new javascript module: es2015 + esnext + angular ivy support
48
-
49
- ```
50
-
51
-
52
-
53
- Simple use:
54
-
55
-
56
-
57
- In your file with log:
58
-
59
- ```ts
60
-
61
- const log = Log.create('books');
62
-
63
- ```
64
-
65
- or if you wanna just log errors and warnings :
66
-
67
- ```ts
68
-
69
- const log = Log.create('books', Level.ERROR, Level.WARN);
70
-
71
- ```
72
-
73
- 'books' is current class or anything inside *.ts/*.js file.
74
-
75
-
76
-
77
- You can also assign static color to specific module in application (browser for now only):
78
-
79
- ```ts
80
-
81
- log.color = 'red';
82
-
83
- ```
84
-
85
- After inited **log** you are able to start debugging:
86
-
87
- ```ts
88
-
89
- log.d('object',obj) // console.log
90
-
91
- log.er('object',obj) // console.error
92
-
93
- log.i('object',obj) // console.info
94
-
95
- log.w('object',obj) // console.warn
96
-
97
- ```
98
-
99
- or
100
-
101
- ```ts
102
-
103
- log.debug('object',obj) // console.log
104
-
105
- log.error('object',obj) // console.error
106
-
107
- log.info('object',obj) // console.info
108
-
109
- log.warn('object',obj) // console.warn
110
-
111
- ```
112
-
113
-
114
-
115
-
116
- **Production mode**
117
-
118
- -------------------
119
-
120
-
121
-
122
- You will not see anyting in prduction mode:
123
-
124
-
125
-
126
- // enable production mode in your app
127
-
128
- ...
129
-
130
- Log.setProductionMode();
131
-
132
- ...
133
-
134
- // your app code with console and ng2-logger logs
135
-
136
-
137
-
138
-
139
- It is important to set production mode before any log messages are executed.
140
-
141
- This will ensure that log messages that should not be seen are leaked out.
142
-
143
-
144
-
145
-
146
- **Selective debug - global settings**
147
-
148
- -------------------
149
-
150
-
151
-
152
- Optional specify what you wanna see in yours debug console.
153
-
154
- This settings will override settings from files.
155
-
156
-
157
-
158
- ```ts
159
-
160
- Log.setProductionMode();
161
-
162
- Log.onlyModules('src:books', 'src:records', 'src:page:login');
163
-
164
- Log.onlyLevel(Level.ERROR,Level.INFO);
165
-
166
- ```
167
-
168
-
169
-
170
- **Specifying `onlyModules` as regular expression(s)**
171
-
172
- -------------------
173
-
174
-
175
-
176
- In the above example you'll notice `module:books` and `module:records` were specified.
177
-
178
- you might be using such syntax for namespace hierarchy etc. You may also pass in one or more regular
179
-
180
- expression string(s) to the `onlyModule` function to specify a selection of modules you wish
181
-
182
- to show, for instances those whose name begins with `src`:
183
-
184
-
185
-
186
- ```ts
187
-
188
-
189
-
190
- Log.onlyModules( new RegEx('^.src') );
191
-
192
- ```
1
+ ## firedev-logger (ng2-logger) ##
2
+
3
+ - Part of [firedev.io](https://github.com/darekf77/firedev)
4
+ - Isomorphic Logger for TypeScript and JavaScript apps.
5
+ - Purpose:
6
+ + usefull/elegant backend/frontend logger
7
+
8
+ You can use this logger in your apps with **any**
9
+ TS/JS framework.
10
+
11
+ See what is going on in your app!
12
+
13
+ Now chrome console logs are full of colors!
14
+
15
+ ![Modules marked](screen.png)
16
+
17
+ See nice server logs:
18
+
19
+ ![Modules marked](server.png)
20
+
21
+
22
+ To install package run:
23
+ ```
24
+ npm install ng2-logger --save
25
+ ```
26
+
27
+ First import proper version for your environment:
28
+
29
+
30
+
31
+ Nodejs server (or any firedev's lib/app):
32
+
33
+
34
+
35
+ ```ts
36
+
37
+ import { Log, Level } from 'ng2-logger'
38
+
39
+ ```
40
+
41
+ or Browser:
42
+
43
+
44
+
45
+ ```ts
46
+
47
+ import { Log, Level } from 'ng2-logger/browser' // new javascript module: es2015 + esnext + angular ivy support
48
+
49
+ ```
50
+
51
+
52
+
53
+ Simple use:
54
+
55
+
56
+
57
+ In your file with log:
58
+
59
+ ```ts
60
+
61
+ const log = Log.create('books');
62
+
63
+ ```
64
+
65
+ or if you wanna just log errors and warnings :
66
+
67
+ ```ts
68
+
69
+ const log = Log.create('books', Level.ERROR, Level.WARN);
70
+
71
+ ```
72
+
73
+ 'books' is current class or anything inside *.ts/*.js file.
74
+
75
+
76
+
77
+ You can also assign static color to specific module in application (browser for now only):
78
+
79
+ ```ts
80
+
81
+ log.color = 'red';
82
+
83
+ ```
84
+
85
+ After inited **log** you are able to start debugging:
86
+
87
+ ```ts
88
+
89
+ log.d('object',obj) // console.log
90
+
91
+ log.er('object',obj) // console.error
92
+
93
+ log.i('object',obj) // console.info
94
+
95
+ log.w('object',obj) // console.warn
96
+
97
+ ```
98
+
99
+ or
100
+
101
+ ```ts
102
+
103
+ log.debug('object',obj) // console.log
104
+
105
+ log.error('object',obj) // console.error
106
+
107
+ log.info('object',obj) // console.info
108
+
109
+ log.warn('object',obj) // console.warn
110
+
111
+ ```
112
+
113
+
114
+
115
+
116
+ **Production mode**
117
+
118
+ -------------------
119
+
120
+
121
+
122
+ You will not see anyting in prduction mode:
123
+
124
+
125
+
126
+ // enable production mode in your app
127
+
128
+ ...
129
+
130
+ Log.setProductionMode();
131
+
132
+ ...
133
+
134
+ // your app code with console and ng2-logger logs
135
+
136
+
137
+
138
+
139
+ It is important to set production mode before any log messages are executed.
140
+
141
+ This will ensure that log messages that should not be seen are leaked out.
142
+
143
+
144
+
145
+
146
+ **Selective debug - global settings**
147
+
148
+ -------------------
149
+
150
+
151
+
152
+ Optional specify what you wanna see in yours debug console.
153
+
154
+ This settings will override settings from files.
155
+
156
+
157
+
158
+ ```ts
159
+
160
+ Log.setProductionMode();
161
+
162
+ Log.onlyModules('src:books', 'src:records', 'src:page:login');
163
+
164
+ Log.onlyLevel(Level.ERROR,Level.INFO);
165
+
166
+ ```
167
+
168
+
169
+
170
+ **Specifying `onlyModules` as regular expression(s)**
171
+
172
+ -------------------
173
+
174
+
175
+
176
+ In the above example you'll notice `module:books` and `module:records` were specified.
177
+
178
+ you might be using such syntax for namespace hierarchy etc. You may also pass in one or more regular
179
+
180
+ expression string(s) to the `onlyModule` function to specify a selection of modules you wish
181
+
182
+ to show, for instances those whose name begins with `src`:
183
+
184
+
185
+
186
+ ```ts
187
+
188
+
189
+
190
+ Log.onlyModules( new RegEx('^.src') );
191
+
192
+ ```
@@ -1,6 +1,6 @@
1
1
  THIS FILE IS GENERATED. THIS FILE IS GENERATED. THIS FILE IS GENERATED.
2
2
 
3
- Assets from this folder are being shipped with this npm package (ng2-logger@16.5.8)
3
+ Assets from this folder are being shipped with this npm package (ng2-logger@16.5.10)
4
4
  created from this project.
5
5
 
6
6
  THIS FILE IS GENERATED.THIS FILE IS GENERATED. THIS FILE IS GENERATED.
package/browser/README.md CHANGED
@@ -1,24 +1,24 @@
1
- # MyLib
2
-
3
- This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 13.2.0.
4
-
5
- ## Code scaffolding
6
-
7
- Run `ng generate component component-name --project my-lib` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project my-lib`.
8
- > Note: Don't forget to add `--project my-lib` or else it will be added to the default project in your `angular.json` file.
9
-
10
- ## Build
11
-
12
- Run `ng build my-lib` to build the project. The build artifacts will be stored in the `dist/` directory.
13
-
14
- ## Publishing
15
-
16
- After building your library with `ng build my-lib`, go to the dist folder `cd dist/my-lib` and run `npm publish`.
17
-
18
- ## Running unit tests
19
-
20
- Run `ng test my-lib` to execute the unit tests via [Karma](https://karma-runner.github.io).
21
-
22
- ## Further help
23
-
24
- To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
1
+ # MyLib
2
+
3
+ This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 13.2.0.
4
+
5
+ ## Code scaffolding
6
+
7
+ Run `ng generate component component-name --project my-lib` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project my-lib`.
8
+ > Note: Don't forget to add `--project my-lib` or else it will be added to the default project in your `angular.json` file.
9
+
10
+ ## Build
11
+
12
+ Run `ng build my-lib` to build the project. The build artifacts will be stored in the `dist/` directory.
13
+
14
+ ## Publishing
15
+
16
+ After building your library with `ng build my-lib`, go to the dist folder `cd dist/my-lib` and run `npm publish`.
17
+
18
+ ## Running unit tests
19
+
20
+ Run `ng test my-lib` to execute the unit tests via [Karma](https://karma-runner.github.io).
21
+
22
+ ## Further help
23
+
24
+ To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
package/client/README.md CHANGED
@@ -1,24 +1,24 @@
1
- # MyLib
2
-
3
- This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 13.2.0.
4
-
5
- ## Code scaffolding
6
-
7
- Run `ng generate component component-name --project my-lib` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project my-lib`.
8
- > Note: Don't forget to add `--project my-lib` or else it will be added to the default project in your `angular.json` file.
9
-
10
- ## Build
11
-
12
- Run `ng build my-lib` to build the project. The build artifacts will be stored in the `dist/` directory.
13
-
14
- ## Publishing
15
-
16
- After building your library with `ng build my-lib`, go to the dist folder `cd dist/my-lib` and run `npm publish`.
17
-
18
- ## Running unit tests
19
-
20
- Run `ng test my-lib` to execute the unit tests via [Karma](https://karma-runner.github.io).
21
-
22
- ## Further help
23
-
24
- To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
1
+ # MyLib
2
+
3
+ This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 13.2.0.
4
+
5
+ ## Code scaffolding
6
+
7
+ Run `ng generate component component-name --project my-lib` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module --project my-lib`.
8
+ > Note: Don't forget to add `--project my-lib` or else it will be added to the default project in your `angular.json` file.
9
+
10
+ ## Build
11
+
12
+ Run `ng build my-lib` to build the project. The build artifacts will be stored in the `dist/` directory.
13
+
14
+ ## Publishing
15
+
16
+ After building your library with `ng build my-lib`, go to the dist folder `cd dist/my-lib` and run `npm publish`.
17
+
18
+ ## Running unit tests
19
+
20
+ Run `ng test my-lib` to execute the unit tests via [Karma](https://karma-runner.github.io).
21
+
22
+ ## Further help
23
+
24
+ To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI Overview and Command Reference](https://angular.io/cli) page.
@@ -51,7 +51,7 @@
51
51
  ]
52
52
  },
53
53
  "name": "ng2-logger",
54
- "version": "16.5.8",
54
+ "version": "16.5.10",
55
55
  "description": "isomorphic logger for browser/server in typescript",
56
56
  "repository": {
57
57
  "type": "git",
@@ -81,11 +81,11 @@
81
81
  "json-stringify-safe": "5.0.1",
82
82
  "json5": "2.2.1",
83
83
  "randomcolor": "0.5.3",
84
- "tnp-config": "~16.5.7"
84
+ "tnp-config": "~16.5.9"
85
85
  },
86
86
  "license": "MIT",
87
87
  "private": false,
88
- "lastBuildTagHash": "73ef231ead38ee76f4a11c781b4b240047f477da",
88
+ "lastBuildTagHash": "ebc1866a60b3e9b1268d62e7b7f77b3e0023df62",
89
89
  "peerDependencies": {},
90
90
  "devDependencies": {
91
91
  "@angular-devkit/build-angular": "~16.0.5",
@@ -168,9 +168,9 @@
168
168
  "angular-material-css-vars": "5.0.2",
169
169
  "angular-resize-event": "3.2.0",
170
170
  "animate.css": "4.1.1 ",
171
- "any-project-cli": "~16.5.6",
171
+ "any-project-cli": "~16.5.7",
172
172
  "axios": "1.3.5",
173
- "background-worker-process": "~16.5.6",
173
+ "background-worker-process": "~16.5.7",
174
174
  "base32": "0.0.7",
175
175
  "bcryptjs": "2.4.3",
176
176
  "better-sqlite3": "7.6.2",
@@ -216,13 +216,13 @@
216
216
  "file-saver": "2.0.5",
217
217
  "file-type": "18.5.0",
218
218
  "firedev": "^16",
219
- "firedev-crud": "~16.5.6",
220
- "firedev-crud-deamon": "~16.5.6",
221
- "firedev-ports": "~16.5.6",
222
- "firedev-storage": "~16.5.6",
223
- "firedev-type-sql": "~16.5.6",
224
- "firedev-typeorm": "~16.5.7",
225
- "firedev-ui": "~16.5.6",
219
+ "firedev-crud": "~16.5.7",
220
+ "firedev-crud-deamon": "~16.5.7",
221
+ "firedev-ports": "~16.5.7",
222
+ "firedev-storage": "~16.5.7",
223
+ "firedev-type-sql": "~16.5.7",
224
+ "firedev-typeorm": "~16.5.8",
225
+ "firedev-ui": "~16.5.7",
226
226
  "fkill": "6.1.0",
227
227
  "font-awesome": "4.7.0",
228
228
  "form-data": "4.0.0",
@@ -239,11 +239,11 @@
239
239
  "image-focus": "1.2.1",
240
240
  "immer": "10.0.2",
241
241
  "immutable": "4.3.0",
242
- "incremental-compiler": "~16.5.16",
242
+ "incremental-compiler": "~16.5.17",
243
243
  "inquirer": "7.3.3",
244
244
  "inquirer-autocomplete-prompt": "1.3.0",
245
245
  "is-elevated": "3.0.0",
246
- "isomorphic-region-loader": "~16.5.6",
246
+ "isomorphic-region-loader": "~16.5.7",
247
247
  "istanbul-instrumenter-loader": "2.0.0",
248
248
  "jest": "29.5.0",
249
249
  "jest-date-mock": "1.0.8",
@@ -253,8 +253,8 @@
253
253
  "jimp": "0.22.8",
254
254
  "joi": "17.9.2",
255
255
  "jscodeshift": "0.6.3",
256
- "json10": "~16.5.6",
257
- "json10-writer": "~16.5.6",
256
+ "json10": "~16.5.7",
257
+ "json10-writer": "~16.5.7",
258
258
  "json5-writer": "0.2.0",
259
259
  "jszip": "3.10.1",
260
260
  "karma-cli": "1.0.1",
@@ -262,23 +262,23 @@
262
262
  "localforage": "1.10.0",
263
263
  "lockfile": "1.0.4",
264
264
  "lodash": "4.17.20",
265
- "lodash-walk-object": "~16.5.6",
265
+ "lodash-walk-object": "~16.5.7",
266
266
  "lowdb": "1.0.0",
267
- "magic-renamer": "~16.5.6",
267
+ "magic-renamer": "~16.5.7",
268
268
  "material-design-icons": "3.0.1",
269
269
  "method-override": "2.3.10",
270
270
  "minimist": "1.2.0",
271
271
  "mkdirp": "0.5.1",
272
272
  "mocha": "10.2.0",
273
273
  "moment": "2.29.3",
274
- "morphi": "~16.5.6",
274
+ "morphi": "~16.5.7",
275
275
  "ng-for-track-by-property": "16.0.1",
276
276
  "ng-in-viewport": "15.0.2",
277
277
  "ng-lock": "16.0.1",
278
278
  "ng-packagr": "16.0.1",
279
- "ng-talkback": "~16.5.6",
280
- "ng2-logger": "~16.5.6",
281
- "ng2-rest": "~16.5.6",
279
+ "ng-talkback": "~16.5.8",
280
+ "ng2-logger": "~16.5.9",
281
+ "ng2-rest": "~16.5.7",
282
282
  "ngx-ace-wrapper": "14.0.0",
283
283
  "ngx-editor": "15.3.0",
284
284
  "ngx-highlightjs": "9.0.0",
@@ -291,7 +291,7 @@
291
291
  "ngx-scrolltop": "6.0.0",
292
292
  "ngx-store": "3.1.1",
293
293
  "ngx-typed-js": "2.1.1",
294
- "node-cli-tester": "~16.5.6",
294
+ "node-cli-tester": "~16.5.7",
295
295
  "node-localstorage": "2.1.6",
296
296
  "node-notifier": "6.0.0",
297
297
  "node-polyfill-webpack-plugin": "2.0.1",
@@ -317,7 +317,7 @@
317
317
  "ps-node": "0.1.6",
318
318
  "q": "1.5.1",
319
319
  "rallax.js": "2.0.4",
320
- "record-replay-req-res-scenario": "~16.5.6",
320
+ "record-replay-req-res-scenario": "~16.5.7",
321
321
  "reflect-metadata": "0.1.10",
322
322
  "rimraf": "2.6.2",
323
323
  "rxjs": "~7.8.0",
@@ -328,7 +328,7 @@
328
328
  "socket.io": "2.4.1",
329
329
  "sort-package-json": "1.11.0",
330
330
  "sql.js": "1.8.0",
331
- "static-columns": "~16.5.7",
331
+ "static-columns": "~16.5.8",
332
332
  "string-similarity": "4.0.2",
333
333
  "sudo-block": "3.0.0",
334
334
  "supertest": "6.3.3",
@@ -336,11 +336,11 @@
336
336
  "systeminformation": "3.45.7",
337
337
  "task.js": "0.1.5",
338
338
  "threads": "1.7.0",
339
- "tnp-cli": "~16.5.6",
340
- "tnp-core": "~16.5.12",
341
- "tnp-db": "~16.5.6",
342
- "tnp-helpers": "~16.5.7",
343
- "tnp-models": "~16.5.6",
339
+ "tnp-cli": "~16.5.7",
340
+ "tnp-core": "~16.5.14",
341
+ "tnp-db": "~16.5.7",
342
+ "tnp-helpers": "~16.5.8",
343
+ "tnp-models": "~16.5.7",
344
344
  "ts-debug": "1.3.0",
345
345
  "ts-loader": "2.3.1",
346
346
  "ts-node": "10.9.1",
@@ -349,13 +349,13 @@
349
349
  "turndown": "7.1.2",
350
350
  "typeorm": "~0.3.10",
351
351
  "typescript": "~5.0.2",
352
- "typescript-class-helpers": "~16.5.6",
352
+ "typescript-class-helpers": "~16.5.8",
353
353
  "typescript-formatter": "~7.2.2",
354
354
  "underscore": "1.9.1",
355
355
  "uuid": "8.3.2",
356
356
  "validator": "9.2.0",
357
357
  "video.js": "8.3.0",
358
- "vpn-split": "~16.5.7",
358
+ "vpn-split": "~16.5.9",
359
359
  "watch": "1.0.2",
360
360
  "yup": "1.1.1",
361
361
  "zone.js": "~0.13.0"
package/package.json CHANGED
@@ -51,7 +51,7 @@
51
51
  ]
52
52
  },
53
53
  "name": "ng2-logger",
54
- "version": "16.5.8",
54
+ "version": "16.5.10",
55
55
  "description": "isomorphic logger for browser/server in typescript",
56
56
  "repository": {
57
57
  "type": "git",
@@ -81,11 +81,11 @@
81
81
  "json-stringify-safe": "5.0.1",
82
82
  "json5": "2.2.1",
83
83
  "randomcolor": "0.5.3",
84
- "tnp-config": "~16.5.7"
84
+ "tnp-config": "~16.5.9"
85
85
  },
86
86
  "license": "MIT",
87
87
  "private": false,
88
- "lastBuildTagHash": "73ef231ead38ee76f4a11c781b4b240047f477da",
88
+ "lastBuildTagHash": "ebc1866a60b3e9b1268d62e7b7f77b3e0023df62",
89
89
  "peerDependencies": {},
90
90
  "devDependencies": {}
91
91
  }