@candlerip/shared3 0.0.46 → 0.0.48

Sign up to get free protection for your applications and to get access to all the features.
@@ -2,23 +2,25 @@ import js from '@eslint/js';
2
2
  import ts from 'typescript-eslint';
3
3
  import globals from 'globals';
4
4
 
5
- export default ts.config(
6
- js.configs.recommended,
7
- ...ts.configs.recommended,
8
- {
9
- ignores: ['temp'],
10
- },
11
- {
12
- languageOptions: {
13
- globals: {
14
- ...globals.browser,
15
- ...globals.node,
5
+ export default (projectConfig) =>
6
+ ts.config(
7
+ js.configs.recommended,
8
+ ...ts.configs.recommended,
9
+ {
10
+ ignores: ['temp'],
11
+ },
12
+ {
13
+ languageOptions: {
14
+ globals: {
15
+ ...globals.browser,
16
+ ...globals.node,
17
+ },
16
18
  },
17
19
  },
18
- },
19
- {
20
- rules: {
21
- 'no-console': [2, { allow: ['error', 'info'] }],
20
+ {
21
+ rules: {
22
+ 'no-console': [2, { allow: ['error', 'info'] }],
23
+ },
22
24
  },
23
- },
24
- );
25
+ projectConfig ?? [],
26
+ );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@candlerip/shared3",
3
- "version": "0.0.46",
3
+ "version": "0.0.48",
4
4
  "type": "module",
5
5
  "main": "src/index.js",
6
6
  "bin": {
@@ -1 +1 @@
1
- export declare const BOOLEAN_ENVIRONMENT_VARIABLE_NAMES: ("API_GATEWAY_PORT" | "AUTHENTICATION_AUDIENCE" | "AUTHENTICATION_DOMAIN" | "CACHE_ENABLED" | "DATABASE_URL" | "FRONTEND_URL" | "RABBITMQ_URL" | "REDIS_PWD" | "REDIS_URL" | "S3_IMAGES_BUCKET_NAME" | "CACHE_SERVICE_PORT" | "LOGGER_SERVICE_PORT" | "RABBITMQ_PORT" | "RABBITMQ_MANAGEMENT_PORT" | "REDIS_PORT" | "APP_NAME" | "DOMAIN_NAME" | "DICTIONARY_SERVICE_PORT" | "RABBITMQ_PWD" | "RABBITMQ_USER")[];
1
+ export declare const BOOLEAN_ENVIRONMENT_VARIABLE_NAMES: ("API_GATEWAY_PORT" | "AUTHENTICATION_AUDIENCE" | "AUTHENTICATION_DOMAIN" | "CACHE_ENABLED" | "DATABASE_URL" | "FRONTEND_URL" | "RABBITMQ_URL" | "REDIS_PWD" | "REDIS_URL" | "S3_IMAGES_BUCKET_NAME" | "CACHE_SERVICE_PORT" | "FRONTEND_PORT" | "LOGGER_SERVICE_PORT" | "RABBITMQ_PORT" | "RABBITMQ_MANAGEMENT_PORT" | "REDIS_PORT" | "APP_NAME" | "DOMAIN_NAME" | "DICTIONARY_SERVICE_PORT" | "RABBITMQ_PWD" | "RABBITMQ_USER")[];
@@ -1 +1 @@
1
- export declare const NUMBER_ENVIRONMENT_VARIABLE_NAMES: ("API_GATEWAY_PORT" | "AUTHENTICATION_AUDIENCE" | "AUTHENTICATION_DOMAIN" | "CACHE_ENABLED" | "DATABASE_URL" | "FRONTEND_URL" | "RABBITMQ_URL" | "REDIS_PWD" | "REDIS_URL" | "S3_IMAGES_BUCKET_NAME" | "CACHE_SERVICE_PORT" | "LOGGER_SERVICE_PORT" | "RABBITMQ_PORT" | "RABBITMQ_MANAGEMENT_PORT" | "REDIS_PORT" | "APP_NAME" | "DOMAIN_NAME" | "DICTIONARY_SERVICE_PORT" | "RABBITMQ_PWD" | "RABBITMQ_USER")[];
1
+ export declare const NUMBER_ENVIRONMENT_VARIABLE_NAMES: ("API_GATEWAY_PORT" | "AUTHENTICATION_AUDIENCE" | "AUTHENTICATION_DOMAIN" | "CACHE_ENABLED" | "DATABASE_URL" | "FRONTEND_URL" | "RABBITMQ_URL" | "REDIS_PWD" | "REDIS_URL" | "S3_IMAGES_BUCKET_NAME" | "CACHE_SERVICE_PORT" | "FRONTEND_PORT" | "LOGGER_SERVICE_PORT" | "RABBITMQ_PORT" | "RABBITMQ_MANAGEMENT_PORT" | "REDIS_PORT" | "APP_NAME" | "DOMAIN_NAME" | "DICTIONARY_SERVICE_PORT" | "RABBITMQ_PWD" | "RABBITMQ_USER")[];
@@ -8,6 +8,7 @@ export declare const ENVIRONMENT_VARIABLES: {
8
8
  readonly DATABASE_URL: "string";
9
9
  readonly DICTIONARY_SERVICE_PORT: "number";
10
10
  readonly DOMAIN_NAME: "string";
11
+ readonly FRONTEND_PORT: "number";
11
12
  readonly FRONTEND_URL: "string";
12
13
  readonly LOGGER_SERVICE_PORT: "number";
13
14
  readonly RABBITMQ_MANAGEMENT_PORT: "number";
@@ -8,6 +8,7 @@ export const ENVIRONMENT_VARIABLES = {
8
8
  DATABASE_URL: 'string',
9
9
  DICTIONARY_SERVICE_PORT: 'number',
10
10
  DOMAIN_NAME: 'string',
11
+ FRONTEND_PORT: 'number',
11
12
  FRONTEND_URL: 'string',
12
13
  LOGGER_SERVICE_PORT: 'number',
13
14
  RABBITMQ_MANAGEMENT_PORT: 'number',
@@ -1,7 +1,9 @@
1
1
  export const consoleCustomError = (customError) => {
2
2
  console.error('***ERROR***:', customError.message);
3
3
  console.error('ID:', customError.id);
4
- console.error('PROJECT_NAME:', customError.projectName);
4
+ if (customError.projectName) {
5
+ console.error('PROJECT_NAME:', customError.projectName);
6
+ }
5
7
  if (customError.info) {
6
8
  console.error('INFO:', customError.info);
7
9
  }
@@ -3,7 +3,7 @@ export declare const PROJECT_CONFIG: {
3
3
  readonly environmentVariableNames: readonly ["API_GATEWAY_PORT", "AUTHENTICATION_AUDIENCE", "AUTHENTICATION_DOMAIN", "CACHE_ENABLED", "DATABASE_URL", "FRONTEND_URL", "RABBITMQ_URL", "REDIS_PWD", "REDIS_URL", "S3_IMAGES_BUCKET_NAME"];
4
4
  };
5
5
  readonly 'backend-project-config': {
6
- readonly environmentVariableNames: readonly ["API_GATEWAY_PORT", "CACHE_SERVICE_PORT", "LOGGER_SERVICE_PORT", "RABBITMQ_PORT", "RABBITMQ_MANAGEMENT_PORT", "REDIS_PORT"];
6
+ readonly environmentVariableNames: readonly ["API_GATEWAY_PORT", "CACHE_SERVICE_PORT", "FRONTEND_PORT", "LOGGER_SERVICE_PORT", "RABBITMQ_PORT", "RABBITMQ_MANAGEMENT_PORT", "REDIS_PORT"];
7
7
  };
8
8
  readonly 'backend-init-project-config': {
9
9
  readonly environmentVariableNames: readonly ["APP_NAME", "DOMAIN_NAME", "S3_IMAGES_BUCKET_NAME"];
@@ -14,6 +14,9 @@ export declare const PROJECT_CONFIG: {
14
14
  readonly 'dictionary-service-project-config': {
15
15
  readonly environmentVariableNames: readonly ["DICTIONARY_SERVICE_PORT"];
16
16
  };
17
+ readonly 'frontend-project-config': {
18
+ readonly environmentVariableNames: readonly ["FRONTEND_PORT"];
19
+ };
17
20
  readonly 'images-project-config': {
18
21
  readonly environmentVariableNames: readonly ["S3_IMAGES_BUCKET_NAME"];
19
22
  };
@@ -24,7 +27,7 @@ export declare const PROJECT_CONFIG: {
24
27
  readonly environmentVariableNames: readonly ["DATABASE_URL", "LOGGER_SERVICE_PORT", "RABBITMQ_URL"];
25
28
  };
26
29
  readonly 'nginx-project-config': {
27
- readonly environmentVariableNames: readonly ["API_GATEWAY_PORT"];
30
+ readonly environmentVariableNames: readonly ["API_GATEWAY_PORT", "FRONTEND_PORT"];
28
31
  };
29
32
  readonly 'rabbitmq-project-config': {
30
33
  readonly environmentVariableNames: readonly ["RABBITMQ_PORT", "RABBITMQ_MANAGEMENT_PORT", "RABBITMQ_PWD", "RABBITMQ_USER"];
@@ -17,6 +17,7 @@ export const PROJECT_CONFIG = {
17
17
  environmentVariableNames: [
18
18
  'API_GATEWAY_PORT',
19
19
  'CACHE_SERVICE_PORT',
20
+ 'FRONTEND_PORT',
20
21
  'LOGGER_SERVICE_PORT',
21
22
  'RABBITMQ_PORT',
22
23
  'RABBITMQ_MANAGEMENT_PORT',
@@ -32,6 +33,9 @@ export const PROJECT_CONFIG = {
32
33
  'dictionary-service-project-config': {
33
34
  environmentVariableNames: ['DICTIONARY_SERVICE_PORT'],
34
35
  },
36
+ 'frontend-project-config': {
37
+ environmentVariableNames: ['FRONTEND_PORT'],
38
+ },
35
39
  'images-project-config': {
36
40
  environmentVariableNames: ['S3_IMAGES_BUCKET_NAME'],
37
41
  },
@@ -42,7 +46,7 @@ export const PROJECT_CONFIG = {
42
46
  environmentVariableNames: ['DATABASE_URL', 'LOGGER_SERVICE_PORT', 'RABBITMQ_URL'],
43
47
  },
44
48
  'nginx-project-config': {
45
- environmentVariableNames: ['API_GATEWAY_PORT'],
49
+ environmentVariableNames: ['API_GATEWAY_PORT', 'FRONTEND_PORT'],
46
50
  },
47
51
  'rabbitmq-project-config': {
48
52
  environmentVariableNames: ['RABBITMQ_PORT', 'RABBITMQ_MANAGEMENT_PORT', 'RABBITMQ_PWD', 'RABBITMQ_USER'],
@@ -1 +1 @@
1
- export declare const PROJECT_NAMES: readonly ["api-gateway", "backend", "backend-init", "cache-service", "dictionary-service", "config", "images", "images-init", "logger-service", "nginx", "rabbitmq", "redis", "shared", "shared-aws", "shared-backend"];
1
+ export declare const PROJECT_NAMES: readonly ["api-gateway", "backend", "backend-init", "cache-service", "dictionary-service", "config", "frontend", "images", "images-init", "logger-service", "nginx", "rabbitmq", "redis", "shared", "shared-aws", "shared-backend"];
@@ -5,6 +5,7 @@ export const PROJECT_NAMES = [
5
5
  'cache-service',
6
6
  'dictionary-service',
7
7
  'config',
8
+ 'frontend',
8
9
  'images',
9
10
  'images-init',
10
11
  'logger-service',