@common-stack/generate-plugin 6.0.8-alpha.1 → 6.0.8-alpha.11

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/CHANGELOG.md CHANGED
@@ -3,6 +3,46 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [6.0.8-alpha.11](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.10...v6.0.8-alpha.11) (2024-12-29)
7
+
8
+ **Note:** Version bump only for package @common-stack/generate-plugin
9
+
10
+ ## [6.0.8-alpha.10](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.9...v6.0.8-alpha.10) (2024-12-20)
11
+
12
+ **Note:** Version bump only for package @common-stack/generate-plugin
13
+
14
+ ## [6.0.8-alpha.9](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.8...v6.0.8-alpha.9) (2024-12-20)
15
+
16
+ **Note:** Version bump only for package @common-stack/generate-plugin
17
+
18
+ ## [6.0.8-alpha.8](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.7...v6.0.8-alpha.8) (2024-12-19)
19
+
20
+ **Note:** Version bump only for package @common-stack/generate-plugin
21
+
22
+ ## [6.0.8-alpha.7](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.6...v6.0.8-alpha.7) (2024-12-19)
23
+
24
+ **Note:** Version bump only for package @common-stack/generate-plugin
25
+
26
+ ## [6.0.8-alpha.6](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.5...v6.0.8-alpha.6) (2024-12-19)
27
+
28
+ **Note:** Version bump only for package @common-stack/generate-plugin
29
+
30
+ ## [6.0.8-alpha.5](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.4...v6.0.8-alpha.5) (2024-12-19)
31
+
32
+ **Note:** Version bump only for package @common-stack/generate-plugin
33
+
34
+ ## [6.0.8-alpha.4](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.3...v6.0.8-alpha.4) (2024-12-19)
35
+
36
+ **Note:** Version bump only for package @common-stack/generate-plugin
37
+
38
+ ## [6.0.8-alpha.3](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.2...v6.0.8-alpha.3) (2024-12-19)
39
+
40
+ **Note:** Version bump only for package @common-stack/generate-plugin
41
+
42
+ ## [6.0.8-alpha.2](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.1...v6.0.8-alpha.2) (2024-12-19)
43
+
44
+ **Note:** Version bump only for package @common-stack/generate-plugin
45
+
6
46
  ## [6.0.8-alpha.1](https://github.com/cdmbase/common-stack/compare/v6.0.8-alpha.0...v6.0.8-alpha.1) (2024-12-17)
7
47
 
8
48
  ## [6.0.6-alpha.107](https://github.com/cdmbase/common-stack/compare/v6.0.6-alpha.106...v6.0.6-alpha.107) (2024-12-13)
@@ -69,13 +69,13 @@
69
69
  "@casl/ability": "^4.1.5",
70
70
  "@cdm-logger/client": "^9.0.3",
71
71
  "@cdm-logger/server": "^9.0.3",
72
- "@cdmbase/graphql-type-uri": "^3.0.0",
73
- "@common-stack/cache-api-server": "6.0.8-alpha.0",
74
- "@common-stack/client-core": "6.0.8-alpha.0",
75
- "@common-stack/core": "6.0.8-alpha.0",
76
- "@common-stack/server-core": "6.0.8-alpha.0",
77
- "@common-stack/server-stack": "6.0.8-alpha.0",
78
- "@common-stack/store-mongo": "6.0.8-alpha.0",
72
+ "@cdmbase/graphql-type-uri": "^4.0.0",
73
+ "@common-stack/cache-api-server": "6.0.8-alpha.9",
74
+ "@common-stack/client-core": "6.0.8-alpha.7",
75
+ "@common-stack/core": "6.0.8-alpha.7",
76
+ "@common-stack/server-core": "6.0.8-alpha.9",
77
+ "@common-stack/server-stack": "6.0.8-alpha.10",
78
+ "@common-stack/store-mongo": "6.0.8-alpha.10",
79
79
  "@graphql-tools/links": "~9.0.1",
