Initial Commit
This commit is contained in:
61
packages/security-stack/security/jws/vite.config.ts
Normal file
61
packages/security-stack/security/jws/vite.config.ts
Normal file
@@ -0,0 +1,61 @@
|
||||
import { defineConfig } from "vite";
|
||||
import dts from "vite-plugin-dts";
|
||||
|
||||
export default defineConfig({
|
||||
root: __dirname,
|
||||
cacheDir: "../../../node_modules/.vite/packages/jws",
|
||||
plugins: [
|
||||
dts({
|
||||
entryRoot: "src",
|
||||
tsconfigPath: "./tsconfig.lib.json",
|
||||
insertTypesEntry: true,
|
||||
}),
|
||||
],
|
||||
build: {
|
||||
outDir: "./dist",
|
||||
emptyOutDir: true,
|
||||
reportCompressedSize: true,
|
||||
sourcemap: true,
|
||||
lib: {
|
||||
entry: {
|
||||
index: "src/index.ts",
|
||||
"serialization/compact/index": "src/serialization/compact/index.ts",
|
||||
"serialization/flat/index": "src/serialization/flat/index.ts",
|
||||
"serialization/general/index": "src/serialization/general/index.ts",
|
||||
"header/index": "src/header/index.ts",
|
||||
"algorithms/index": "src/algorithms/index.ts",
|
||||
"keys/index": "src/keys/index.ts",
|
||||
"detached/index": "src/detached/index.ts",
|
||||
"base64url/index": "src/base64url/index.ts",
|
||||
"errors/index": "src/errors/index.ts",
|
||||
},
|
||||
formats: ["es"],
|
||||
},
|
||||
rollupOptions: {
|
||||
treeshake: true,
|
||||
output: {
|
||||
preserveModules: true,
|
||||
preserveModulesRoot: "src",
|
||||
entryFileNames: "[name].js",
|
||||
},
|
||||
external: [
|
||||
"@opentelemetry/api",
|
||||
"@suaveplan/crypto-curve",
|
||||
/^@suaveplan\/crypto-curve\//,
|
||||
"@suaveplan/crypto-hash",
|
||||
/^@suaveplan\/crypto-hash\//,
|
||||
"@suaveplan/crypto-rsa",
|
||||
/^@suaveplan\/crypto-rsa\//,
|
||||
"@suaveplan/crypto-utils",
|
||||
/^@suaveplan\/crypto-utils\//,
|
||||
"@suaveplan/error",
|
||||
"@suaveplan/types",
|
||||
"@suaveplan/x509",
|
||||
/^@suaveplan\/x509\//,
|
||||
"tslib",
|
||||
"zod",
|
||||
/^node:/,
|
||||
],
|
||||
},
|
||||
},
|
||||
});
|
||||
Reference in New Issue
Block a user