@eso-status/forum-message 1.0.13 → 2.0.0-dev.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/LICENSE.md +1 -1
- package/README.md +100 -93
- package/lib/connector.d.ts +68 -0
- package/lib/connector.js +122 -0
- package/lib/const.d.ts +9 -0
- package/lib/const.js +12 -0
- package/lib/formatter/date.formatter.d.ts +97 -0
- package/lib/formatter/date.formatter.js +161 -0
- package/lib/identifier/slug.identifier.d.ts +94 -0
- package/lib/identifier/slug.identifier.js +139 -0
- package/lib/identifier/slug.match.d.ts +26 -0
- package/lib/identifier/slug.match.js +35 -0
- package/lib/identifier/status.identifier.d.ts +63 -0
- package/lib/identifier/status.identifier.js +85 -0
- package/lib/index.d.ts +11 -13
- package/lib/index.js +14 -72
- package/lib/raw.d.ts +42 -0
- package/lib/raw.js +58 -0
- package/lib/type/messageType.type.d.ts +4 -0
- package/lib/type/messageType.type.js +3 -0
- package/lib/type/remoteDownRawStatus.type.d.ts +4 -0
- package/lib/type/remoteDownRawStatus.type.js +3 -0
- package/lib/type/remotePlannedRawStatus.type.d.ts +4 -0
- package/lib/type/remotePlannedRawStatus.type.js +3 -0
- package/lib/type/remoteRawSlug.type.d.ts +11 -0
- package/lib/type/remoteRawSlug.type.js +3 -0
- package/lib/type/remoteRawStatus.type.d.ts +7 -0
- package/lib/type/remoteRawStatus.type.js +3 -0
- package/lib/type/remoteServerPcEuRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerPcEuRawSlug.type.js +3 -0
- package/lib/type/remoteServerPcNaRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerPcNaRawSlug.type.js +3 -0
- package/lib/type/remoteServerPcPtsRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerPcPtsRawSlug.type.js +3 -0
- package/lib/type/remoteServerPsEuRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerPsEuRawSlug.type.js +3 -0
- package/lib/type/remoteServerPsNaRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerPsNaRawSlug.type.js +3 -0
- package/lib/type/remoteServerXboxEuRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerXboxEuRawSlug.type.js +3 -0
- package/lib/type/remoteServerXboxNaRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServerXboxNaRawSlug.type.js +3 -0
- package/lib/type/remoteServiceStoreEsoRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServiceStoreEsoRawSlug.type.js +3 -0
- package/lib/type/remoteServiceSystemAccountRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServiceSystemAccountRawSlug.type.js +3 -0
- package/lib/type/remoteServiceWebSiteRawSlug.type.d.ts +4 -0
- package/lib/type/remoteServiceWebSiteRawSlug.type.js +3 -0
- package/lib/type/remoteUpRawStatus.type.d.ts +4 -0
- package/lib/type/remoteUpRawStatus.type.js +3 -0
- package/lib/type/sourceUrl.type.d.ts +4 -0
- package/lib/type/sourceUrl.type.js +3 -0
- package/package.json +110 -37
- package/lib/classes/ForumMessageElement.d.ts +0 -110
- package/lib/classes/ForumMessageElement.js +0 -386
- package/lib/connectors/ForumMessageConnector.d.ts +0 -127
- package/lib/connectors/ForumMessageConnector.js +0 -311
package/lib/index.js
CHANGED
|
@@ -1,77 +1,19 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
12
|
-
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
13
|
-
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
14
|
-
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
15
|
-
function step(op) {
|
|
16
|
-
if (f) throw new TypeError("Generator is already executing.");
|
|
17
|
-
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
18
|
-
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
19
|
-
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
20
|
-
switch (op[0]) {
|
|
21
|
-
case 0: case 1: t = op; break;
|
|
22
|
-
case 4: _.label++; return { value: op[1], done: false };
|
|
23
|
-
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
24
|
-
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
25
|
-
default:
|
|
26
|
-
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
27
|
-
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
28
|
-
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
29
|
-
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
30
|
-
if (t[2]) _.ops.pop();
|
|
31
|
-
_.trys.pop(); continue;
|
|
32
|
-
}
|
|
33
|
-
op = body.call(thisArg, _);
|
|
34
|
-
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
35
|
-
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
36
|
-
}
|
|
37
|
-
};
|
|
38
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
exports.ForumMessageURL = 'https://forums.elderscrollsonline.com/';
|
|
42
|
-
exports.ForumMessagePTSURL = 'https://forums.elderscrollsonline.com/en/categories/pts';
|
|
3
|
+
const const_1 = require("./const");
|
|
4
|
+
const connector_1 = require("./connector");
|
|
43
5
|
/**
|
|
44
|
-
* Class
|
|
6
|
+
* Class for retrieving announcement information
|
|
45
7
|
*/
|
|
46
|
-
|
|
47
|
-
function ForumMessage() {
|
|
48
|
-
}
|
|
8
|
+
class ForumMessage {
|
|
49
9
|
/**
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
if (url === void 0) { url = exports.ForumMessageURL; }
|
|
61
|
-
return __generator(this, function (_a) {
|
|
62
|
-
switch (_a.label) {
|
|
63
|
-
case 0: return [4 /*yield*/, ForumMessageConnector_1.default.getRemoteContent(url)];
|
|
64
|
-
case 1:
|
|
65
|
-
remoteContent = _a.sent();
|
|
66
|
-
slugOfRawContent = ForumMessageConnector_1.default.getRawContentWithSlug(remoteContent);
|
|
67
|
-
rawContentBySlug = ForumMessageConnector_1.default.splitRawContentBySlug(slugOfRawContent);
|
|
68
|
-
rawContentWithRawDate = ForumMessageConnector_1.default.getRawContentWithRawDate(rawContentBySlug);
|
|
69
|
-
data = ForumMessageConnector_1.default.getData(rawContentWithRawDate);
|
|
70
|
-
return [2 /*return*/, ForumMessageConnector_1.default.sortData(data)];
|
|
71
|
-
}
|
|
72
|
-
});
|
|
73
|
-
});
|
|
74
|
-
};
|
|
75
|
-
return ForumMessage;
|
|
76
|
-
}());
|
|
77
|
-
exports.ForumMessage = ForumMessage;
|
|
10
|
+
* Method for retrieving announcement information
|
|
11
|
+
* If no URL is provided as a parameter, the method will return announcement information for https://forums.elderscrollsonline.com
|
|
12
|
+
* @param url URL serving as the source to retrieve announcements
|
|
13
|
+
*/
|
|
14
|
+
static async getData(url) {
|
|
15
|
+
return (await connector_1.default.init(url ?? const_1.ForumMessageURL)).rawEsoStatus;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.default = ForumMessage;
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
package/lib/raw.d.ts
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { SourceUrl } from './type/sourceUrl.type';
|
|
2
|
+
import { EsoStatusRawData } from './interface/esoStatusRawData.interface';
|
|
3
|
+
/**
|
|
4
|
+
* Class containing announcement information
|
|
5
|
+
*/
|
|
6
|
+
export default class Raw {
|
|
7
|
+
private url;
|
|
8
|
+
private raw;
|
|
9
|
+
/**
|
|
10
|
+
* Status identification class
|
|
11
|
+
* @private
|
|
12
|
+
*/
|
|
13
|
+
private readonly statusIdentifier;
|
|
14
|
+
/**
|
|
15
|
+
* Class for identifying and formatting the date(s)
|
|
16
|
+
* @private
|
|
17
|
+
*/
|
|
18
|
+
private readonly dateFormatter;
|
|
19
|
+
/**
|
|
20
|
+
* Class for identifying the list of slugs
|
|
21
|
+
* @private
|
|
22
|
+
*/
|
|
23
|
+
private slugsIdentifier;
|
|
24
|
+
/**
|
|
25
|
+
* List of information about slugs found in the announcement
|
|
26
|
+
*/
|
|
27
|
+
matches: EsoStatusRawData[];
|
|
28
|
+
/**
|
|
29
|
+
* @param url URL used as the source to retrieve announcements
|
|
30
|
+
* @param raw Raw data of the announcement
|
|
31
|
+
*/
|
|
32
|
+
constructor(url: SourceUrl, raw: string);
|
|
33
|
+
/**
|
|
34
|
+
* Method for formatting each slug found in the announcement to RawEsoStatus
|
|
35
|
+
* @private
|
|
36
|
+
*/
|
|
37
|
+
private split;
|
|
38
|
+
/**
|
|
39
|
+
* Method for generating the RawEsoStatus object
|
|
40
|
+
*/
|
|
41
|
+
private getRawEsoStatus;
|
|
42
|
+
}
|
package/lib/raw.js
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const status_identifier_1 = require("./identifier/status.identifier");
|
|
4
|
+
const date_formatter_1 = require("./formatter/date.formatter");
|
|
5
|
+
const slug_identifier_1 = require("./identifier/slug.identifier");
|
|
6
|
+
/**
|
|
7
|
+
* Class containing announcement information
|
|
8
|
+
*/
|
|
9
|
+
class Raw {
|
|
10
|
+
/**
|
|
11
|
+
* @param url URL used as the source to retrieve announcements
|
|
12
|
+
* @param raw Raw data of the announcement
|
|
13
|
+
*/
|
|
14
|
+
constructor(url, raw) {
|
|
15
|
+
this.url = url;
|
|
16
|
+
this.raw = raw;
|
|
17
|
+
/**
|
|
18
|
+
* List of information about slugs found in the announcement
|
|
19
|
+
*/
|
|
20
|
+
this.matches = [];
|
|
21
|
+
this.statusIdentifier = new status_identifier_1.default(this.raw);
|
|
22
|
+
this.dateFormatter = new date_formatter_1.default(this.raw);
|
|
23
|
+
this.slugsIdentifier = new slug_identifier_1.default(this.raw);
|
|
24
|
+
this.split();
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Method for formatting each slug found in the announcement to RawEsoStatus
|
|
28
|
+
* @private
|
|
29
|
+
*/
|
|
30
|
+
split() {
|
|
31
|
+
this.matches = this.slugsIdentifier.slugMatches.map((slugMatch) => this.getRawEsoStatus(slugMatch));
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Method for generating the RawEsoStatus object
|
|
35
|
+
*/
|
|
36
|
+
getRawEsoStatus(slugMatch) {
|
|
37
|
+
const rawEsoStatus = {
|
|
38
|
+
source: this.url,
|
|
39
|
+
raw: this.raw,
|
|
40
|
+
slug: slugMatch.slug,
|
|
41
|
+
type: slugMatch.getType(),
|
|
42
|
+
support: slugMatch.getSupport(),
|
|
43
|
+
zone: slugMatch.getZone(),
|
|
44
|
+
status: this.statusIdentifier.status,
|
|
45
|
+
rawSlug: slugMatch.rawSlug,
|
|
46
|
+
};
|
|
47
|
+
if (this.dateFormatter.rawDate) {
|
|
48
|
+
rawEsoStatus.rawDate = this.dateFormatter.rawDate;
|
|
49
|
+
rawEsoStatus.dates = this.dateFormatter.dates;
|
|
50
|
+
}
|
|
51
|
+
if (this.statusIdentifier.rawStatus) {
|
|
52
|
+
rawEsoStatus.rawStatus = this.statusIdentifier.rawStatus;
|
|
53
|
+
}
|
|
54
|
+
return rawEsoStatus;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
exports.default = Raw;
|
|
58
|
+
//# sourceMappingURL=raw.js.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { RemoteServerPcEuRawSlug } from './remoteServerPcEuRawSlug.type';
|
|
2
|
+
import { RemoteServerPcNaRawSlug } from './remoteServerPcNaRawSlug.type';
|
|
3
|
+
import { RemoteServerPcPtsRawSlug } from './remoteServerPcPtsRawSlug.type';
|
|
4
|
+
import { RemoteServerPsEuRawSlug } from './remoteServerPsEuRawSlug.type';
|
|
5
|
+
import { RemoteServerXboxEuRawSlug } from './remoteServerXboxEuRawSlug.type';
|
|
6
|
+
import { RemoteServiceStoreEsoRawSlug } from './remoteServiceStoreEsoRawSlug.type';
|
|
7
|
+
import { RemoteServiceWebSiteRawSlug } from './remoteServiceWebSiteRawSlug.type';
|
|
8
|
+
/**
|
|
9
|
+
* Different slugs of announcements
|
|
10
|
+
*/
|
|
11
|
+
export type RemoteRawSlug = RemoteServerPcEuRawSlug | RemoteServerPcNaRawSlug | RemoteServerPcPtsRawSlug | RemoteServerPsEuRawSlug | RemoteServerXboxEuRawSlug | RemoteServiceStoreEsoRawSlug | RemoteServiceWebSiteRawSlug;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { RemoteUpRawStatus } from './remoteUpRawStatus.type';
|
|
2
|
+
import { RemoteDownRawStatus } from './remoteDownRawStatus.type';
|
|
3
|
+
import { RemotePlannedRawStatus } from './remotePlannedRawStatus.type';
|
|
4
|
+
/**
|
|
5
|
+
* Different statuses of announcements
|
|
6
|
+
*/
|
|
7
|
+
export type RemoteRawStatus = RemoteUpRawStatus | RemoteDownRawStatus | RemotePlannedRawStatus;
|
package/package.json
CHANGED
|
@@ -1,64 +1,137 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eso-status/forum-message",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "Library
|
|
3
|
+
"version": "2.0.0-dev.0",
|
|
4
|
+
"description": "Library for retrieving and formatting data, available at https://forums.elderscrollsonline.com or https://forums.elderscrollsonline.com/en/categories/pts",
|
|
5
|
+
"author": "@dov118 <contact@dov118.dev> (https://dov118.dev)",
|
|
5
6
|
"main": "lib/index.js",
|
|
6
|
-
"
|
|
7
|
-
|
|
8
|
-
"lint": "eslint tests src --ext .ts",
|
|
9
|
-
"lint:fix": "eslint tests src --ext .ts --fix",
|
|
10
|
-
"build": "rm -R -f lib/* && tsc",
|
|
11
|
-
"test": "jest",
|
|
12
|
-
"start": "node .",
|
|
13
|
-
"dev": "npm run build && npm run start",
|
|
14
|
-
"dev:test": "npm run lint && npm run build && npm run test",
|
|
15
|
-
"watch": "nodemon --exec npm run dev",
|
|
16
|
-
"watch:test": "nodemon --exec npm run dev:test"
|
|
17
|
-
},
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"engineStrict": true,
|
|
18
9
|
"files": [
|
|
19
|
-
"lib/
|
|
20
|
-
"lib/
|
|
21
|
-
"lib/
|
|
22
|
-
"lib/
|
|
10
|
+
"lib/formatter/date.formatter.d.ts",
|
|
11
|
+
"lib/formatter/date.formatter.js",
|
|
12
|
+
"lib/identifier/slug.identifier.d.ts",
|
|
13
|
+
"lib/identifier/slug.identifier.js",
|
|
14
|
+
"lib/identifier/slug.match.d.ts",
|
|
15
|
+
"lib/identifier/slug.match.js",
|
|
16
|
+
"lib/identifier/status.identifier.d.ts",
|
|
17
|
+
"lib/identifier/status.identifier.js",
|
|
18
|
+
"lib/type/messageType.type.d.ts",
|
|
19
|
+
"lib/type/messageType.type.js",
|
|
20
|
+
"lib/type/remoteDownRawStatus.type.d.ts",
|
|
21
|
+
"lib/type/remoteDownRawStatus.type.js",
|
|
22
|
+
"lib/type/remotePlannedRawStatus.type.d.ts",
|
|
23
|
+
"lib/type/remotePlannedRawStatus.type.js",
|
|
24
|
+
"lib/type/remoteRawSlug.type.d.ts",
|
|
25
|
+
"lib/type/remoteRawSlug.type.js",
|
|
26
|
+
"lib/type/remoteRawStatus.type.d.ts",
|
|
27
|
+
"lib/type/remoteRawStatus.type.js",
|
|
28
|
+
"lib/type/remoteServerPcEuRawSlug.type.d.ts",
|
|
29
|
+
"lib/type/remoteServerPcEuRawSlug.type.js",
|
|
30
|
+
"lib/type/remoteServerPcNaRawSlug.type.d.ts",
|
|
31
|
+
"lib/type/remoteServerPcNaRawSlug.type.js",
|
|
32
|
+
"lib/type/remoteServerPcPtsRawSlug.type.d.ts",
|
|
33
|
+
"lib/type/remoteServerPcPtsRawSlug.type.js",
|
|
34
|
+
"lib/type/remoteServerPsEuRawSlug.type.d.ts",
|
|
35
|
+
"lib/type/remoteServerPsEuRawSlug.type.js",
|
|
36
|
+
"lib/type/remoteServerPsNaRawSlug.type.d.ts",
|
|
37
|
+
"lib/type/remoteServerPsNaRawSlug.type.js",
|
|
38
|
+
"lib/type/remoteServerXboxEuRawSlug.type.d.ts",
|
|
39
|
+
"lib/type/remoteServerXboxEuRawSlug.type.js",
|
|
40
|
+
"lib/type/remoteServerXboxNaRawSlug.type.d.ts",
|
|
41
|
+
"lib/type/remoteServerXboxNaRawSlug.type.js",
|
|
42
|
+
"lib/type/remoteServiceStoreEsoRawSlug.type.d.ts",
|
|
43
|
+
"lib/type/remoteServiceStoreEsoRawSlug.type.js",
|
|
44
|
+
"lib/type/remoteServiceSystemAccountRawSlug.type.d.ts",
|
|
45
|
+
"lib/type/remoteServiceSystemAccountRawSlug.type.js",
|
|
46
|
+
"lib/type/remoteServiceWebSiteRawSlug.type.d.ts",
|
|
47
|
+
"lib/type/remoteServiceWebSiteRawSlug.type.js",
|
|
48
|
+
"lib/type/remoteUpRawStatus.type.d.ts",
|
|
49
|
+
"lib/type/remoteUpRawStatus.type.js",
|
|
50
|
+
"lib/type/sourceUrl.type.d.ts",
|
|
51
|
+
"lib/type/sourceUrl.type.js",
|
|
52
|
+
"lib/connector.d.ts",
|
|
53
|
+
"lib/connector.js",
|
|
54
|
+
"lib/const.d.ts",
|
|
55
|
+
"lib/const.js",
|
|
23
56
|
"lib/index.d.ts",
|
|
24
57
|
"lib/index.js",
|
|
25
|
-
".
|
|
58
|
+
"lib/raw.d.ts",
|
|
59
|
+
"lib/raw.js",
|
|
60
|
+
".npmrc,",
|
|
26
61
|
"LICENSE.md",
|
|
27
62
|
"package.json",
|
|
28
63
|
"README.md"
|
|
29
64
|
],
|
|
30
|
-
"engineStrict": true,
|
|
31
65
|
"engines": {
|
|
32
|
-
"node": ">=
|
|
66
|
+
"node": ">=16.10.0 || >=18.12.0 || >=20.0.0"
|
|
33
67
|
},
|
|
68
|
+
"bugs": {
|
|
69
|
+
"url": "https://github.com/eso-status/forum-message/issues"
|
|
70
|
+
},
|
|
71
|
+
"homepage": "https://github.com/eso-status/forum-message#readme",
|
|
34
72
|
"repository": {
|
|
35
73
|
"type": "git",
|
|
36
|
-
"url": "git@github.com:eso-status/forum-message
|
|
74
|
+
"url": "git@github.com:eso-status/forum-message.git"
|
|
37
75
|
},
|
|
38
|
-
"
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
"
|
|
76
|
+
"scripts": {
|
|
77
|
+
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
|
|
78
|
+
"lint": "eslint \"{src,test}/**/*.ts\"",
|
|
79
|
+
"lint:fix": "eslint \"{src,test}/**/*.ts\" --fix",
|
|
80
|
+
"build": "rm -R -f lib/* && tsc --project tsconfig.build.json",
|
|
81
|
+
"dev": "npm run build && node .",
|
|
82
|
+
"watch": "nodemon --exec npm run dev",
|
|
83
|
+
"test": "npm run build && jest --runInBand --setupFiles",
|
|
84
|
+
"test:watch": "jest --runInBand --watch --setupFiles",
|
|
85
|
+
"test:cov": "jest --runInBand --coverage --setupFiles",
|
|
86
|
+
"prepare": "husky"
|
|
87
|
+
},
|
|
88
|
+
"dependencies": {
|
|
89
|
+
"@eso-status/types": "2.0.0-dev.4",
|
|
90
|
+
"axios": "1.7.7",
|
|
91
|
+
"moment": "2.30.1"
|
|
42
92
|
},
|
|
43
|
-
"homepage": "https://github.com/eso-status/forum-message-dev#readme",
|
|
44
93
|
"devDependencies": {
|
|
45
|
-
"@eso-status/types": "1.0.7",
|
|
46
94
|
"@types/jest": "29.5.12",
|
|
47
|
-
"@types/node": "22.5.1",
|
|
48
|
-
"@typescript-eslint/eslint-plugin": "7.18.0",
|
|
49
|
-
"@typescript-eslint/parser": "7.18.0",
|
|
50
|
-
"@typescript-eslint/typescript-estree": "7.18.0",
|
|
51
95
|
"eslint": "8.57.0",
|
|
52
96
|
"eslint-config-airbnb-base": "15.0.0",
|
|
53
|
-
"eslint-
|
|
54
|
-
"eslint-
|
|
97
|
+
"eslint-config-airbnb-typescript": "18.0.0",
|
|
98
|
+
"eslint-config-prettier": "9.1.0",
|
|
99
|
+
"eslint-plugin-jest": "28.8.3",
|
|
100
|
+
"eslint-plugin-prettier": "5.2.1",
|
|
101
|
+
"eslint-plugin-sonarjs": "2.0.2",
|
|
102
|
+
"eslint-plugin-unused-imports": "4.1.3",
|
|
103
|
+
"husky": "9.1.5",
|
|
55
104
|
"jest": "29.7.0",
|
|
56
105
|
"nodemon": "3.1.4",
|
|
106
|
+
"prettier": "3.3.3",
|
|
57
107
|
"ts-jest": "29.2.5",
|
|
58
108
|
"typescript": "5.5.4"
|
|
59
109
|
},
|
|
60
|
-
"
|
|
61
|
-
"
|
|
62
|
-
|
|
110
|
+
"jest": {
|
|
111
|
+
"moduleFileExtensions": [
|
|
112
|
+
"js",
|
|
113
|
+
"json",
|
|
114
|
+
"ts"
|
|
115
|
+
],
|
|
116
|
+
"rootDir": "./",
|
|
117
|
+
"testRegex": ".*\\.e2e-spec\\.ts|.*\\.spec\\.ts$",
|
|
118
|
+
"transform": {
|
|
119
|
+
"^.+\\.ts$": "ts-jest"
|
|
120
|
+
},
|
|
121
|
+
"collectCoverageFrom": [
|
|
122
|
+
"src/**/*.ts"
|
|
123
|
+
],
|
|
124
|
+
"coverageDirectory": "./coverage",
|
|
125
|
+
"testEnvironment": "node",
|
|
126
|
+
"setupFiles": [
|
|
127
|
+
"dotenv/config"
|
|
128
|
+
],
|
|
129
|
+
"moduleDirectories": [
|
|
130
|
+
"node_modules",
|
|
131
|
+
"src"
|
|
132
|
+
],
|
|
133
|
+
"modulePaths": [
|
|
134
|
+
"<rootDir>"
|
|
135
|
+
]
|
|
63
136
|
}
|
|
64
137
|
}
|