80
80
  "@graphql-tools/schema": "~10.0.6",
81
81
  "@graphql-tools/stitch": "~9.2.10",
@@ -95,7 +95,6 @@
95
95
  "express": "^4.17.1",
96
96
  "graphql": "^16.0.0",
97
97
  "graphql-bigint": "^1.0.0",
98
- "graphql-iso-date": "^3.6.1",
99
98
  "graphql-middleware": "^6.1.33",
100
99
  "graphql-nats-subscriptions": "^1.5.0",
101
100
  "graphql-playground-middleware-express": "^1.7.3",
@@ -63,13 +63,13 @@
63
63
  "@apollo/client": "^3.9.0",
64
64
  "@cdm-logger/client": "^9.0.3",
65
65
  "@cdm-logger/server": "^9.0.3",
66
- "@common-stack/cache-api-server": "6.0.8-alpha.0",
67
- "@common-stack/client-core": "6.0.8-alpha.0",
68
- "@common-stack/client-react": "6.0.8-alpha.0",
69
- "@common-stack/components-pro": "6.0.8-alpha.0",
70
- "@common-stack/core": "6.0.8-alpha.0",
71
- "@common-stack/remix-router-redux": "6.0.8-alpha.0",
72
- "@common-stack/server-core": "6.0.8-alpha.0",
66
+ "@common-stack/cache-api-server": "6.0.8-alpha.9",
67
+ "@common-stack/client-core": "6.0.8-alpha.7",
68
+ "@common-stack/client-react": "6.0.8-alpha.7",
69
+ "@common-stack/components-pro": "6.0.8-alpha.7",
70
+ "@common-stack/core": "6.0.8-alpha.7",
71
+ "@common-stack/remix-router-redux": "6.0.8-alpha.7",
72
+ "@common-stack/server-core": "6.0.8-alpha.9",
73
73
  "@reduxjs/toolkit": "^2.2.6",
74
74
  "@remix-run/express": "~2.10.1",
75
75
  "@remix-run/node": "~2.10.1",
@@ -62,7 +62,7 @@
62
62
  "dependencies": {
63
63
  "@apollo/client": "^3.9.0",
64
64
  "@babel/runtime": "^7.20.1",
65
- "@common-stack/server-stack": "6.0.8-alpha.0",
65
+ "@common-stack/server-stack": "6.0.8-alpha.10",
66
66
  "@remix-run/node": "~2.10.1",
67
67
  "lodash": "^4.17.15",
68
68
  "react": "18.2.0"
@@ -1,4 +1,6 @@
1
- process.env.ENV_FILE !== null && require('dotenv').config({ path: process.env.ENV_FILE });
1
+ if (process.env.ENV_FILE) {
2
+ require('dotenv').config({ path: process.env.ENV_FILE });
3
+ }
2
4
  const webpack = require('webpack');
3
5
  const path = require('path');
4
6
  const { CleanWebpackPlugin } = require('clean-webpack-plugin');
@@ -52,7 +52,7 @@
52
52
  "watch:test": "cross-env ENV_FILE=../../config/test/test.env node ./server.js"
53
53
  },
54
54
  "dependencies": {
55
- "@common-stack/frontend-stack-react": "6.0.8-alpha.0",
55
+ "@common-stack/frontend-stack-react": "6.0.8-alpha.9",
56
56
  "@react-icons/all-files": "^4.1.0",
57
57
  "classnames": "^2.2.6",
58
58
  "compression": "^1.7.4",
@@ -63,7 +63,6 @@
63
63
  "lodash": "^4.17.15",
64
64
  "lodash-es": "^4.17.21",
65
65
  "moment": "2.29.1",
66
- "remix-utils": "^7.6.0",
67
66
  "ramda": "^0.30.1",
68
67
  "react-ga4": "^2.1.0",
69
68
  "react-helmet": "^6.1.0",
@@ -72,12 +71,13 @@
72
71
  "react-icons-converter": "^1.1.4",
73
72
  "react-transition-group": "^4.3.0",
74
73
  "react-use": "^17.2.4",
74
+ "remix-utils": "^7.6.0",
75
75
  "reselect": "^4.0.0",
76
76
  "vite-env-only": "^2.2.1"
77
77
  },
