@8ms/helpers 2.3.2 → 2.3.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.
- package/.github/generate-exports.js +39 -48
- package/.yarn/install-state.gz +0 -0
- package/api/ApiResponseClass.js +12 -12
- package/api/api.d.ts +2 -2
- package/api/api.js +2 -2
- package/api/functions.js +7 -7
- package/brightData/serpApi/server/brightDataSerpApi.d.ts +2 -2
- package/brightData/serpApi/server/brightDataSerpApi.js +1 -1
- package/brightData/serpApi/server/getAsyncRequestId.js +2 -2
- package/brightData/webScraperIde/server/getRealtime.js +5 -5
- package/crud/crud.d.ts +2 -2
- package/crud/crud.js +1 -1
- package/date/calculation.d.ts +3 -0
- package/date/calculation.js +3 -0
- package/date/date.d.ts +2 -2
- package/date/date.js +1 -1
- package/date/financialYear.d.ts +1 -1
- package/date/financialYear.js +1 -1
- package/environment/environment.d.ts +4 -4
- package/environment/environment.js +9 -9
- package/file/getFileKey.js +2 -2
- package/googleAds/keywordPlanner/server/googleAdsKeywordPlanner.d.ts +2 -2
- package/googleAds/keywordPlanner/server/googleAdsKeywordPlanner.js +2 -2
- package/googleAds/server/GoogleAdsNamespace.js +1 -2
- package/googlePageSpeed/server/GooglePageSpeedNamespace.d.ts +1 -1
- package/googlePageSpeed/server/GooglePageSpeedNamespace.js +3 -3
- package/googlePageSpeed/server/googlePageSpeed.d.ts +4 -4
- package/googlePageSpeed/server/googlePageSpeed.js +2 -2
- package/inngest/inngest.d.ts +2 -2
- package/inngest/inngest.js +1 -1
- package/littleWarden/server/littleWarden.d.ts +2 -2
- package/littleWarden/server/littleWarden.js +4 -4
- package/lumar/api/server/buildRequest.d.ts +3 -3
- package/lumar/api/server/buildRequest.js +15 -15
- package/lumar/api/server/lumarApi.d.ts +27 -27
- package/lumar/api/server/lumarApi.js +3 -6
- package/lumar/graphql/server/columns.d.ts +28 -27
- package/lumar/graphql/server/columns.js +1 -1
- package/lumar/graphql/server/getData.js +1 -2
- package/lumar/graphql/server/lumarGraphql.d.ts +21 -23
- package/lumar/graphql/server/lumarGraphql.js +2 -6
- package/lumar/graphql/server/queries/getReportDifferences.d.ts +1 -1
- package/lumar/graphql/server/queries/getReportDifferences.js +2 -2
- package/lumar/graphql/server/reportTemplates.d.ts +67 -66
- package/lumar/graphql/server/reportTemplates.js +1 -1
- package/nextAuth/nextAuth.d.ts +3 -3
- package/nextJs/nextJs.js +2 -8
- package/package.json +1 -1
- package/sorting/sorting.d.ts +4 -4
- package/sorting/sorting.js +4 -4
- package/util/isUndefined.js +2 -2
|
@@ -24,7 +24,7 @@ export const littleWardenClient = async (key = "default", config, vaultId, itemI
|
|
|
24
24
|
littleWardenNamespaces.set(key, namespace);
|
|
25
25
|
return namespace;
|
|
26
26
|
};
|
|
27
|
-
export const
|
|
27
|
+
export const littleWardenState = {
|
|
28
28
|
ALL_GOOD: "all_good",
|
|
29
29
|
DANGER: "danger",
|
|
30
30
|
WARNING: "warning",
|
|
@@ -36,7 +36,7 @@ export const isAllGood = ({ field }) => {
|
|
|
36
36
|
let response = false;
|
|
37
37
|
// Check that the status field exists
|
|
38
38
|
if (undefined !== field && undefined !== field["status"]) {
|
|
39
|
-
response =
|
|
39
|
+
response = littleWardenState.ALL_GOOD === field["status"];
|
|
40
40
|
}
|
|
41
41
|
return response;
|
|
42
42
|
};
|
|
@@ -47,7 +47,7 @@ export const isWarning = ({ field }) => {
|
|
|
47
47
|
let response = false;
|
|
48
48
|
// Check that the status field exists
|
|
49
49
|
if (undefined !== field && undefined !== field["status"]) {
|
|
50
|
-
response =
|
|
50
|
+
response = littleWardenState.WARNING === field["status"];
|
|
51
51
|
}
|
|
52
52
|
return response;
|
|
53
53
|
};
|
|
@@ -58,7 +58,7 @@ export const isDanger = ({ field }) => {
|
|
|
58
58
|
let response = false;
|
|
59
59
|
// Check that the status field exists
|
|
60
60
|
if (undefined !== field && undefined !== field["status"]) {
|
|
61
|
-
response =
|
|
61
|
+
response = littleWardenState.DANGER === field["status"];
|
|
62
62
|
}
|
|
63
63
|
return response;
|
|
64
64
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { Filter,
|
|
1
|
+
import { Filter, OrderRow, Report } from "./";
|
|
2
2
|
export type BuildRequestProps = {
|
|
3
3
|
crawlId?: number;
|
|
4
4
|
customPath?: string;
|
|
5
5
|
filters?: Filter[];
|
|
6
6
|
limit?: number;
|
|
7
|
-
orders?:
|
|
7
|
+
orders?: OrderRow[];
|
|
8
8
|
page?: number;
|
|
9
9
|
projectId?: number;
|
|
10
|
-
report?:
|
|
10
|
+
report?: Report;
|
|
11
11
|
subReport?: string;
|
|
12
12
|
};
|
|
13
13
|
export declare const buildRequest: (props: BuildRequestProps) => string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { order, report } from "./";
|
|
2
2
|
export const buildRequest = (props) => {
|
|
3
3
|
let url = `https://api.deepcrawl.com/accounts/37204`;
|
|
4
4
|
// Limit must be greater than 0 but also less than 200
|
|
@@ -15,35 +15,35 @@ export const buildRequest = (props) => {
|
|
|
15
15
|
props.limit = 200;
|
|
16
16
|
}
|
|
17
17
|
// If a report other than List Crawls is selected, Crawl ID must be defined
|
|
18
|
-
if (undefined !== props.report &&
|
|
18
|
+
if (undefined !== props.report && report.LIST_CRAWLS !== props.report && undefined == props.crawlId) {
|
|
19
19
|
throw `Crawl ID must be defined.`;
|
|
20
20
|
}
|
|
21
21
|
switch (props.report) {
|
|
22
|
-
case
|
|
22
|
+
case report.LIST_CRAWLS:
|
|
23
23
|
url += `/projects/${props.projectId}/crawls`;
|
|
24
24
|
break;
|
|
25
|
-
case
|
|
25
|
+
case report.LIST_PROJECTS:
|
|
26
26
|
url += `/projects`;
|
|
27
27
|
break;
|
|
28
|
-
case
|
|
28
|
+
case report.CUSTOM:
|
|
29
29
|
url += props.customPath;
|
|
30
30
|
url = url.replace("[PROJECT]", props.projectId.toString());
|
|
31
31
|
url = url.replace("[CRAWL]", props.crawlId.toString());
|
|
32
32
|
break;
|
|
33
|
-
case
|
|
33
|
+
case report.CRAWL_STATISTICS:
|
|
34
34
|
url += `/projects/${props.projectId}/crawls/${props.crawlId}/statistics`;
|
|
35
35
|
break;
|
|
36
|
-
case
|
|
36
|
+
case report.LIST_REPORTS:
|
|
37
37
|
url += `/projects/${props.projectId}/crawls/${props.crawlId}/reports`;
|
|
38
38
|
break;
|
|
39
|
-
case
|
|
40
|
-
case
|
|
41
|
-
case
|
|
39
|
+
case report.REPORT_ROWS:
|
|
40
|
+
case report.REPORT_STATISTICS:
|
|
41
|
+
case report.REPORT_SUMMARY:
|
|
42
42
|
url += `/projects/${props.projectId}/crawls/${props.crawlId}/reports/${props.subReport}`;
|
|
43
|
-
if (
|
|
43
|
+
if (report.REPORT_ROWS === props.report) {
|
|
44
44
|
url += `/report_rows`;
|
|
45
45
|
}
|
|
46
|
-
else if (
|
|
46
|
+
else if (report.REPORT_STATISTICS === props.report) {
|
|
47
47
|
url += `/statistics`;
|
|
48
48
|
}
|
|
49
49
|
break;
|
|
@@ -66,10 +66,10 @@ export const buildRequest = (props) => {
|
|
|
66
66
|
// Order the data
|
|
67
67
|
if (undefined !== props.orders) {
|
|
68
68
|
url += -1 === url.indexOf("?") ? "?" : "&";
|
|
69
|
-
props.orders.map((
|
|
69
|
+
props.orders.map((orderRow, index) => {
|
|
70
70
|
url += 0 === index ? "sort=" : ",";
|
|
71
|
-
url +=
|
|
72
|
-
url +=
|
|
71
|
+
url += order.DESCENDING === orderRow.direction ? "-" : "";
|
|
72
|
+
url += orderRow.field;
|
|
73
73
|
});
|
|
74
74
|
}
|
|
75
75
|
return url;
|
|
@@ -3,34 +3,34 @@ export type Filter = {
|
|
|
3
3
|
operand: string;
|
|
4
4
|
value: string;
|
|
5
5
|
};
|
|
6
|
-
export declare const
|
|
7
|
-
EQUALS:
|
|
8
|
-
CONTAINS:
|
|
9
|
-
LESS_THAN:
|
|
10
|
-
LESS_THAN_OR_EQUAL:
|
|
11
|
-
GREATER_THAN:
|
|
12
|
-
GREATER_THAN_OR_EQUAL:
|
|
13
|
-
REGEX:
|
|
14
|
-
NOT_REGEX:
|
|
6
|
+
export declare const operand: {
|
|
7
|
+
readonly EQUALS: "eql";
|
|
8
|
+
readonly CONTAINS: "cont";
|
|
9
|
+
readonly LESS_THAN: "lt";
|
|
10
|
+
readonly LESS_THAN_OR_EQUAL: "lte";
|
|
11
|
+
readonly GREATER_THAN: "gt";
|
|
12
|
+
readonly GREATER_THAN_OR_EQUAL: "gte";
|
|
13
|
+
readonly REGEX: "rgx";
|
|
14
|
+
readonly NOT_REGEX: "nrgx";
|
|
15
15
|
};
|
|
16
|
-
export type
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
export type Operand = typeof operand[keyof typeof operand];
|
|
17
|
+
export declare const order: {
|
|
18
|
+
readonly ASCENDING: "asc";
|
|
19
|
+
readonly DESCENDING: "desc";
|
|
19
20
|
};
|
|
20
|
-
export
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
export type Order = typeof order[keyof typeof order];
|
|
22
|
+
export type OrderRow = {
|
|
23
|
+
direction: Order;
|
|
24
|
+
field: string;
|
|
23
25
|
};
|
|
24
|
-
export declare const
|
|
25
|
-
CRAWL_STATISTICS:
|
|
26
|
-
CUSTOM:
|
|
27
|
-
LIST_PROJECTS:
|
|
28
|
-
LIST_CRAWLS:
|
|
29
|
-
LIST_REPORTS:
|
|
30
|
-
REPORT_ROWS:
|
|
31
|
-
REPORT_STATISTICS:
|
|
32
|
-
REPORT_SUMMARY:
|
|
26
|
+
export declare const report: {
|
|
27
|
+
readonly CRAWL_STATISTICS: "crawl_statistics";
|
|
28
|
+
readonly CUSTOM: "custom";
|
|
29
|
+
readonly LIST_PROJECTS: "list_projects";
|
|
30
|
+
readonly LIST_CRAWLS: "list_crawls";
|
|
31
|
+
readonly LIST_REPORTS: "list_reports";
|
|
32
|
+
readonly REPORT_ROWS: "report_rows";
|
|
33
|
+
readonly REPORT_STATISTICS: "report_statistics";
|
|
34
|
+
readonly REPORT_SUMMARY: "report_summary";
|
|
33
35
|
};
|
|
34
|
-
export
|
|
35
|
-
export * from "./getData";
|
|
36
|
-
export * from "./initClient";
|
|
36
|
+
export type Report = typeof report[keyof typeof report];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const
|
|
1
|
+
export const operand = {
|
|
2
2
|
EQUALS: 'eql',
|
|
3
3
|
CONTAINS: 'cont',
|
|
4
4
|
LESS_THAN: 'lt',
|
|
@@ -8,11 +8,11 @@ export const operands = {
|
|
|
8
8
|
REGEX: 'rgx',
|
|
9
9
|
NOT_REGEX: 'nrgx',
|
|
10
10
|
};
|
|
11
|
-
export const
|
|
11
|
+
export const order = {
|
|
12
12
|
ASCENDING: 'asc',
|
|
13
13
|
DESCENDING: 'desc',
|
|
14
14
|
};
|
|
15
|
-
export const
|
|
15
|
+
export const report = {
|
|
16
16
|
CRAWL_STATISTICS: 'crawl_statistics',
|
|
17
17
|
CUSTOM: 'custom',
|
|
18
18
|
LIST_PROJECTS: 'list_projects',
|
|
@@ -22,6 +22,3 @@ export const reports = {
|
|
|
22
22
|
REPORT_STATISTICS: 'report_statistics',
|
|
23
23
|
REPORT_SUMMARY: 'report_summary',
|
|
24
24
|
};
|
|
25
|
-
export * from "./buildRequest";
|
|
26
|
-
export * from "./getData";
|
|
27
|
-
export * from "./initClient";
|
|
@@ -1,28 +1,29 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
CUSTOM_EXTRACTION_1:
|
|
3
|
-
CUSTOM_EXTRACTION_2:
|
|
4
|
-
DEEP_RANK:
|
|
5
|
-
DESCRIPTION:
|
|
6
|
-
DUPLICATE_PAGE:
|
|
7
|
-
DUPLICATE_DESCRIPTION_FROM:
|
|
8
|
-
DUPLICATE_TITLE_FROM:
|
|
9
|
-
FOUND_AT_URL:
|
|
10
|
-
FOUND_IN_CRAWL:
|
|
11
|
-
FOUND_IN_SEARCH_CONSOLE:
|
|
12
|
-
FOUND_IN_SITEMAP:
|
|
13
|
-
LEVEL:
|
|
14
|
-
PAGE_TITLE:
|
|
15
|
-
PRIMARY_PAGE:
|
|
16
|
-
PRIMARY_URL_FROM:
|
|
17
|
-
PRIMARY_URL_FROM_STATUS_CODE:
|
|
18
|
-
REDIRECTED_TO_URL:
|
|
19
|
-
REDIRECTED_TO_STATUS_CODE:
|
|
20
|
-
REDIRECTION_CHAIN:
|
|
21
|
-
SOURCE_URL:
|
|
22
|
-
STATUS_CODE:
|
|
23
|
-
TARGET_STATUS_CODE:
|
|
24
|
-
URL:
|
|
25
|
-
URL_COUNT:
|
|
26
|
-
URL_TO:
|
|
27
|
-
URL_TO_STATUS_CODE:
|
|
1
|
+
export declare const column: {
|
|
2
|
+
readonly CUSTOM_EXTRACTION_1: "customExtraction1";
|
|
3
|
+
readonly CUSTOM_EXTRACTION_2: "customExtraction2";
|
|
4
|
+
readonly DEEP_RANK: "deepRank";
|
|
5
|
+
readonly DESCRIPTION: "description";
|
|
6
|
+
readonly DUPLICATE_PAGE: "duplicatePage";
|
|
7
|
+
readonly DUPLICATE_DESCRIPTION_FROM: "duplicateDescriptionPrimaryUrl";
|
|
8
|
+
readonly DUPLICATE_TITLE_FROM: "duplicateTitlePrimaryUrl";
|
|
9
|
+
readonly FOUND_AT_URL: "foundAtUrl";
|
|
10
|
+
readonly FOUND_IN_CRAWL: "foundInWebCrawl";
|
|
11
|
+
readonly FOUND_IN_SEARCH_CONSOLE: "foundInGoogleSearchConsole";
|
|
12
|
+
readonly FOUND_IN_SITEMAP: "foundInSitemap";
|
|
13
|
+
readonly LEVEL: "level";
|
|
14
|
+
readonly PAGE_TITLE: "pageTitle";
|
|
15
|
+
readonly PRIMARY_PAGE: "primaryPage";
|
|
16
|
+
readonly PRIMARY_URL_FROM: "primaryUrlFrom";
|
|
17
|
+
readonly PRIMARY_URL_FROM_STATUS_CODE: "primaryUrlFromStatusCode";
|
|
18
|
+
readonly REDIRECTED_TO_URL: "redirectedToUrl";
|
|
19
|
+
readonly REDIRECTED_TO_STATUS_CODE: "redirectedToStatusCode";
|
|
20
|
+
readonly REDIRECTION_CHAIN: "redirectionChain";
|
|
21
|
+
readonly SOURCE_URL: "sourceUrl";
|
|
22
|
+
readonly STATUS_CODE: "httpStatusCode";
|
|
23
|
+
readonly TARGET_STATUS_CODE: "targetStatusCode";
|
|
24
|
+
readonly URL: "url";
|
|
25
|
+
readonly URL_COUNT: "urlCount";
|
|
26
|
+
readonly URL_TO: "urlTo";
|
|
27
|
+
readonly URL_TO_STATUS_CODE: "urlToStatusCode";
|
|
28
28
|
};
|
|
29
|
+
export type Column = typeof column[keyof typeof column];
|
|
@@ -4,7 +4,7 @@ export const getData = async (query, variables, accessToken) => {
|
|
|
4
4
|
queryClean = queryClean.replace(/\n/g, " ");
|
|
5
5
|
queryClean = queryClean.replace(/\t/g, " ");
|
|
6
6
|
queryClean = queryClean.replace(/ /g, " ");
|
|
7
|
-
|
|
7
|
+
return await post("https://api.lumar.io/graphql", {
|
|
8
8
|
query: queryClean,
|
|
9
9
|
variables,
|
|
10
10
|
}, {
|
|
@@ -12,5 +12,4 @@ export const getData = async (query, variables, accessToken) => {
|
|
|
12
12
|
"x-auth-token": accessToken,
|
|
13
13
|
},
|
|
14
14
|
});
|
|
15
|
-
return apiResponse;
|
|
16
15
|
};
|
|
@@ -1,29 +1,27 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
CONTAINS:
|
|
3
|
-
DOESNT_CONTAIN:
|
|
4
|
-
DOESNT_MATCH_REGEX:
|
|
5
|
-
ENDS_WITH:
|
|
6
|
-
EQUALS:
|
|
7
|
-
GREATER_THAN:
|
|
8
|
-
GREATER_THAN_OR_EQUAL:
|
|
9
|
-
IS_EMPTY:
|
|
10
|
-
LESS_THAN:
|
|
11
|
-
LESS_THAN_OR_EQUAL:
|
|
12
|
-
MATCHES_REGEX:
|
|
13
|
-
NOT_EQUALS:
|
|
14
|
-
STARTS_WITH:
|
|
1
|
+
export declare const operand: {
|
|
2
|
+
readonly CONTAINS: "contains";
|
|
3
|
+
readonly DOESNT_CONTAIN: "notContains";
|
|
4
|
+
readonly DOESNT_MATCH_REGEX: "notMatchesRegex";
|
|
5
|
+
readonly ENDS_WITH: "endsWith";
|
|
6
|
+
readonly EQUALS: "eq";
|
|
7
|
+
readonly GREATER_THAN: "gt";
|
|
8
|
+
readonly GREATER_THAN_OR_EQUAL: "ge";
|
|
9
|
+
readonly IS_EMPTY: "isEmpty";
|
|
10
|
+
readonly LESS_THAN: "lt";
|
|
11
|
+
readonly LESS_THAN_OR_EQUAL: "le";
|
|
12
|
+
readonly MATCHES_REGEX: "matchesRegex";
|
|
13
|
+
readonly NOT_EQUALS: "ne";
|
|
14
|
+
readonly STARTS_WITH: "beginsWith";
|
|
15
15
|
};
|
|
16
|
-
export
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
16
|
+
export type Operand = typeof operand[keyof typeof operand];
|
|
17
|
+
export declare const reportType: {
|
|
18
|
+
readonly ADDED: "Added";
|
|
19
|
+
readonly BASIC: "Basic";
|
|
20
|
+
readonly MISSING: "Missing";
|
|
21
|
+
readonly REMOVED: "Removed";
|
|
21
22
|
};
|
|
23
|
+
export type ReportType = typeof reportType[keyof typeof reportType];
|
|
22
24
|
/**
|
|
23
25
|
* Shorthand function to return the report key.
|
|
24
26
|
*/
|
|
25
27
|
export declare const getReportKey: (templateCode: string, typeCode: string) => string;
|
|
26
|
-
export { columns } from "./columns";
|
|
27
|
-
export { reportTemplates } from "./reportTemplates";
|
|
28
|
-
export { getData } from "./getData";
|
|
29
|
-
export { initClient } from "./initClient";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const
|
|
1
|
+
export const operand = {
|
|
2
2
|
CONTAINS: "contains",
|
|
3
3
|
DOESNT_CONTAIN: "notContains",
|
|
4
4
|
DOESNT_MATCH_REGEX: "notMatchesRegex",
|
|
@@ -13,7 +13,7 @@ export const operands = {
|
|
|
13
13
|
NOT_EQUALS: "ne",
|
|
14
14
|
STARTS_WITH: "beginsWith",
|
|
15
15
|
};
|
|
16
|
-
export const
|
|
16
|
+
export const reportType = {
|
|
17
17
|
ADDED: "Added",
|
|
18
18
|
BASIC: "Basic",
|
|
19
19
|
MISSING: "Missing",
|
|
@@ -25,7 +25,3 @@ export const reportTypes = {
|
|
|
25
25
|
export const getReportKey = (templateCode, typeCode) => {
|
|
26
26
|
return `${templateCode}-${typeCode}`.toLowerCase();
|
|
27
27
|
};
|
|
28
|
-
export { columns } from "./columns";
|
|
29
|
-
export { reportTemplates } from "./reportTemplates";
|
|
30
|
-
export { getData } from "./getData";
|
|
31
|
-
export { initClient } from "./initClient";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { reportType } from "../";
|
|
2
2
|
/**
|
|
3
3
|
* Used to return the number for: Basic, Added, Missing, Removed for a given report.
|
|
4
4
|
*/
|
|
@@ -28,7 +28,7 @@ const getReportDifferences = ({ crawlId, filter, reportTemplateCode }) => ({
|
|
|
28
28
|
input: {
|
|
29
29
|
crawlId,
|
|
30
30
|
reportTemplateCode,
|
|
31
|
-
reportTypeCode:
|
|
31
|
+
reportTypeCode: reportType.BASIC,
|
|
32
32
|
},
|
|
33
33
|
},
|
|
34
34
|
});
|
|
@@ -1,67 +1,68 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
"200_PAGES":
|
|
3
|
-
"301_REDIRECTS":
|
|
4
|
-
"4XX_ERRORS":
|
|
5
|
-
"5XX_ERRORS":
|
|
6
|
-
ALL_PAGES:
|
|
7
|
-
BROKEN_EXTERNAL_LINKS:
|
|
8
|
-
BROKEN_INTERNAL_LINKS:
|
|
9
|
-
BROKEN_SITEMAP_PAGES:
|
|
10
|
-
CANONICAL_CONFLICTING:
|
|
11
|
-
CANONICAL_NON_200:
|
|
12
|
-
CANONICAL_NON_INDEXABLE:
|
|
13
|
-
CANONICAL_ORPHANED:
|
|
14
|
-
CUSTOM_EXTRACTION_1:
|
|
15
|
-
CUSTOM_EXTRACTION_2:
|
|
16
|
-
DUPLICATE_CONTENT:
|
|
17
|
-
DUPLICATE_DESCRIPTIONS:
|
|
18
|
-
DUPLICATE_TITLES:
|
|
19
|
-
EMPTY_PAGES:
|
|
20
|
-
INDEXABLE_PAGES:
|
|
21
|
-
LINKED_DOMAINS:
|
|
22
|
-
MAX_DESCRIPTIONS:
|
|
23
|
-
MAX_MOBILE_DESCRIPTIONS:
|
|
24
|
-
MAX_TITLES:
|
|
25
|
-
MISSING_DESCRIPTIONS:
|
|
26
|
-
MISSING_TITLES:
|
|
27
|
-
NON_301_REDIRECTS:
|
|
28
|
-
NON_INDEXABLE_PAGES:
|
|
29
|
-
NON_INDEXABLE_SITEMAP_PAGES:
|
|
30
|
-
ORPHANED_CANONICAL:
|
|
31
|
-
ORPHANED_ANALYTICS_PAGES:
|
|
32
|
-
ORPHANED_SEARCH_CONSOLE_PAGES:
|
|
33
|
-
ORPHANED_SITEMAP_PAGES:
|
|
34
|
-
PAGES_WITH_HIGH_EXTERNAL_LINKS:
|
|
35
|
-
PERFORMANCE_MAX_FETCH_TIME:
|
|
36
|
-
PERFORMANCE_POOR_CLS:
|
|
37
|
-
PERFORMANCE_SLOW_DCL:
|
|
38
|
-
PERFORMANCE_SLOW_FCP:
|
|
39
|
-
PERFORMANCE_SLOW_LCP:
|
|
40
|
-
PERFORMANCE_SLOW_TTFB:
|
|
41
|
-
PERFORMANCE_SLOW_TTI:
|
|
42
|
-
PRIMARY_PAGES:
|
|
43
|
-
REDIRECTS_BROKEN:
|
|
44
|
-
REDIRECTS_CHAIN:
|
|
45
|
-
REDIRECTS_LOOP:
|
|
46
|
-
SCHEMA_BREADCRUMB:
|
|
47
|
-
SCHEMA_EVENT:
|
|
48
|
-
SCHEMA_FAQ:
|
|
49
|
-
SCHEMA_HOW_TO:
|
|
50
|
-
SCHEMA_NEWS_ARTICLE:
|
|
51
|
-
SCHEMA_PRODUCT:
|
|
52
|
-
SCHEMA_QA:
|
|
53
|
-
SCHEMA_RECIPE:
|
|
54
|
-
SCHEMA_REVIEW:
|
|
55
|
-
SCHEMA_VIDEO:
|
|
56
|
-
SHORT_DESCRIPTIONS:
|
|
57
|
-
SHORT_TITLES:
|
|
58
|
-
SITEMAP_PAGES:
|
|
59
|
-
SITEMAPS_NON_INDEXABLE_PAGES:
|
|
60
|
-
SITEMAPS_ORPHANED_PAGES:
|
|
61
|
-
SITEMAPS_MISSING_PAGES:
|
|
62
|
-
THIN_PAGES:
|
|
63
|
-
TRUE_UNIQUE_PAGES:
|
|
64
|
-
UNIQUE_EXTERNAL_LINKS:
|
|
65
|
-
UNIQUE_INTERNAL_LINKS:
|
|
66
|
-
XML_SITEMAPS:
|
|
1
|
+
export declare const reportTemplate: {
|
|
2
|
+
readonly "200_PAGES": "200_pages";
|
|
3
|
+
readonly "301_REDIRECTS": "301_redirects";
|
|
4
|
+
readonly "4XX_ERRORS": "4xx_errors";
|
|
5
|
+
readonly "5XX_ERRORS": "5xx_errors";
|
|
6
|
+
readonly ALL_PAGES: "all_pages";
|
|
7
|
+
readonly BROKEN_EXTERNAL_LINKS: "broken_links_external";
|
|
8
|
+
readonly BROKEN_INTERNAL_LINKS: "all_broken_links";
|
|
9
|
+
readonly BROKEN_SITEMAP_PAGES: "broken_sitemap_links";
|
|
10
|
+
readonly CANONICAL_CONFLICTING: "conflicting_canonical_tags";
|
|
11
|
+
readonly CANONICAL_NON_200: "canonical_to_non_200";
|
|
12
|
+
readonly CANONICAL_NON_INDEXABLE: "non_indexable_canonical_links_in";
|
|
13
|
+
readonly CANONICAL_ORPHANED: "unlinked_canonical_pages";
|
|
14
|
+
readonly CUSTOM_EXTRACTION_1: "custom_extraction_1";
|
|
15
|
+
readonly CUSTOM_EXTRACTION_2: "custom_extraction_2";
|
|
16
|
+
readonly DUPLICATE_CONTENT: "duplicate_body_content";
|
|
17
|
+
readonly DUPLICATE_DESCRIPTIONS: "pages_with_duplicate_descriptions";
|
|
18
|
+
readonly DUPLICATE_TITLES: "pages_with_duplicate_titles";
|
|
19
|
+
readonly EMPTY_PAGES: "empty_pages";
|
|
20
|
+
readonly INDEXABLE_PAGES: "indexable_pages";
|
|
21
|
+
readonly LINKED_DOMAINS: "linked_domains";
|
|
22
|
+
readonly MAX_DESCRIPTIONS: "max_description_length";
|
|
23
|
+
readonly MAX_MOBILE_DESCRIPTIONS: "max_mobile_description_length";
|
|
24
|
+
readonly MAX_TITLES: "max_title_length";
|
|
25
|
+
readonly MISSING_DESCRIPTIONS: "missing_descriptions";
|
|
26
|
+
readonly MISSING_TITLES: "missing_titles";
|
|
27
|
+
readonly NON_301_REDIRECTS: "non_301_redirects";
|
|
28
|
+
readonly NON_INDEXABLE_PAGES: "non_indexable_pages";
|
|
29
|
+
readonly NON_INDEXABLE_SITEMAP_PAGES: "sitemaps_non_indexable_links";
|
|
30
|
+
readonly ORPHANED_CANONICAL: "unlinked_canonical_pages";
|
|
31
|
+
readonly ORPHANED_ANALYTICS_PAGES: "orphaned_organic_landing_pages";
|
|
32
|
+
readonly ORPHANED_SEARCH_CONSOLE_PAGES: "orphaned_google_search_console_pages";
|
|
33
|
+
readonly ORPHANED_SITEMAP_PAGES: "orphaned_sitemaps_pages";
|
|
34
|
+
readonly PAGES_WITH_HIGH_EXTERNAL_LINKS: "max_external_links";
|
|
35
|
+
readonly PERFORMANCE_MAX_FETCH_TIME: "max_load_time";
|
|
36
|
+
readonly PERFORMANCE_POOR_CLS: "poor_cls";
|
|
37
|
+
readonly PERFORMANCE_SLOW_DCL: "slow_dcl";
|
|
38
|
+
readonly PERFORMANCE_SLOW_FCP: "slow_fcp";
|
|
39
|
+
readonly PERFORMANCE_SLOW_LCP: "slow_lcp";
|
|
40
|
+
readonly PERFORMANCE_SLOW_TTFB: "slow_server_response";
|
|
41
|
+
readonly PERFORMANCE_SLOW_TTI: "slow_tti";
|
|
42
|
+
readonly PRIMARY_PAGES: "unique_pages";
|
|
43
|
+
readonly REDIRECTS_BROKEN: "all_broken_redirects";
|
|
44
|
+
readonly REDIRECTS_CHAIN: "redirect_chains";
|
|
45
|
+
readonly REDIRECTS_LOOP: "redirection_loop";
|
|
46
|
+
readonly SCHEMA_BREADCRUMB: "pages_with_breadcrumb_schema";
|
|
47
|
+
readonly SCHEMA_EVENT: "pages_with_event_schema";
|
|
48
|
+
readonly SCHEMA_FAQ: "pages_with_faqpage_schema";
|
|
49
|
+
readonly SCHEMA_HOW_TO: "pages_with_howto_schema";
|
|
50
|
+
readonly SCHEMA_NEWS_ARTICLE: "pages_with_news_article_schema";
|
|
51
|
+
readonly SCHEMA_PRODUCT: "pages_with_product_schema";
|
|
52
|
+
readonly SCHEMA_QA: "pages_with_qapage_schema";
|
|
53
|
+
readonly SCHEMA_RECIPE: "pages_with_recipe_schema";
|
|
54
|
+
readonly SCHEMA_REVIEW: "pages_with_review_schema";
|
|
55
|
+
readonly SCHEMA_VIDEO: "pages_with_videoobject_schema";
|
|
56
|
+
readonly SHORT_DESCRIPTIONS: "short_descriptions";
|
|
57
|
+
readonly SHORT_TITLES: "short_titles";
|
|
58
|
+
readonly SITEMAP_PAGES: "all_sitemaps_links";
|
|
59
|
+
readonly SITEMAPS_NON_INDEXABLE_PAGES: "sitemaps_non_indexable_links";
|
|
60
|
+
readonly SITEMAPS_ORPHANED_PAGES: "orphaned_sitemaps_pages";
|
|
61
|
+
readonly SITEMAPS_MISSING_PAGES: "not_in_sitemaps_primary_indexable";
|
|
62
|
+
readonly THIN_PAGES: "thin_pages";
|
|
63
|
+
readonly TRUE_UNIQUE_PAGES: "true_uniques";
|
|
64
|
+
readonly UNIQUE_EXTERNAL_LINKS: "unique_external_links";
|
|
65
|
+
readonly UNIQUE_INTERNAL_LINKS: "unique_internal_links";
|
|
66
|
+
readonly XML_SITEMAPS: "xml_sitemaps";
|
|
67
67
|
};
|
|
68
|
+
export type ReportTemplate = typeof reportTemplate[keyof typeof reportTemplate];
|
package/nextAuth/nextAuth.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export { isSessionReady } from "./isSessionReady";
|
|
2
2
|
export declare const NextAuthState: {
|
|
3
|
-
AUTHENTICATED:
|
|
4
|
-
PENDING:
|
|
5
|
-
UNAUTHENTICATED:
|
|
3
|
+
readonly AUTHENTICATED: "authenticated";
|
|
4
|
+
readonly PENDING: "loading";
|
|
5
|
+
readonly UNAUTHENTICATED: "unauthenticated";
|
|
6
6
|
};
|
|
7
7
|
export type NextAuthState = typeof NextAuthState[keyof typeof NextAuthState];
|
package/nextJs/nextJs.js
CHANGED
|
@@ -1,14 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Get the user's remote IP Address
|
|
3
3
|
*/
|
|
4
|
-
export const getIp = ({ req }) =>
|
|
5
|
-
let response = 'unset';
|
|
6
|
-
if (undefined !== req.headers['x-real-ip']) {
|
|
7
|
-
response = String(req.headers['x-real-ip']);
|
|
8
|
-
}
|
|
9
|
-
return response;
|
|
10
|
-
};
|
|
4
|
+
export const getIp = ({ req }) => String(req.headers?.["x-real-ip"] || "unset");
|
|
11
5
|
/**
|
|
12
6
|
* Get the user's User Agent
|
|
13
7
|
*/
|
|
14
|
-
export const getUserAgent = ({ req }) => req.headers[
|
|
8
|
+
export const getUserAgent = ({ req }) => String(req.headers["user-agent"] || "unset");
|
package/package.json
CHANGED
package/sorting/sorting.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
1
|
+
export * from "./byNumberAscending";
|
|
2
|
+
export * from "./byNumberDescending";
|
|
3
|
+
export * from "./byStringAscending";
|
|
4
|
+
export * from "./byStringDescending";
|
package/sorting/sorting.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
1
|
+
export * from "./byNumberAscending";
|
|
2
|
+
export * from "./byNumberDescending";
|
|
3
|
+
export * from "./byStringAscending";
|
|
4
|
+
export * from "./byStringDescending";
|
package/util/isUndefined.js
CHANGED