@prosopo/config 2.1.1 → 2.1.2
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/package.json +4 -4
- package/dist/cjs/dependencies.cjs +0 -160
- package/dist/cjs/index.cjs +0 -67
- package/dist/cjs/projectInfo.cjs +0 -82
- package/dist/cjs/provider/index.cjs +0 -4
- package/dist/cjs/provider/test.cjs +0 -28
- package/dist/cjs/vite/index.cjs +0 -16
- package/dist/cjs/vite/vite-plugin-close-and-copy.cjs +0 -43
- package/dist/cjs/vite/vite-plugin-fix-absolute-imports.cjs +0 -26
- package/dist/cjs/vite/vite-plugin-sourcemap-exclude.cjs +0 -17
- package/dist/cjs/vite/vite.backend.config.cjs +0 -95
- package/dist/cjs/vite/vite.commonjs.config.cjs +0 -56
- package/dist/cjs/vite/vite.frontend.config.cjs +0 -175
- package/dist/cjs/vite/vite.test.config.cjs +0 -48
- package/dist/cjs/webpack/index.cjs +0 -2
- package/dist/cjs/webpack/webpack.config.cjs +0 -141
- package/dist/dependencies.d.ts +0 -11
- package/dist/dependencies.d.ts.map +0 -1
- package/dist/dependencies.js +0 -138
- package/dist/dependencies.js.map +0 -1
- package/dist/index.d.ts +0 -6
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -6
- package/dist/index.js.map +0 -1
- package/dist/projectInfo.d.ts +0 -41
- package/dist/projectInfo.d.ts.map +0 -1
- package/dist/projectInfo.js +0 -41
- package/dist/projectInfo.js.map +0 -1
- package/dist/provider/index.d.ts +0 -2
- package/dist/provider/index.d.ts.map +0 -1
- package/dist/provider/index.js +0 -2
- package/dist/provider/index.js.map +0 -1
- package/dist/provider/test.d.ts +0 -104
- package/dist/provider/test.d.ts.map +0 -1
- package/dist/provider/test.js +0 -27
- package/dist/provider/test.js.map +0 -1
- package/dist/vite/NodejsPolarsDirnamePlugin.d.ts +0 -7
- package/dist/vite/NodejsPolarsDirnamePlugin.d.ts.map +0 -1
- package/dist/vite/NodejsPolarsDirnamePlugin.js +0 -22
- package/dist/vite/NodejsPolarsDirnamePlugin.js.map +0 -1
- package/dist/vite/NodejsPolarsNativeFilePlugin.d.ts +0 -9
- package/dist/vite/NodejsPolarsNativeFilePlugin.d.ts.map +0 -1
- package/dist/vite/NodejsPolarsNativeFilePlugin.js +0 -58
- package/dist/vite/NodejsPolarsNativeFilePlugin.js.map +0 -1
- package/dist/vite/index.d.ts +0 -8
- package/dist/vite/index.d.ts.map +0 -1
- package/dist/vite/index.js +0 -8
- package/dist/vite/index.js.map +0 -1
- package/dist/vite/types.d.ts +0 -2
- package/dist/vite/types.d.ts.map +0 -1
- package/dist/vite/types.js +0 -2
- package/dist/vite/types.js.map +0 -1
- package/dist/vite/vite-plugin-close-and-copy.d.ts +0 -7
- package/dist/vite/vite-plugin-close-and-copy.d.ts.map +0 -1
- package/dist/vite/vite-plugin-close-and-copy.js +0 -44
- package/dist/vite/vite-plugin-close-and-copy.js.map +0 -1
- package/dist/vite/vite-plugin-fix-absolute-imports.d.ts +0 -3
- package/dist/vite/vite-plugin-fix-absolute-imports.d.ts.map +0 -1
- package/dist/vite/vite-plugin-fix-absolute-imports.js +0 -22
- package/dist/vite/vite-plugin-fix-absolute-imports.js.map +0 -1
- package/dist/vite/vite-plugin-sourcemap-exclude.d.ts +0 -7
- package/dist/vite/vite-plugin-sourcemap-exclude.d.ts.map +0 -1
- package/dist/vite/vite-plugin-sourcemap-exclude.js +0 -15
- package/dist/vite/vite-plugin-sourcemap-exclude.js.map +0 -1
- package/dist/vite/vite.backend.config.d.ts +0 -3
- package/dist/vite/vite.backend.config.d.ts.map +0 -1
- package/dist/vite/vite.backend.config.js +0 -88
- package/dist/vite/vite.backend.config.js.map +0 -1
- package/dist/vite/vite.commonjs.config.d.ts +0 -3
- package/dist/vite/vite.commonjs.config.d.ts.map +0 -1
- package/dist/vite/vite.commonjs.config.js +0 -51
- package/dist/vite/vite.commonjs.config.js.map +0 -1
- package/dist/vite/vite.frontend.config.d.ts +0 -4
- package/dist/vite/vite.frontend.config.d.ts.map +0 -1
- package/dist/vite/vite.frontend.config.js +0 -144
- package/dist/vite/vite.frontend.config.js.map +0 -1
- package/dist/vite/vite.test.config.d.ts +0 -2
- package/dist/vite/vite.test.config.d.ts.map +0 -1
- package/dist/vite/vite.test.config.js +0 -45
- package/dist/vite/vite.test.config.js.map +0 -1
- package/dist/webpack/index.d.ts +0 -2
- package/dist/webpack/index.d.ts.map +0 -1
- package/dist/webpack/index.js +0 -2
- package/dist/webpack/index.js.map +0 -1
- package/dist/webpack/webpack.config.d.ts +0 -94
- package/dist/webpack/webpack.config.d.ts.map +0 -1
- package/dist/webpack/webpack.config.js +0 -113
- package/dist/webpack/webpack.config.js.map +0 -1
|
@@ -1,175 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
const node_module = require("node:module");
|
|
3
|
-
const path = require("node:path");
|
|
4
|
-
const common = require("@prosopo/common");
|
|
5
|
-
const nodeResolve = require("@rollup/plugin-node-resolve");
|
|
6
|
-
const typescript = require("@rollup/plugin-typescript");
|
|
7
|
-
const pluginWasm = require("@rollup/plugin-wasm");
|
|
8
|
-
const viteReact = require("@vitejs/plugin-react");
|
|
9
|
-
const css = require("rollup-plugin-import-css");
|
|
10
|
-
const rollupPluginVisualizer = require("rollup-plugin-visualizer");
|
|
11
|
-
const dependencies = require("../dependencies.cjs");
|
|
12
|
-
require("./index.cjs");
|
|
13
|
-
const vitePluginCloseAndCopy = require("./vite-plugin-close-and-copy.cjs");
|
|
14
|
-
const logger = common.getLogger("Info", "vite.config.js");
|
|
15
|
-
async function vite_frontend_config(packageName, bundleName, dir, entry, command, mode, copyOptions, tsConfigPaths, workspaceRoot) {
|
|
16
|
-
logger.info(`Running at ${dir} in ${mode} mode`);
|
|
17
|
-
const isProduction = mode === "production";
|
|
18
|
-
process.env.NODE_ENV = `${process.env.NODE_ENV || mode}`;
|
|
19
|
-
logger.info(`NODE_ENV: ${process.env.NODE_ENV}`);
|
|
20
|
-
const define = {
|
|
21
|
-
// used to stop websockets package from breaking
|
|
22
|
-
"process.env.WS_NO_BUFFER_UTIL": JSON.stringify("true"),
|
|
23
|
-
"process.env.WS_NO_UTF_8_VALIDATE": JSON.stringify("true"),
|
|
24
|
-
"process.env.NODE_ENV": JSON.stringify(process.env.NODE_ENV),
|
|
25
|
-
"process.env.PROSOPO_DEFAULT_ENVIRONMENT": JSON.stringify(
|
|
26
|
-
process.env.PROSOPO_DEFAULT_ENVIRONMENT || process.env.NODE_ENV || mode
|
|
27
|
-
),
|
|
28
|
-
"process.env.PROSOPO_SERVER_URL": JSON.stringify(
|
|
29
|
-
process.env.PROSOPO_SERVER_URL
|
|
30
|
-
),
|
|
31
|
-
"process.env._DEV_ONLY_WATCH_EVENTS": JSON.stringify(
|
|
32
|
-
process.env._DEV_ONLY_WATCH_EVENTS
|
|
33
|
-
),
|
|
34
|
-
"process.env.PROSOPO_MONGO_EVENTS_URI": JSON.stringify(
|
|
35
|
-
process.env.PROSOPO_MONGO_EVENTS_URI
|
|
36
|
-
),
|
|
37
|
-
"process.env.PROSOPO_PACKAGE_VERSION": JSON.stringify(
|
|
38
|
-
process.env.PROSOPO_PACKAGE_VERSION
|
|
39
|
-
),
|
|
40
|
-
"process.env.PROSOPO_DOCS_URL": JSON.stringify(
|
|
41
|
-
process.env.PROSOPO_DOCS_URL
|
|
42
|
-
),
|
|
43
|
-
// only needed if bundling with a site key
|
|
44
|
-
"process.env.PROSOPO_SITE_KEY": JSON.stringify(
|
|
45
|
-
process.env.PROSOPO_SITE_KEY
|
|
46
|
-
)
|
|
47
|
-
};
|
|
48
|
-
logger.info(`Env vars: ${JSON.stringify(define, null, 4)}`);
|
|
49
|
-
const { dependencies: deps, optionalPeerDependencies } = await dependencies.getDependencies(packageName, isProduction);
|
|
50
|
-
const { external, internal } = dependencies.filterDependencies(deps, [
|
|
51
|
-
"pm2",
|
|
52
|
-
"nodejs-polars",
|
|
53
|
-
"aws",
|
|
54
|
-
"webpack",
|
|
55
|
-
"vite"
|
|
56
|
-
]);
|
|
57
|
-
const allExternal = [
|
|
58
|
-
...node_module.builtinModules,
|
|
59
|
-
...node_module.builtinModules.map((m) => `node:${m}`),
|
|
60
|
-
...external,
|
|
61
|
-
...optionalPeerDependencies
|
|
62
|
-
];
|
|
63
|
-
logger.debug(
|
|
64
|
-
`Bundling. ${JSON.stringify(internal.slice(0, 10), null, 2)}... ${internal.length} deps`
|
|
65
|
-
);
|
|
66
|
-
const proto = RegExp.prototype;
|
|
67
|
-
proto.toJSON = RegExp.prototype.toString;
|
|
68
|
-
let drop;
|
|
69
|
-
let pure = [];
|
|
70
|
-
if (isProduction) {
|
|
71
|
-
drop = ["debugger"];
|
|
72
|
-
pure = ["console.log", "console.warn", "console.info", "console.debug"];
|
|
73
|
-
}
|
|
74
|
-
logger.info("Bundle name", bundleName);
|
|
75
|
-
return {
|
|
76
|
-
ssr: {
|
|
77
|
-
target: "webworker"
|
|
78
|
-
},
|
|
79
|
-
server: {
|
|
80
|
-
host: "127.0.0.1"
|
|
81
|
-
},
|
|
82
|
-
mode: mode || "development",
|
|
83
|
-
optimizeDeps: {
|
|
84
|
-
include: ["node_modules"],
|
|
85
|
-
force: true
|
|
86
|
-
},
|
|
87
|
-
esbuild: {
|
|
88
|
-
platform: "browser",
|
|
89
|
-
target: [
|
|
90
|
-
"es2020",
|
|
91
|
-
"chrome60",
|
|
92
|
-
"edge18",
|
|
93
|
-
"firefox60",
|
|
94
|
-
"node12",
|
|
95
|
-
"safari11"
|
|
96
|
-
],
|
|
97
|
-
drop,
|
|
98
|
-
pure,
|
|
99
|
-
legalComments: "none"
|
|
100
|
-
},
|
|
101
|
-
define,
|
|
102
|
-
build: {
|
|
103
|
-
outDir: path.resolve(dir, "dist/bundle"),
|
|
104
|
-
minify: isProduction,
|
|
105
|
-
ssr: false,
|
|
106
|
-
lib: {
|
|
107
|
-
entry: path.resolve(dir, entry),
|
|
108
|
-
name: bundleName,
|
|
109
|
-
fileName: `${bundleName}.bundle.js`,
|
|
110
|
-
formats: ["es"]
|
|
111
|
-
},
|
|
112
|
-
modulePreload: { polyfill: true },
|
|
113
|
-
commonjsOptions: {
|
|
114
|
-
exclude: ["mongodb/*"],
|
|
115
|
-
transformMixedEsModules: true,
|
|
116
|
-
strictRequires: "debug"
|
|
117
|
-
},
|
|
118
|
-
rollupOptions: {
|
|
119
|
-
treeshake: {
|
|
120
|
-
annotations: false,
|
|
121
|
-
propertyReadSideEffects: false,
|
|
122
|
-
tryCatchDeoptimization: false,
|
|
123
|
-
moduleSideEffects: "no-external",
|
|
124
|
-
//true,
|
|
125
|
-
preset: "smallest",
|
|
126
|
-
unknownGlobalSideEffects: false
|
|
127
|
-
},
|
|
128
|
-
experimentalLogSideEffects: false,
|
|
129
|
-
external: allExternal,
|
|
130
|
-
watch: false,
|
|
131
|
-
output: {
|
|
132
|
-
dir: path.resolve(dir, "dist/bundle"),
|
|
133
|
-
entryFileNames: `${bundleName}.bundle.js`
|
|
134
|
-
},
|
|
135
|
-
plugins: [
|
|
136
|
-
css(),
|
|
137
|
-
pluginWasm.wasm(),
|
|
138
|
-
// @ts-ignore
|
|
139
|
-
nodeResolve({
|
|
140
|
-
browser: true,
|
|
141
|
-
preferBuiltins: false,
|
|
142
|
-
rootDir: path.resolve(dir, "../../"),
|
|
143
|
-
dedupe: ["react", "react-dom"],
|
|
144
|
-
modulesOnly: true
|
|
145
|
-
}),
|
|
146
|
-
rollupPluginVisualizer.visualizer({
|
|
147
|
-
open: true,
|
|
148
|
-
template: "treemap",
|
|
149
|
-
//'list',
|
|
150
|
-
gzipSize: true,
|
|
151
|
-
brotliSize: true
|
|
152
|
-
}),
|
|
153
|
-
// I think we can use this plugin to build all packages instead of relying on the tsc step that's
|
|
154
|
-
// currently a precursor in package.json. However, it fails for the following reason:
|
|
155
|
-
// https://github.com/rollup/plugins/issues/243
|
|
156
|
-
// @ts-ignore
|
|
157
|
-
typescript({
|
|
158
|
-
tsconfig: path.resolve("./tsconfig.json"),
|
|
159
|
-
compilerOptions: { rootDir: path.resolve("./src") },
|
|
160
|
-
outDir: path.resolve(dir, "dist/bundle")
|
|
161
|
-
})
|
|
162
|
-
]
|
|
163
|
-
}
|
|
164
|
-
},
|
|
165
|
-
plugins: [
|
|
166
|
-
// Not sure if we need this plugin or not, it works without it
|
|
167
|
-
// @ts-ignore
|
|
168
|
-
viteReact(),
|
|
169
|
-
// Closes the bundler and copies the bundle to the client-bundle-example project unless we're in serve
|
|
170
|
-
// mode, in which case we don't want to close the bundler because it will close the server
|
|
171
|
-
command !== "serve" ? vitePluginCloseAndCopy(copyOptions) : void 0
|
|
172
|
-
]
|
|
173
|
-
};
|
|
174
|
-
}
|
|
175
|
-
module.exports = vite_frontend_config;
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
const config = require("vitest/config");
|
|
3
|
-
const vitePluginCloseAndCopy = require("./vite-plugin-close-and-copy.cjs");
|
|
4
|
-
const vitePluginSourcemapExclude = require("./vite-plugin-sourcemap-exclude.cjs");
|
|
5
|
-
function vite_test_config() {
|
|
6
|
-
const testTypeEnv = process.env.TEST_TYPE || "";
|
|
7
|
-
const testTypes = testTypeEnv.trim().split(",");
|
|
8
|
-
const testTypeGlob = `@(|${testTypes.map((t) => t ? `.${t.trim()}` : "").join("|")})`;
|
|
9
|
-
console.log(`Filtering tests by type: ${testTypeGlob}`);
|
|
10
|
-
return config.defineConfig({
|
|
11
|
-
build: {
|
|
12
|
-
minify: false,
|
|
13
|
-
sourcemap: false,
|
|
14
|
-
rollupOptions: {
|
|
15
|
-
maxParallelFileOps: 1,
|
|
16
|
-
cache: false,
|
|
17
|
-
output: {
|
|
18
|
-
sourcemap: false
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
},
|
|
22
|
-
test: {
|
|
23
|
-
//root: getRootDir(),
|
|
24
|
-
reporters: ["basic"],
|
|
25
|
-
include: [
|
|
26
|
-
`src/**/*${testTypeGlob}.@(test|spec).@(mts|cts|mjs|cjs|js|ts|tsx|jsx)`
|
|
27
|
-
],
|
|
28
|
-
watch: false,
|
|
29
|
-
exclude: ["**/node_modules/**", "**/dist/**"],
|
|
30
|
-
logHeapUsage: true,
|
|
31
|
-
coverage: {
|
|
32
|
-
enabled: true,
|
|
33
|
-
include: ["packages/*/src/**"]
|
|
34
|
-
},
|
|
35
|
-
typecheck: {
|
|
36
|
-
enabled: true
|
|
37
|
-
},
|
|
38
|
-
pool: "forks",
|
|
39
|
-
// forks is slower than 'threads' but more compatible with low-level libs (e.g. bcrypt)
|
|
40
|
-
testTimeout: 1e4
|
|
41
|
-
},
|
|
42
|
-
plugins: [
|
|
43
|
-
vitePluginSourcemapExclude({ excludeNodeModules: true }),
|
|
44
|
-
vitePluginCloseAndCopy()
|
|
45
|
-
]
|
|
46
|
-
});
|
|
47
|
-
}
|
|
48
|
-
module.exports = vite_test_config;
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __create = Object.create;
|
|
3
|
-
var __defProp = Object.defineProperty;
|
|
4
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __copyProps = (to, from, except, desc) => {
|
|
9
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
10
|
-
for (let key of __getOwnPropNames(from))
|
|
11
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
12
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
13
|
-
}
|
|
14
|
-
return to;
|
|
15
|
-
};
|
|
16
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
17
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
18
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
19
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
20
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
21
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
-
mod
|
|
23
|
-
));
|
|
24
|
-
const path = require("node:path");
|
|
25
|
-
const HtmlWebpackPlugin = require("html-webpack-plugin");
|
|
26
|
-
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
|
|
27
|
-
const NodePolyfillPlugin = require("node-polyfill-webpack-plugin");
|
|
28
|
-
const TerserPlugin = require("terser-webpack-plugin");
|
|
29
|
-
const moduleDirs = [path.resolve("./node_modules")];
|
|
30
|
-
const webpack_config = (mode) => {
|
|
31
|
-
const isProduction = mode === "production";
|
|
32
|
-
const libraryName = "react_app";
|
|
33
|
-
return {
|
|
34
|
-
resolve: {
|
|
35
|
-
extensions: [".js", ".jsx", ".ts", ".tsx"],
|
|
36
|
-
extensionAlias: {
|
|
37
|
-
".js": [".js", ".ts"]
|
|
38
|
-
},
|
|
39
|
-
modules: moduleDirs,
|
|
40
|
-
fullySpecified: false,
|
|
41
|
-
alias: {
|
|
42
|
-
"@polkadot/x-textdecoder": path.resolve(
|
|
43
|
-
"../../node_modules/@polkadot/util/node_modules/@polkadot/x-textdecoder"
|
|
44
|
-
),
|
|
45
|
-
"@polkadot/x-textencoder": path.resolve(
|
|
46
|
-
"../../node_modules/@polkadot/util/node_modules/@polkadot/x-textencoder"
|
|
47
|
-
)
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
externals: {
|
|
51
|
-
"node:url": "commonjs url",
|
|
52
|
-
url: "commonjs url"
|
|
53
|
-
},
|
|
54
|
-
entry: "./src/index.tsx",
|
|
55
|
-
output: {
|
|
56
|
-
filename: `${libraryName}.[name].bundle.js`,
|
|
57
|
-
path: path.resolve("./dist"),
|
|
58
|
-
publicPath: "/"
|
|
59
|
-
},
|
|
60
|
-
module: {
|
|
61
|
-
rules: [
|
|
62
|
-
// instead of using .babelrc, we can use babel-loader options
|
|
63
|
-
{
|
|
64
|
-
test: /\.(m?js|jsx|tsx|ts)$/,
|
|
65
|
-
exclude: /node_modules/,
|
|
66
|
-
use: {
|
|
67
|
-
loader: "babel-loader",
|
|
68
|
-
options: {
|
|
69
|
-
plugins: [
|
|
70
|
-
"@babel/plugin-transform-runtime",
|
|
71
|
-
"@babel/transform-class-properties",
|
|
72
|
-
"@babel/transform-object-rest-spread",
|
|
73
|
-
"@babel/plugin-transform-react-jsx",
|
|
74
|
-
[
|
|
75
|
-
"@babel/plugin-syntax-import-attributes",
|
|
76
|
-
{ deprecatedAssertSyntax: true }
|
|
77
|
-
]
|
|
78
|
-
],
|
|
79
|
-
presets: ["@babel/preset-env", "@babel/preset-typescript"]
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
{
|
|
84
|
-
include: /node_modules|src/,
|
|
85
|
-
test: /\.css$/,
|
|
86
|
-
resolve: {
|
|
87
|
-
fullySpecified: false
|
|
88
|
-
},
|
|
89
|
-
sideEffects: true,
|
|
90
|
-
use: [
|
|
91
|
-
MiniCssExtractPlugin.loader,
|
|
92
|
-
{
|
|
93
|
-
loader: require.resolve("css-loader"),
|
|
94
|
-
options: {
|
|
95
|
-
url: false
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
]
|
|
99
|
-
},
|
|
100
|
-
{
|
|
101
|
-
test: /locale\.json$/,
|
|
102
|
-
// match JSON files to optimize
|
|
103
|
-
loader: "webpack-json-access-optimizer"
|
|
104
|
-
},
|
|
105
|
-
// Fix for module
|
|
106
|
-
{
|
|
107
|
-
test: /packageInfo.js$/,
|
|
108
|
-
loader: "string-replace-loader",
|
|
109
|
-
options: {
|
|
110
|
-
search: /import\.meta && import\.meta\.url/g,
|
|
111
|
-
replace: "false"
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
]
|
|
115
|
-
},
|
|
116
|
-
plugins: [
|
|
117
|
-
new NodePolyfillPlugin(),
|
|
118
|
-
new HtmlWebpackPlugin({
|
|
119
|
-
template: "./src/index.html"
|
|
120
|
-
}),
|
|
121
|
-
new MiniCssExtractPlugin({
|
|
122
|
-
filename: "extr.[contenthash].css"
|
|
123
|
-
})
|
|
124
|
-
],
|
|
125
|
-
optimization: {
|
|
126
|
-
noEmitOnErrors: true,
|
|
127
|
-
minimize: isProduction,
|
|
128
|
-
minimizer: isProduction ? [
|
|
129
|
-
new TerserPlugin({
|
|
130
|
-
terserOptions: {
|
|
131
|
-
compress: {
|
|
132
|
-
drop_console: true
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
})
|
|
136
|
-
] : [],
|
|
137
|
-
usedExports: true
|
|
138
|
-
}
|
|
139
|
-
};
|
|
140
|
-
};
|
|
141
|
-
module.exports = webpack_config;
|
package/dist/dependencies.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
export declare function getTsConfigs(tsConfigPath: string, ignorePatterns?: RegExp[], tsConfigPaths?: string[], includeInitialTsConfig?: boolean): string[];
|
|
2
|
-
export declare function getExternalsFromReferences(tsConfigPath: string, ignorePatterns?: RegExp[]): Promise<string[]>;
|
|
3
|
-
export declare function getDependencies(packageName?: string, production?: boolean): Promise<{
|
|
4
|
-
dependencies: string[];
|
|
5
|
-
optionalPeerDependencies: string[];
|
|
6
|
-
}>;
|
|
7
|
-
export declare function filterDependencies(deps: string[], filters: string[]): {
|
|
8
|
-
internal: string[];
|
|
9
|
-
external: string[];
|
|
10
|
-
};
|
|
11
|
-
//# sourceMappingURL=dependencies.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dependencies.d.ts","sourceRoot":"","sources":["../src/dependencies.ts"],"names":[],"mappings":"AA0EA,wBAAgB,YAAY,CAC3B,YAAY,EAAE,MAAM,EACpB,cAAc,GAAE,MAAM,EAAO,EAC7B,aAAa,GAAE,MAAM,EAAO,EAC5B,sBAAsB,UAAO,GAC3B,MAAM,EAAE,CA4CV;AAOD,wBAAsB,0BAA0B,CAC/C,YAAY,EAAE,MAAM,EACpB,cAAc,GAAE,MAAM,EAAO,GAC3B,OAAO,CAAC,MAAM,EAAE,CAAC,CAmCnB;AAOD,wBAAsB,eAAe,CACpC,WAAW,CAAC,EAAE,MAAM,EACpB,UAAU,CAAC,EAAE,OAAO,GAClB,OAAO,CAAC;IAAE,YAAY,EAAE,MAAM,EAAE,CAAC;IAAC,wBAAwB,EAAE,MAAM,EAAE,CAAA;CAAE,CAAC,CA0CzE;AAOD,wBAAgB,kBAAkB,CACjC,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE,MAAM,EAAE,GACf;IAAE,QAAQ,EAAE,MAAM,EAAE,CAAC;IAAC,QAAQ,EAAE,MAAM,EAAE,CAAA;CAAE,CAe5C"}
|
package/dist/dependencies.js
DELETED
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
import child_process from "node:child_process";
|
|
2
|
-
import fs from "node:fs";
|
|
3
|
-
import path from "node:path";
|
|
4
|
-
import util from "node:util";
|
|
5
|
-
import { ProsopoEnvError, getLogger } from "@prosopo/common";
|
|
6
|
-
import { at } from "@prosopo/util";
|
|
7
|
-
const logger = getLogger("Info", "config.dependencies.js");
|
|
8
|
-
const exec = util.promisify(child_process.exec);
|
|
9
|
-
const tsConfigRegex = /\/[A-Za-z.]*\.json$/;
|
|
10
|
-
const peerDepsRegex = /UNMET\sOPTIONAL\sDEPENDENCY\s+(@*[\w\-/.]+)@/;
|
|
11
|
-
const depsRegex = /\s+(@*[\w\-/.]+)@/;
|
|
12
|
-
async function getPackageDir(packageName) {
|
|
13
|
-
let pkg = packageName;
|
|
14
|
-
if (packageName && !packageName.startsWith("@prosopo/")) {
|
|
15
|
-
pkg = `@prosopo/${packageName}`;
|
|
16
|
-
}
|
|
17
|
-
const pkgCommand = `npm list ${pkg} -ap`;
|
|
18
|
-
logger.info(`Running command ${pkgCommand}`);
|
|
19
|
-
const { stdout: packageDir, stderr } = await exec(pkgCommand);
|
|
20
|
-
if (stderr) {
|
|
21
|
-
throw new ProsopoEnvError("CONFIG.INVALID_PACKAGE_DIR", {
|
|
22
|
-
context: { stderr },
|
|
23
|
-
});
|
|
24
|
-
}
|
|
25
|
-
return packageDir.trim() || path.resolve();
|
|
26
|
-
}
|
|
27
|
-
function getReferenceTsConfigPath(initialTsConfigPath, reference) {
|
|
28
|
-
let refTSConfigPath = path.resolve(initialTsConfigPath.replace(tsConfigRegex, ""), reference.path);
|
|
29
|
-
if (!refTSConfigPath.endsWith(".json")) {
|
|
30
|
-
refTSConfigPath = path.resolve(refTSConfigPath, "tsconfig.json");
|
|
31
|
-
}
|
|
32
|
-
return refTSConfigPath;
|
|
33
|
-
}
|
|
34
|
-
export function getTsConfigs(tsConfigPath, ignorePatterns = [], tsConfigPaths = [], includeInitialTsConfig = true) {
|
|
35
|
-
let tsConfigs = [...tsConfigPaths];
|
|
36
|
-
const references = JSON.parse(fs.readFileSync(tsConfigPath).toString()).references;
|
|
37
|
-
if (!tsConfigs.includes(tsConfigPath)) {
|
|
38
|
-
if (references) {
|
|
39
|
-
const ignore = ignorePatterns && ignorePatterns.length > 0
|
|
40
|
-
? new RegExp(`${ignorePatterns.join("|")}`)
|
|
41
|
-
: undefined;
|
|
42
|
-
if (includeInitialTsConfig) {
|
|
43
|
-
tsConfigs.push(tsConfigPath);
|
|
44
|
-
}
|
|
45
|
-
const filteredReferences = references.filter((reference) => ignore ? !ignore.test(reference.path) : false);
|
|
46
|
-
for (const reference of filteredReferences) {
|
|
47
|
-
const refTSConfigPath = getReferenceTsConfigPath(tsConfigPath, reference);
|
|
48
|
-
const newTsConfigs = getTsConfigs(refTSConfigPath, ignorePatterns, tsConfigs);
|
|
49
|
-
if (newTsConfigs.length > 0) {
|
|
50
|
-
const distinctTsConfigPaths = new Set(tsConfigs.concat(newTsConfigs));
|
|
51
|
-
tsConfigs = [...distinctTsConfigPaths];
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
return tsConfigs;
|
|
57
|
-
}
|
|
58
|
-
export async function getExternalsFromReferences(tsConfigPath, ignorePatterns = []) {
|
|
59
|
-
const tsConfigPaths = getTsConfigs(tsConfigPath, ignorePatterns, [], false);
|
|
60
|
-
logger.debug("tsConfigPaths", tsConfigPaths);
|
|
61
|
-
const promises = [];
|
|
62
|
-
for (const refTsConfigPath of tsConfigPaths) {
|
|
63
|
-
const packageJsonPath = path.resolve(refTsConfigPath.replace(tsConfigRegex, ""), "package.json");
|
|
64
|
-
promises.push(new Promise((resolve, reject) => {
|
|
65
|
-
fs.stat(packageJsonPath, (err) => {
|
|
66
|
-
if (err) {
|
|
67
|
-
reject(err);
|
|
68
|
-
}
|
|
69
|
-
fs.readFile(new URL(packageJsonPath, import.meta.url), (err, buffer) => {
|
|
70
|
-
if (err) {
|
|
71
|
-
reject(err);
|
|
72
|
-
}
|
|
73
|
-
else {
|
|
74
|
-
const packageJson = JSON.parse(buffer.toString());
|
|
75
|
-
const pkg = packageJson.name;
|
|
76
|
-
resolve(pkg);
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
});
|
|
80
|
-
}));
|
|
81
|
-
}
|
|
82
|
-
const externals = await Promise.all(promises);
|
|
83
|
-
logger.debug("externals", externals);
|
|
84
|
-
return externals;
|
|
85
|
-
}
|
|
86
|
-
export async function getDependencies(packageName, production) {
|
|
87
|
-
let cmd = production
|
|
88
|
-
? "npm ls -a --silent --omit=dev --package-lock-only"
|
|
89
|
-
: "npm ls --silent -a --package-lock-only";
|
|
90
|
-
if (packageName) {
|
|
91
|
-
const packageDir = await getPackageDir(packageName);
|
|
92
|
-
cmd = `cd ${packageDir.trim()} && ${cmd}`;
|
|
93
|
-
logger.info(`Running command ${cmd} in ${packageDir}`);
|
|
94
|
-
}
|
|
95
|
-
const { stdout, stderr } = await exec(cmd);
|
|
96
|
-
if (stderr) {
|
|
97
|
-
throw new ProsopoEnvError("CONFIG.INVALID_PACKAGE_DIR", {
|
|
98
|
-
context: { stderr },
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
const deps = [];
|
|
102
|
-
const peerDeps = [];
|
|
103
|
-
for (const line of stdout.split("\n")) {
|
|
104
|
-
if (line.includes("UNMET OPTIONAL DEPENDENCY")) {
|
|
105
|
-
const parts = line.match(peerDepsRegex);
|
|
106
|
-
if (parts && parts.length > 1) {
|
|
107
|
-
peerDeps.push(at(parts, 1));
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
else {
|
|
111
|
-
const parts = line.match(depsRegex);
|
|
112
|
-
if (parts && parts.length > 1) {
|
|
113
|
-
deps.push(at(parts, 1));
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
return {
|
|
118
|
-
dependencies: deps.filter((x, i) => i === deps.indexOf(x)),
|
|
119
|
-
optionalPeerDependencies: peerDeps.filter((x, i) => i === peerDeps.indexOf(x)),
|
|
120
|
-
};
|
|
121
|
-
}
|
|
122
|
-
export function filterDependencies(deps, filters) {
|
|
123
|
-
const depsDeduped = deps.filter((x, i) => i === deps.indexOf(x));
|
|
124
|
-
const depsWithLength = depsDeduped.filter((dep) => dep.length > 0).sort();
|
|
125
|
-
const exclude = new RegExp(`${filters.join("|")}`);
|
|
126
|
-
const internal = [];
|
|
127
|
-
const external = [];
|
|
128
|
-
for (const dep of depsWithLength) {
|
|
129
|
-
if (exclude.test(dep)) {
|
|
130
|
-
external.push(dep);
|
|
131
|
-
}
|
|
132
|
-
else {
|
|
133
|
-
internal.push(dep);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
return { internal, external };
|
|
137
|
-
}
|
|
138
|
-
//# sourceMappingURL=dependencies.js.map
|
package/dist/dependencies.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dependencies.js","sourceRoot":"","sources":["../src/dependencies.ts"],"names":[],"mappings":"AAcA,OAAO,aAAa,MAA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AAM,GAAG,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;IAC1E,MAAM,OAAO,GAAG,IAAI,MAAM,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IAEnD,MAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,MAAM,QAAQ,GAAa,EAAE,CAAC;IAC9B,KAAK,MAAM,GAAG,IAAI,cAAc,EAAE,CAAC;QAClC,IAAI,OAAO,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;YACvB,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACpB,CAAC;aAAM,CAAC;YACP,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACpB,CAAC;IACF,CAAC;IACD,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,CAAC;AAC/B,CAAC"}
|
package/dist/index.d.ts
DELETED
package/dist/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAaA,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC"}
|
package/dist/index.js
DELETED
package/dist/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAaA,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC"}
|
package/dist/projectInfo.d.ts
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
export declare const getRootDir: () => string;
|
|
2
|
-
export declare const getCacheDir: () => string;
|
|
3
|
-
export declare const getTestResultsDir: () => string;
|
|
4
|
-
export declare const getDevDir: () => string;
|
|
5
|
-
export declare const getDemosDir: () => string;
|
|
6
|
-
export declare const getPackagesDir: () => string;
|
|
7
|
-
export declare const getNodeModulesDir: () => string;
|
|
8
|
-
export declare const getConfigPkgDir: () => string;
|
|
9
|
-
export declare const getScriptsPkgDir: () => string;
|
|
10
|
-
export declare const getClientExampleDir: () => string;
|
|
11
|
-
export declare const getClientExampleServerDir: () => string;
|
|
12
|
-
export declare const getClientBundleExampleDir: () => string;
|
|
13
|
-
export declare const getDappExampleDir: () => string;
|
|
14
|
-
export declare const getAccountPkgDir: () => string;
|
|
15
|
-
export declare const getApiPkgDir: () => string;
|
|
16
|
-
export declare const getCliPkgDir: () => string;
|
|
17
|
-
export declare const getCommonPkgDir: () => string;
|
|
18
|
-
export declare const getContractPkgDir: () => string;
|
|
19
|
-
export declare const getDatabasePkgDir: () => string;
|
|
20
|
-
export declare const getDatasetsPkgDir: () => string;
|
|
21
|
-
export declare const getDatasetsFsPkgDir: () => string;
|
|
22
|
-
export declare const getDotEnvPkgDir: () => string;
|
|
23
|
-
export declare const getEnvPkgDir: () => string;
|
|
24
|
-
export declare const getFileServerPkgDir: () => string;
|
|
25
|
-
export declare const getProcaptchaPkgDir: () => string;
|
|
26
|
-
export declare const getProcaptchaBundlePkgDir: () => string;
|
|
27
|
-
export declare const getProcaptchaCommonPkgDir: () => string;
|
|
28
|
-
export declare const getProcaptchaFrictionlessPkgDir: () => string;
|
|
29
|
-
export declare const getProcaptchaPoWPkgDir: () => string;
|
|
30
|
-
export declare const getProcaptchaReactPkgDir: () => string;
|
|
31
|
-
export declare const getProviderPkgDir: () => string;
|
|
32
|
-
export declare const getServerPkgDir: () => string;
|
|
33
|
-
export declare const getTxPkgDir: () => string;
|
|
34
|
-
export declare const getTypesPkgDir: () => string;
|
|
35
|
-
export declare const getTypesDatabasePkgDir: () => string;
|
|
36
|
-
export declare const getTypesEnvPkgDir: () => string;
|
|
37
|
-
export declare const getUtilPkgDir: () => string;
|
|
38
|
-
export declare const getWebComponentsPkgDir: () => string;
|
|
39
|
-
export declare const getLocalePkgDir: () => string;
|
|
40
|
-
export declare const getLocaleBrowserPkgDir: () => string;
|
|
41
|
-
//# sourceMappingURL=projectInfo.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"projectInfo.d.ts","sourceRoot":"","sources":["../src/projectInfo.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,UAAU,cACoC,CAAC;AAE5D,eAAO,MAAM,WAAW,cAAiC,CAAC;AAE1D,eAAO,MAAM,iBAAiB,cAAwC,CAAC;AAEvE,eAAO,MAAM,SAAS,cAA8B,CAAC;AAErD,eAAO,MAAM,WAAW,cAAgC,CAAC;AAEzD,eAAO,MAAM,cAAc,cAAmC,CAAC;AAE/D,eAAO,MAAM,iBAAiB,cAAuC,CAAC;AAItE,eAAO,MAAM,eAAe,cAAgC,CAAC;AAE7D,eAAO,MAAM,gBAAgB,cAAiC,CAAC;AAI/D,eAAO,MAAM,mBAAmB,cAA0C,CAAC;AAE3E,eAAO,MAAM,yBAAyB,cACG,CAAC;AAE1C,eAAO,MAAM,yBAAyB,cACG,CAAC;AAE1C,eAAO,MAAM,iBAAiB,cAAwC,CAAC;AAIvE,eAAO,MAAM,gBAAgB,cAAsC,CAAC;AAEpE,eAAO,MAAM,YAAY,cAAkC,CAAC;AAE5D,eAAO,MAAM,YAAY,cAAkC,CAAC;AAE5D,eAAO,MAAM,eAAe,cAAqC,CAAC;AAElE,eAAO,MAAM,iBAAiB,cAAuC,CAAC;AAEtE,eAAO,MAAM,iBAAiB,cAAuC,CAAC;AAEtE,eAAO,MAAM,iBAAiB,cAAuC,CAAC;AAEtE,eAAO,MAAM,mBAAmB,cAA0C,CAAC;AAE3E,eAAO,MAAM,eAAe,cAAqC,CAAC;AAElE,eAAO,MAAM,YAAY,cAAkC,CAAC;AAE5D,eAAO,MAAM,mBAAmB,cAA0C,CAAC;AAE3E,eAAO,MAAM,mBAAmB,cAAyC,CAAC;AAE1E,eAAO,MAAM,yBAAyB,cACE,CAAC;AAEzC,eAAO,MAAM,yBAAyB,cACE,CAAC;AAEzC,eAAO,MAAM,+BAA+B,cACE,CAAC;AAE/C,eAAO,MAAM,sBAAsB,cACE,CAAC;AAEtC,eAAO,MAAM,wBAAwB,cACE,CAAC;AAExC,eAAO,MAAM,iBAAiB,cAAuC,CAAC;AAEtE,eAAO,MAAM,eAAe,cAAqC,CAAC;AAElE,eAAO,MAAM,WAAW,cAAiC,CAAC;AAE1D,eAAO,MAAM,cAAc,cAAoC,CAAC;AAEhE,eAAO,MAAM,sBAAsB,cACE,CAAC;AAEtC,eAAO,MAAM,iBAAiB,cAAwC,CAAC;AAEvE,eAAO,MAAM,aAAa,cAAmC,CAAC;AAE9D,eAAO,MAAM,sBAAsB,cACE,CAAC;AAEtC,eAAO,MAAM,eAAe,cAAqC,CAAC;AAElE,eAAO,MAAM,sBAAsB,cACE,CAAC"}
|
package/dist/projectInfo.js
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
export const getRootDir = () => new URL("../../..", import.meta.url).pathname.slice(0, -1);
|
|
2
|
-
export const getCacheDir = () => `${getRootDir()}/.cache`;
|
|
3
|
-
export const getTestResultsDir = () => `${getCacheDir()}/test-results`;
|
|
4
|
-
export const getDevDir = () => `${getRootDir()}/dev`;
|
|
5
|
-
export const getDemosDir = () => `${getRootDir()}/demos`;
|
|
6
|
-
export const getPackagesDir = () => `${getRootDir()}/packages`;
|
|
7
|
-
export const getNodeModulesDir = () => `${getRootDir()}/node_modules`;
|
|
8
|
-
export const getConfigPkgDir = () => `${getDevDir()}/config`;
|
|
9
|
-
export const getScriptsPkgDir = () => `${getDevDir()}/scripts`;
|
|
10
|
-
export const getClientExampleDir = () => `${getDemosDir()}/client-example`;
|
|
11
|
-
export const getClientExampleServerDir = () => `${getDemosDir()}/client-example-server`;
|
|
12
|
-
export const getClientBundleExampleDir = () => `${getDemosDir()}/client-bundle-example`;
|
|
13
|
-
export const getDappExampleDir = () => `${getDemosDir()}/dapp-example`;
|
|
14
|
-
export const getAccountPkgDir = () => `${getPackagesDir()}/account`;
|
|
15
|
-
export const getApiPkgDir = () => `${getPackagesDir()}/api`;
|
|
16
|
-
export const getCliPkgDir = () => `${getPackagesDir()}/cli`;
|
|
17
|
-
export const getCommonPkgDir = () => `${getPackagesDir()}/common`;
|
|
18
|
-
export const getContractPkgDir = () => `${getPackagesDir()}/contract`;
|
|
19
|
-
export const getDatabasePkgDir = () => `${getPackagesDir()}/database`;
|
|
20
|
-
export const getDatasetsPkgDir = () => `${getPackagesDir()}/datasets`;
|
|
21
|
-
export const getDatasetsFsPkgDir = () => `${getPackagesDir()}/datasets-fs`;
|
|
22
|
-
export const getDotEnvPkgDir = () => `${getPackagesDir()}/dotenv`;
|
|
23
|
-
export const getEnvPkgDir = () => `${getPackagesDir()}/env`;
|
|
24
|
-
export const getFileServerPkgDir = () => `${getPackagesDir()}/file-server`;
|
|
25
|
-
export const getProcaptchaPkgDir = () => `${getPackagesDir()}/procaptcha`;
|
|
26
|
-
export const getProcaptchaBundlePkgDir = () => `${getPackagesDir()}/procaptcha-bundle`;
|
|
27
|
-
export const getProcaptchaCommonPkgDir = () => `${getPackagesDir()}/procaptcha-common`;
|
|
28
|
-
export const getProcaptchaFrictionlessPkgDir = () => `${getPackagesDir()}/procaptcha-frictionless`;
|
|
29
|
-
export const getProcaptchaPoWPkgDir = () => `${getPackagesDir()}/procaptcha-pow`;
|
|
30
|
-
export const getProcaptchaReactPkgDir = () => `${getPackagesDir()}/procaptcha-react`;
|
|
31
|
-
export const getProviderPkgDir = () => `${getPackagesDir()}/provider`;
|
|
32
|
-
export const getServerPkgDir = () => `${getPackagesDir()}/server`;
|
|
33
|
-
export const getTxPkgDir = () => `${getPackagesDir()}/tx`;
|
|
34
|
-
export const getTypesPkgDir = () => `${getPackagesDir()}/types`;
|
|
35
|
-
export const getTypesDatabasePkgDir = () => `${getPackagesDir()}/types-database`;
|
|
36
|
-
export const getTypesEnvPkgDir = () => `${getPackagesDir()}/types-env`;
|
|
37
|
-
export const getUtilPkgDir = () => `${getPackagesDir()}/util`;
|
|
38
|
-
export const getWebComponentsPkgDir = () => `${getPackagesDir()}/web-components`;
|
|
39
|
-
export const getLocalePkgDir = () => `${getPackagesDir()}/locale`;
|
|
40
|
-
export const getLocaleBrowserPkgDir = () => `${getPackagesDir()}/locale-browser`;
|
|
41
|
-
//# sourceMappingURL=projectInfo.js.map
|
package/dist/projectInfo.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"projectInfo.js","sourceRoot":"","sources":["../src/projectInfo.ts"],"names":[],"mappings":"AAgBA,MAAM,CAAC,MAAM,UAAU,GAAG,GAAG,EAAE,CAC9B,IAAI,GAAG,CAAC,UAAU,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;AAE5D,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,EAAE,CAAC,GAAG,UAAU,EAAE,SAAS,CAAC;AAE1D,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,EAAE,CAAC,GAAG,WAAW,EAAE,eAAe,CAAC;AAEvE,MAAM,CAAC,MAAM,SAAS,GAAG,GAAG,EAAE,CAAC,GAAG,UAAU,EAAE,MAAM,CAAC;AAErD,MAAM,CAAC,MAAM,WAAW,GAAG,GAAG,EAAE,CAAC,GAAG,UAAU,EAAE,QAAQ,CAAC;AAEzD,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,EAAE,CAAC,GAAG,UAAU,EAAE,WAAW,CAAC;AAE/D,MAAM,CAAC,MAAM,iBAAiB,GAAG,GAAG,EAAE,CAAC,GAAG,UAAU,EAAE,eAAe,CAAC;AAItE,MAAM,CAAC,MAAM,eAAe,GAAG,GAAG,EAAE,CAAC,GAAG,SAAS,EAAE,SAAS,CAAC;AAE7D,MAAM,CAA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