78
78
  "devDependencies": {
79
79
  "@cdmbase/vite-plugin-i18next-loader": "^2.0.12",
80
- "@common-stack/rollup-vite-utils": "6.0.8-alpha.0",
80
+ "@common-stack/rollup-vite-utils": "6.0.8-alpha.7",
81
81
  "@remix-run/dev": "~2.10.1",
82
82
  "@remix-run/serve": "~2.10.1",
83
83
  "cross-env": "^7.0.3",
@@ -146,9 +146,9 @@
146
146
  "@babel/preset-typescript": "^7.18.6",
147
147
  "@babel/register": "^7.18.9",
148
148
  "@babel/runtime": "^7.20.1",
149
- "@common-stack/env-list-loader": "6.0.8-alpha.0",
150
- "@common-stack/generate-plugin": "6.0.8-alpha.0",
151
- "@common-stack/rollup-vite-utils": "6.0.8-alpha.0",
149
+ "@common-stack/env-list-loader": "6.0.8-alpha.7",
150
+ "@common-stack/generate-plugin": "6.0.8-alpha.10",
151
+ "@common-stack/rollup-vite-utils": "6.0.8-alpha.7",
152
152
  "@emotion/babel-plugin": "^11.11.0",
153
153
  "@graphql-codegen/add": "^5.0.2",
154
154
  "@graphql-codegen/cli": "^5.0.2",
@@ -272,7 +272,7 @@
272
272
  "jest-raw-loader": "^1.0.1",
273
273
  "jest-transform-graphql": "^2.1.0",
274
274
  "jsdom": "^20.0.2",
275
- "lerna": "8",
275
+ "lerna": "8.1.8",
276
276
  "less": "^4.1.3",
277
277
  "less-loader": "^11.0.0",
278
278
  "lint-staged": "^15.2.7",
@@ -25,11 +25,11 @@
25
25
  "watch": "npm run start:dev"
26
26
  },
27
27
  "dependencies": {
28
- "@common-stack/client-core": "6.0.8-alpha.0",
29
- "@common-stack/core": "6.0.8-alpha.0",
30
- "@common-stack/server-core": "6.0.8-alpha.0",
31
- "@common-stack/server-stack": "6.0.8-alpha.0",
32
- "@common-stack/store-mongo": "6.0.8-alpha.0",
28
+ "@common-stack/client-core": "6.0.8-alpha.7",
29
+ "@common-stack/core": "6.0.8-alpha.7",
30
+ "@common-stack/server-core": "6.0.8-alpha.9",
31
+ "@common-stack/server-stack": "6.0.8-alpha.10",
32
+ "@common-stack/store-mongo": "6.0.8-alpha.10",
33
33
  "@container-stack/mailing-api": "5.2.1-alpha.1",
34
34
  "helmet": "^3.21.2",
35
35
  "react": "18.2.0",
@@ -1,11 +1,24 @@
1
1
  import graphql from '@rollup/plugin-graphql';
2
2
  import typescript from '@rollup/plugin-typescript';
3
3
  import { string } from 'rollup-plugin-string';
4
+ import path from 'path';
5
+ import { fileURLToPath } from 'url';
6
+ import { writeBackendModuleFile } from '@common-stack/rollup-vite-utils';
7
+
8
+ const __filename = fileURLToPath(import.meta.url);
9
+ const __dirname = path.dirname(__filename);
10
+
11
+ // Write backend module file before bundling
12
+ try {
13
+ const packageConfig = await import('./config.json', { assert: { type: 'json' } });
14
+ await writeBackendModuleFile(path.join(__dirname, 'src/modules'), packageConfig.default);
15
+ } catch (e) {
16
+ console.error('Error writing backend module file:', e);
17
+ }
4
18
 
5
19
  const bundle = (config) => ({
6
20
  ...config,
7
21
  input: 'src/index.ts',
8
- // marking all node modules as external
9
22
  external: (id) => !/^[./]/.test(id),
10
23
  });
11
24
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@common-stack/generate-plugin",
3
- "version": "6.0.8-alpha.1",
3
+ "version": "6.0.8-alpha.11",
4
4
  "type": "module",
5
5
  "main": "./lib/index.mjs",
6
6
  "typings": "./lib/index.d.ts",
@@ -17,7 +17,7 @@
17
17
  "watch": "yarn build:lib:watch"
18
18
  },
