@static-suite/static-suite-data-server 1.0.2 → 1.0.4
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.
|
@@ -17,7 +17,7 @@ exports.dumpMetadataHelper = {
|
|
|
17
17
|
current: workDir_1.unixEpochUniqueId,
|
|
18
18
|
dumps: [],
|
|
19
19
|
};
|
|
20
|
-
let currentDumpMetadata
|
|
20
|
+
let currentDumpMetadata;
|
|
21
21
|
try {
|
|
22
22
|
currentDumpMetadata = JSON.parse(fs_1.default.readFileSync(metadataFilepath).toString());
|
|
23
23
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -28,7 +28,7 @@ exports.isJsonFile = isJsonFile;
|
|
|
28
28
|
* @returns The file contents as a string if file is found, or null otherwise.
|
|
29
29
|
*/
|
|
30
30
|
const readFile = (filePath) => {
|
|
31
|
-
let content
|
|
31
|
+
let content;
|
|
32
32
|
try {
|
|
33
33
|
content = fs_1.default.readFileSync(filePath, { encoding: 'utf8', flag: 'r' });
|
|
34
34
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@static-suite/static-suite-data-server",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "A flexible, fast and developer friendly Data Server for Static Suite",
|
|
5
5
|
"main": "./dist/lib/index.js",
|
|
6
6
|
"typings": "./dist/lib/index.d.ts",
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"decache": "^4.6.1",
|
|
22
22
|
"express": "^5.1.0",
|
|
23
23
|
"fast-glob": "^3.2.12",
|
|
24
|
-
"marked": "^
|
|
24
|
+
"marked": "^18.0.3",
|
|
25
25
|
"microtime": "^3.1.1",
|
|
26
26
|
"mime-types": "^3.0.1",
|
|
27
27
|
"pug": "^3.0.3",
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"prepare": "husky"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@eslint/js": "^
|
|
51
|
+
"@eslint/js": "^10.0.1",
|
|
52
52
|
"@types/cors": "^2.8.13",
|
|
53
53
|
"@types/express": "^5.0.3",
|
|
54
54
|
"@types/jest": "^30.0.0",
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"@types/yargs": "^17.0.22",
|
|
60
60
|
"@typescript-eslint/eslint-plugin": "^8.43.0",
|
|
61
61
|
"@typescript-eslint/parser": "^8.43.0",
|
|
62
|
-
"eslint": "^
|
|
62
|
+
"eslint": "^10.3.0",
|
|
63
63
|
"eslint-import-resolver-typescript": "^4.4.4",
|
|
64
64
|
"eslint-plugin-import": "^2.27.5",
|
|
65
65
|
"eslint-plugin-prettier": "^5.5.4",
|
|
@@ -14,7 +14,7 @@ export const dumpMetadataHelper = {
|
|
|
14
14
|
current: unixEpochUniqueId,
|
|
15
15
|
dumps: [],
|
|
16
16
|
};
|
|
17
|
-
let currentDumpMetadata
|
|
17
|
+
let currentDumpMetadata;
|
|
18
18
|
try {
|
|
19
19
|
currentDumpMetadata = JSON.parse(
|
|
20
20
|
fs.readFileSync(metadataFilepath).toString(),
|
|
@@ -25,7 +25,7 @@ export const isJsonFile = (filepath: string): boolean =>
|
|
|
25
25
|
* @returns The file contents as a string if file is found, or null otherwise.
|
|
26
26
|
*/
|
|
27
27
|
export const readFile = (filePath: string): string | null => {
|
|
28
|
-
let content
|
|
28
|
+
let content;
|
|
29
29
|
try {
|
|
30
30
|
content = fs.readFileSync(filePath, { encoding: 'utf8', flag: 'r' });
|
|
31
31
|
} catch (error) {
|
|
@@ -115,4 +115,3 @@ export const removeEmptyDirsUpwards = (dir: string): void => {
|
|
|
115
115
|
removeEmptyDirsUpwards(path.dirname(dir));
|
|
116
116
|
}
|
|
117
117
|
};
|
|
118
|
-
|