19
19
  "dependencies": {
20
- "@common-stack/rollup-vite-utils": "6.0.8-alpha.1",
20
+ "@common-stack/rollup-vite-utils": "6.0.8-alpha.7",
21
21
  "tslib": "^2.3.0"
22
22
  },
23
23
  "publishConfig": {
@@ -25,5 +25,5 @@
25
25
  },
26
26
  "executors": "./executors.json",
27
27
  "generators": "./generators.json",
28
- "gitHead": "bad0cdee8b052117347c03008b06f8c0c99a6018"
28
+ "gitHead": "2f5c585fe2b4d81bb3c70ce248fe3a38c7a9f43b"
29
29
  }
@@ -146,9 +146,9 @@
146
146
  "@babel/preset-typescript": "^7.18.6",
147
147
  "@babel/register": "^7.18.9",
148
148
  "@babel/runtime": "^7.20.1",
149
- "@common-stack/env-list-loader": "6.0.8-alpha.0",
150
- "@common-stack/generate-plugin": "6.0.8-alpha.0",
151
- "@common-stack/rollup-vite-utils": "6.0.8-alpha.0",
149
+ "@common-stack/env-list-loader": "6.0.8-alpha.7",
150
+ "@common-stack/generate-plugin": "6.0.8-alpha.10",
151
+ "@common-stack/rollup-vite-utils": "6.0.8-alpha.7",
152
152
  "@emotion/babel-plugin": "^11.11.0",
153
153
  "@graphql-codegen/add": "^5.0.2",
154
154
  "@graphql-codegen/cli": "^5.0.2",
@@ -272,7 +272,7 @@
272
272
  "jest-raw-loader": "^1.0.1",
273
273
  "jest-transform-graphql": "^2.1.0",
274
274
  "jsdom": "^20.0.2",
275
- "lerna": "8",
275
+ "lerna": "8.1.8",
276
276
  "less": "^4.1.3",
277
277
  "less-loader": "^11.0.0",
278
278
  "lint-staged": "^15.2.7",
@@ -25,11 +25,11 @@
25
25
  "watch": "npm run start:dev"
26
26
  },
27
27
  "dependencies": {
28
- "@common-stack/client-core": "6.0.8-alpha.0",
29
- "@common-stack/core": "6.0.8-alpha.0",
30
- "@common-stack/server-core": "6.0.8-alpha.0",
31
- "@common-stack/server-stack": "6.0.8-alpha.0",
32
- "@common-stack/store-mongo": "6.0.8-alpha.0",
28
+ "@common-stack/client-core": "6.0.8-alpha.7",
29
+ "@common-stack/core": "6.0.8-alpha.7",
30
+ "@common-stack/server-core": "6.0.8-alpha.9",
31
+ "@common-stack/server-stack": "6.0.8-alpha.10",
32
+ "@common-stack/store-mongo": "6.0.8-alpha.10",
33
33
  "@container-stack/mailing-api": "5.2.1-alpha.1",
34
34
  "helmet": "^3.21.2",
35
35
  "react": "18.2.0",
@@ -1,11 +1,24 @@
1
1
  import graphql from '@rollup/plugin-graphql';
2
2
  import typescript from '@rollup/plugin-typescript';
3
3
  import { string } from 'rollup-plugin-string';
4
+ import path from 'path';
5
+ import { fileURLToPath } from 'url';
6
+ import { writeBackendModuleFile } from '@common-stack/rollup-vite-utils';
7
+
8
+ const __filename = fileURLToPath(import.meta.url);
9
+ const __dirname = path.dirname(__filename);
10
+
11
+ // Write backend module file before bundling
12
+ try {
13
+ const packageConfig = await import('./config.json', { assert: { type: 'json' } });
14
+ await writeBackendModuleFile(path.join(__dirname, 'src/modules'), packageConfig.default);
15
+ } catch (e) {
16
+ console.error('Error writing backend module file:', e);
17
+ }
4
18
 
5
19
  const bundle = (config) => ({
6
20
  ...config,
7
21
  input: 'src/index.ts',
8
- // marking all node modules as external
9
22
  external: (id) => !/^[./]/.test(id),
10
23
  });
11
24
 
@@ -1,31 +0,0 @@
1
- import { ContainerModule, interfaces } from 'inversify';
2
- import { Feature } from '@common-stack/server-core';
3
- import { TaggedType } from '@common-stack/core';
4
- import { config } from '../config';
5
-
6
- const subTopic = config.CONNECTION_ID;
7
- export const settings: any = {
8
- connectionId: config.CONNECTION_ID,
9
- namespace: config.NAMESPACE,
10
- subTopic,
11
- logger: config.LOG_LEVEL,
12
- workspaceId: config.CONNECTION_ID || 'DEFAULT',
13
- configPath: process.env.CONFIG_PATH,
14
- adminApiNamespace: 'api-admin',
15
- apiNamespace: 'api-admin',
16
- };
17
-
18
- const defaultModule = () =>
19
- new ContainerModule((bind: interfaces.Bind) => {
20
- bind('Settings').toConstantValue(settings).whenTargetTagged('default', true);
21
- bind('Settings').toConstantValue(settings).whenTargetTagged('microservice', true);
22
- bind('Settings').toConstantValue(settings).whenTargetTagged(TaggedType.MICROSERVICE, true);
23
- bind('MongoOptions').toConstantValue({});
24
- });
25
-
26
- const DefaultFeature = new Feature({
27
- createContainerFunc: [defaultModule],
28
- createHemeraContainerFunc: [defaultModule],
29
- });
30
-
31
- export default new Feature<any>(DefaultFeature);
@@ -1,31 +0,0 @@
1
- import { ContainerModule, interfaces } from 'inversify';
2
- import { Feature } from '@common-stack/server-core';
3
- import { TaggedType } from '@common-stack/core';
4
- import { config } from '../config';
5
-
6
- const subTopic = config.CONNECTION_ID;
7
- export const settings: any = {
8
- connectionId: config.CONNECTION_ID,
9
- namespace: config.NAMESPACE,
10
- subTopic,
11
- logger: config.LOG_LEVEL,
12
- workspaceId: config.CONNECTION_ID || 'DEFAULT',
13
- configPath: process.env.CONFIG_PATH,
14
- adminApiNamespace: 'api-admin',
15
- apiNamespace: 'api-admin',
16
- };
17
-
18
- const defaultModule = () =>
19
- new ContainerModule((bind: interfaces.Bind) => {
20
- bind('Settings').toConstantValue(settings).whenTargetTagged('default', true);
21
- bind('Settings').toConstantValue(settings).whenTargetTagged('microservice', true);
22
- bind('Settings').toConstantValue(settings).whenTargetTagged(TaggedType.MICROSERVICE, true);
23
- bind('MongoOptions').toConstantValue({});
24
- });
25
-
26
- const DefaultFeature = new Feature({
27
- createContainerFunc: [defaultModule],
28
- createHemeraContainerFunc: [defaultModule],
29
- });
30
-
31
- export default new Feature<any>(DefaultFeature);