chore: update version to 0.0.51, add auto.ts to files, and update dependencies
feat: enhance parseXml function to handle Bun requests and refactor XML parsing logic
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://json.schemastore.org/package",
|
"$schema": "https://json.schemastore.org/package",
|
||||||
"name": "@kevisual/router",
|
"name": "@kevisual/router",
|
||||||
"version": "0.0.50",
|
"version": "0.0.51",
|
||||||
"description": "",
|
"description": "",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "./dist/router.js",
|
"main": "./dist/router.js",
|
||||||
@@ -15,6 +15,7 @@
|
|||||||
"files": [
|
"files": [
|
||||||
"dist",
|
"dist",
|
||||||
"src",
|
"src",
|
||||||
|
"auto.ts",
|
||||||
"mod.ts"
|
"mod.ts"
|
||||||
],
|
],
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
|
|||||||
246
pnpm-lock.yaml
generated
246
pnpm-lock.yaml
generated
@@ -12,8 +12,8 @@ importers:
|
|||||||
specifier: ^8.3.0
|
specifier: ^8.3.0
|
||||||
version: 8.3.0
|
version: 8.3.0
|
||||||
selfsigned:
|
selfsigned:
|
||||||
specifier: ^5.2.0
|
specifier: ^5.4.0
|
||||||
version: 5.2.0
|
version: 5.4.0
|
||||||
send:
|
send:
|
||||||
specifier: ^1.2.1
|
specifier: ^1.2.1
|
||||||
version: 1.2.1
|
version: 1.2.1
|
||||||
@@ -22,20 +22,20 @@ importers:
|
|||||||
specifier: ^0.0.8
|
specifier: ^0.0.8
|
||||||
version: 0.0.8
|
version: 0.0.8
|
||||||
'@kevisual/query':
|
'@kevisual/query':
|
||||||
specifier: ^0.0.32
|
specifier: ^0.0.33
|
||||||
version: 0.0.32
|
version: 0.0.33
|
||||||
'@rollup/plugin-alias':
|
'@rollup/plugin-alias':
|
||||||
specifier: ^6.0.0
|
specifier: ^6.0.0
|
||||||
version: 6.0.0(rollup@4.53.5)
|
version: 6.0.0(rollup@4.54.0)
|
||||||
'@rollup/plugin-commonjs':
|
'@rollup/plugin-commonjs':
|
||||||
specifier: 29.0.0
|
specifier: 29.0.0
|
||||||
version: 29.0.0(rollup@4.53.5)
|
version: 29.0.0(rollup@4.54.0)
|
||||||
'@rollup/plugin-node-resolve':
|
'@rollup/plugin-node-resolve':
|
||||||
specifier: ^16.0.3
|
specifier: ^16.0.3
|
||||||
version: 16.0.3(rollup@4.53.5)
|
version: 16.0.3(rollup@4.54.0)
|
||||||
'@rollup/plugin-typescript':
|
'@rollup/plugin-typescript':
|
||||||
specifier: ^12.3.0
|
specifier: ^12.3.0
|
||||||
version: 12.3.0(rollup@4.53.5)(tslib@2.8.1)(typescript@5.9.3)
|
version: 12.3.0(rollup@4.54.0)(tslib@2.8.1)(typescript@5.9.3)
|
||||||
'@types/bun':
|
'@types/bun':
|
||||||
specifier: ^1.3.5
|
specifier: ^1.3.5
|
||||||
version: 1.3.5
|
version: 1.3.5
|
||||||
@@ -58,11 +58,11 @@ importers:
|
|||||||
specifier: ^5.1.6
|
specifier: ^5.1.6
|
||||||
version: 5.1.6
|
version: 5.1.6
|
||||||
rollup:
|
rollup:
|
||||||
specifier: ^4.53.5
|
specifier: ^4.54.0
|
||||||
version: 4.53.5
|
version: 4.54.0
|
||||||
rollup-plugin-dts:
|
rollup-plugin-dts:
|
||||||
specifier: ^6.3.0
|
specifier: ^6.3.0
|
||||||
version: 6.3.0(rollup@4.53.5)(typescript@5.9.3)
|
version: 6.3.0(rollup@4.54.0)(typescript@5.9.3)
|
||||||
ts-loader:
|
ts-loader:
|
||||||
specifier: ^9.5.4
|
specifier: ^9.5.4
|
||||||
version: 9.5.4(typescript@5.9.3)(webpack@5.104.1)
|
version: 9.5.4(typescript@5.9.3)(webpack@5.104.1)
|
||||||
@@ -296,8 +296,8 @@ packages:
|
|||||||
'@kevisual/local-proxy@0.0.8':
|
'@kevisual/local-proxy@0.0.8':
|
||||||
resolution: {integrity: sha512-VX/P+6/Cc8ruqp34ag6gVX073BchUmf5VNZcTV/6MJtjrNE76G8V6TLpBE8bywLnrqyRtFLIspk4QlH8up9B5Q==}
|
resolution: {integrity: sha512-VX/P+6/Cc8ruqp34ag6gVX073BchUmf5VNZcTV/6MJtjrNE76G8V6TLpBE8bywLnrqyRtFLIspk4QlH8up9B5Q==}
|
||||||
|
|
||||||
'@kevisual/query@0.0.32':
|
'@kevisual/query@0.0.33':
|
||||||
resolution: {integrity: sha512-9WN9cjmwSW8I5A0SqITdts9oxlLBGdPP7kJ8vwrxkaQteHS9FzxKuMBJxZzGKZdyte/zJDvdrE+lMf254BGbbg==}
|
resolution: {integrity: sha512-3w74bcLpwV3z483eg8n0DgkftfjWC6iLONXBvfyjW6IZf6jMOuouFaM4Rk+uEsTgElU6XGMKseNTp6dlQdWYkg==}
|
||||||
|
|
||||||
'@kevisual/ws@8.0.0':
|
'@kevisual/ws@8.0.0':
|
||||||
resolution: {integrity: sha512-jlFxSlXUEz93cFW+UYT5BXv/rFVgiMQnIfqRYZ0gj1hSP8PMGRqMqUoHSLfKvfRRS4jseLSvTTeEKSQpZJtURg==}
|
resolution: {integrity: sha512-jlFxSlXUEz93cFW+UYT5BXv/rFVgiMQnIfqRYZ0gj1hSP8PMGRqMqUoHSLfKvfRRS4jseLSvTTeEKSQpZJtURg==}
|
||||||
@@ -390,113 +390,113 @@ packages:
|
|||||||
rollup:
|
rollup:
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-android-arm-eabi@4.53.5':
|
'@rollup/rollup-android-arm-eabi@4.54.0':
|
||||||
resolution: {integrity: sha512-iDGS/h7D8t7tvZ1t6+WPK04KD0MwzLZrG0se1hzBjSi5fyxlsiggoJHwh18PCFNn7tG43OWb6pdZ6Y+rMlmyNQ==}
|
resolution: {integrity: sha512-OywsdRHrFvCdvsewAInDKCNyR3laPA2mc9bRYJ6LBp5IyvF3fvXbbNR0bSzHlZVFtn6E0xw2oZlyjg4rKCVcng==}
|
||||||
cpu: [arm]
|
cpu: [arm]
|
||||||
os: [android]
|
os: [android]
|
||||||
|
|
||||||
'@rollup/rollup-android-arm64@4.53.5':
|
'@rollup/rollup-android-arm64@4.54.0':
|
||||||
resolution: {integrity: sha512-wrSAViWvZHBMMlWk6EJhvg8/rjxzyEhEdgfMMjREHEq11EtJ6IP6yfcCH57YAEca2Oe3FNCE9DSTgU70EIGmVw==}
|
resolution: {integrity: sha512-Skx39Uv+u7H224Af+bDgNinitlmHyQX1K/atIA32JP3JQw6hVODX5tkbi2zof/E69M1qH2UoN3Xdxgs90mmNYw==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [android]
|
os: [android]
|
||||||
|
|
||||||
'@rollup/rollup-darwin-arm64@4.53.5':
|
'@rollup/rollup-darwin-arm64@4.54.0':
|
||||||
resolution: {integrity: sha512-S87zZPBmRO6u1YXQLwpveZm4JfPpAa6oHBX7/ghSiGH3rz/KDgAu1rKdGutV+WUI6tKDMbaBJomhnT30Y2t4VQ==}
|
resolution: {integrity: sha512-k43D4qta/+6Fq+nCDhhv9yP2HdeKeP56QrUUTW7E6PhZP1US6NDqpJj4MY0jBHlJivVJD5P8NxrjuobZBJTCRw==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [darwin]
|
os: [darwin]
|
||||||
|
|
||||||
'@rollup/rollup-darwin-x64@4.53.5':
|
'@rollup/rollup-darwin-x64@4.54.0':
|
||||||
resolution: {integrity: sha512-YTbnsAaHo6VrAczISxgpTva8EkfQus0VPEVJCEaboHtZRIb6h6j0BNxRBOwnDciFTZLDPW5r+ZBmhL/+YpTZgA==}
|
resolution: {integrity: sha512-cOo7biqwkpawslEfox5Vs8/qj83M/aZCSSNIWpVzfU2CYHa2G3P1UN5WF01RdTHSgCkri7XOlTdtk17BezlV3A==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [darwin]
|
os: [darwin]
|
||||||
|
|
||||||
'@rollup/rollup-freebsd-arm64@4.53.5':
|
'@rollup/rollup-freebsd-arm64@4.54.0':
|
||||||
resolution: {integrity: sha512-1T8eY2J8rKJWzaznV7zedfdhD1BqVs1iqILhmHDq/bqCUZsrMt+j8VCTHhP0vdfbHK3e1IQ7VYx3jlKqwlf+vw==}
|
resolution: {integrity: sha512-miSvuFkmvFbgJ1BevMa4CPCFt5MPGw094knM64W9I0giUIMMmRYcGW/JWZDriaw/k1kOBtsWh1z6nIFV1vPNtA==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [freebsd]
|
os: [freebsd]
|
||||||
|
|
||||||
'@rollup/rollup-freebsd-x64@4.53.5':
|
'@rollup/rollup-freebsd-x64@4.54.0':
|
||||||
resolution: {integrity: sha512-sHTiuXyBJApxRn+VFMaw1U+Qsz4kcNlxQ742snICYPrY+DDL8/ZbaC4DVIB7vgZmp3jiDaKA0WpBdP0aqPJoBQ==}
|
resolution: {integrity: sha512-KGXIs55+b/ZfZsq9aR026tmr/+7tq6VG6MsnrvF4H8VhwflTIuYh+LFUlIsRdQSgrgmtM3fVATzEAj4hBQlaqQ==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [freebsd]
|
os: [freebsd]
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm-gnueabihf@4.53.5':
|
'@rollup/rollup-linux-arm-gnueabihf@4.54.0':
|
||||||
resolution: {integrity: sha512-dV3T9MyAf0w8zPVLVBptVlzaXxka6xg1f16VAQmjg+4KMSTWDvhimI/Y6mp8oHwNrmnmVl9XxJ/w/mO4uIQONA==}
|
resolution: {integrity: sha512-EHMUcDwhtdRGlXZsGSIuXSYwD5kOT9NVnx9sqzYiwAc91wfYOE1g1djOEDseZJKKqtHAHGwnGPQu3kytmfaXLQ==}
|
||||||
cpu: [arm]
|
cpu: [arm]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm-musleabihf@4.53.5':
|
'@rollup/rollup-linux-arm-musleabihf@4.54.0':
|
||||||
resolution: {integrity: sha512-wIGYC1x/hyjP+KAu9+ewDI+fi5XSNiUi9Bvg6KGAh2TsNMA3tSEs+Sh6jJ/r4BV/bx/CyWu2ue9kDnIdRyafcQ==}
|
resolution: {integrity: sha512-+pBrqEjaakN2ySv5RVrj/qLytYhPKEUwk+e3SFU5jTLHIcAtqh2rLrd/OkbNuHJpsBgxsD8ccJt5ga/SeG0JmA==}
|
||||||
cpu: [arm]
|
cpu: [arm]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm64-gnu@4.53.5':
|
'@rollup/rollup-linux-arm64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-Y+qVA0D9d0y2FRNiG9oM3Hut/DgODZbU9I8pLLPwAsU0tUKZ49cyV1tzmB/qRbSzGvY8lpgGkJuMyuhH7Ma+Vg==}
|
resolution: {integrity: sha512-NSqc7rE9wuUaRBsBp5ckQ5CVz5aIRKCwsoa6WMF7G01sX3/qHUw/z4pv+D+ahL1EIKy6Enpcnz1RY8pf7bjwng==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm64-musl@4.53.5':
|
'@rollup/rollup-linux-arm64-musl@4.54.0':
|
||||||
resolution: {integrity: sha512-juaC4bEgJsyFVfqhtGLz8mbopaWD+WeSOYr5E16y+1of6KQjc0BpwZLuxkClqY1i8sco+MdyoXPNiCkQou09+g==}
|
resolution: {integrity: sha512-gr5vDbg3Bakga5kbdpqx81m2n9IX8M6gIMlQQIXiLTNeQW6CucvuInJ91EuCJ/JYvc+rcLLsDFcfAD1K7fMofg==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-loong64-gnu@4.53.5':
|
'@rollup/rollup-linux-loong64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-rIEC0hZ17A42iXtHX+EPJVL/CakHo+tT7W0pbzdAGuWOt2jxDFh7A/lRhsNHBcqL4T36+UiAgwO8pbmn3dE8wA==}
|
resolution: {integrity: sha512-gsrtB1NA3ZYj2vq0Rzkylo9ylCtW/PhpLEivlgWe0bpgtX5+9j9EZa0wtZiCjgu6zmSeZWyI/e2YRX1URozpIw==}
|
||||||
cpu: [loong64]
|
cpu: [loong64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-ppc64-gnu@4.53.5':
|
'@rollup/rollup-linux-ppc64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-T7l409NhUE552RcAOcmJHj3xyZ2h7vMWzcwQI0hvn5tqHh3oSoclf9WgTl+0QqffWFG8MEVZZP1/OBglKZx52Q==}
|
resolution: {integrity: sha512-y3qNOfTBStmFNq+t4s7Tmc9hW2ENtPg8FeUD/VShI7rKxNW7O4fFeaYbMsd3tpFlIg1Q8IapFgy7Q9i2BqeBvA==}
|
||||||
cpu: [ppc64]
|
cpu: [ppc64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-riscv64-gnu@4.53.5':
|
'@rollup/rollup-linux-riscv64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-7OK5/GhxbnrMcxIFoYfhV/TkknarkYC1hqUw1wU2xUN3TVRLNT5FmBv4KkheSG2xZ6IEbRAhTooTV2+R5Tk0lQ==}
|
resolution: {integrity: sha512-89sepv7h2lIVPsFma8iwmccN7Yjjtgz0Rj/Ou6fEqg3HDhpCa+Et+YSufy27i6b0Wav69Qv4WBNl3Rs6pwhebQ==}
|
||||||
cpu: [riscv64]
|
cpu: [riscv64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-riscv64-musl@4.53.5':
|
'@rollup/rollup-linux-riscv64-musl@4.54.0':
|
||||||
resolution: {integrity: sha512-GwuDBE/PsXaTa76lO5eLJTyr2k8QkPipAyOrs4V/KJufHCZBJ495VCGJol35grx9xryk4V+2zd3Ri+3v7NPh+w==}
|
resolution: {integrity: sha512-ZcU77ieh0M2Q8Ur7D5X7KvK+UxbXeDHwiOt/CPSBTI1fBmeDMivW0dPkdqkT4rOgDjrDDBUed9x4EgraIKoR2A==}
|
||||||
cpu: [riscv64]
|
cpu: [riscv64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-s390x-gnu@4.53.5':
|
'@rollup/rollup-linux-s390x-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-IAE1Ziyr1qNfnmiQLHBURAD+eh/zH1pIeJjeShleII7Vj8kyEm2PF77o+lf3WTHDpNJcu4IXJxNO0Zluro8bOw==}
|
resolution: {integrity: sha512-2AdWy5RdDF5+4YfG/YesGDDtbyJlC9LHmL6rZw6FurBJ5n4vFGupsOBGfwMRjBYH7qRQowT8D/U4LoSvVwOhSQ==}
|
||||||
cpu: [s390x]
|
cpu: [s390x]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-x64-gnu@4.53.5':
|
'@rollup/rollup-linux-x64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-Pg6E+oP7GvZ4XwgRJBuSXZjcqpIW3yCBhK4BcsANvb47qMvAbCjR6E+1a/U2WXz1JJxp9/4Dno3/iSJLcm5auw==}
|
resolution: {integrity: sha512-WGt5J8Ij/rvyqpFexxk3ffKqqbLf9AqrTBbWDk7ApGUzaIs6V+s2s84kAxklFwmMF/vBNGrVdYgbblCOFFezMQ==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-linux-x64-musl@4.53.5':
|
'@rollup/rollup-linux-x64-musl@4.54.0':
|
||||||
resolution: {integrity: sha512-txGtluxDKTxaMDzUduGP0wdfng24y1rygUMnmlUJ88fzCCULCLn7oE5kb2+tRB+MWq1QDZT6ObT5RrR8HFRKqg==}
|
resolution: {integrity: sha512-JzQmb38ATzHjxlPHuTH6tE7ojnMKM2kYNzt44LO/jJi8BpceEC8QuXYA908n8r3CNuG/B3BV8VR3Hi1rYtmPiw==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [linux]
|
os: [linux]
|
||||||
|
|
||||||
'@rollup/rollup-openharmony-arm64@4.53.5':
|
'@rollup/rollup-openharmony-arm64@4.54.0':
|
||||||
resolution: {integrity: sha512-3DFiLPnTxiOQV993fMc+KO8zXHTcIjgaInrqlG8zDp1TlhYl6WgrOHuJkJQ6M8zHEcntSJsUp1XFZSY8C1DYbg==}
|
resolution: {integrity: sha512-huT3fd0iC7jigGh7n3q/+lfPcXxBi+om/Rs3yiFxjvSxbSB6aohDFXbWvlspaqjeOh+hx7DDHS+5Es5qRkWkZg==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [openharmony]
|
os: [openharmony]
|
||||||
|
|
||||||
'@rollup/rollup-win32-arm64-msvc@4.53.5':
|
'@rollup/rollup-win32-arm64-msvc@4.54.0':
|
||||||
resolution: {integrity: sha512-nggc/wPpNTgjGg75hu+Q/3i32R00Lq1B6N1DO7MCU340MRKL3WZJMjA9U4K4gzy3dkZPXm9E1Nc81FItBVGRlA==}
|
resolution: {integrity: sha512-c2V0W1bsKIKfbLMBu/WGBz6Yci8nJ/ZJdheE0EwB73N3MvHYKiKGs3mVilX4Gs70eGeDaMqEob25Tw2Gb9Nqyw==}
|
||||||
cpu: [arm64]
|
cpu: [arm64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
'@rollup/rollup-win32-ia32-msvc@4.53.5':
|
'@rollup/rollup-win32-ia32-msvc@4.54.0':
|
||||||
resolution: {integrity: sha512-U/54pTbdQpPLBdEzCT6NBCFAfSZMvmjr0twhnD9f4EIvlm9wy3jjQ38yQj1AGznrNO65EWQMgm/QUjuIVrYF9w==}
|
resolution: {integrity: sha512-woEHgqQqDCkAzrDhvDipnSirm5vxUXtSKDYTVpZG3nUdW/VVB5VdCYA2iReSj/u3yCZzXID4kuKG7OynPnB3WQ==}
|
||||||
cpu: [ia32]
|
cpu: [ia32]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
'@rollup/rollup-win32-x64-gnu@4.53.5':
|
'@rollup/rollup-win32-x64-gnu@4.54.0':
|
||||||
resolution: {integrity: sha512-2NqKgZSuLH9SXBBV2dWNRCZmocgSOx8OJSdpRaEcRlIfX8YrKxUT6z0F1NpvDVhOsl190UFTRh2F2WDWWCYp3A==}
|
resolution: {integrity: sha512-dzAc53LOuFvHwbCEOS0rPbXp6SIhAf2txMP5p6mGyOXXw5mWY8NGGbPMPrs4P1WItkfApDathBj/NzMLUZ9rtQ==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
'@rollup/rollup-win32-x64-msvc@4.53.5':
|
'@rollup/rollup-win32-x64-msvc@4.54.0':
|
||||||
resolution: {integrity: sha512-JRpZUhCfhZ4keB5v0fe02gQJy05GqboPOaxvjugW04RLSYYoB/9t2lx2u/tMs/Na/1NXfY8QYjgRljRpN+MjTQ==}
|
resolution: {integrity: sha512-hYT5d3YNdSh3mbCU1gwQyPgQd3T2ne0A3KG8KSBdav5TiBg6eInVmV+TeR5uHufiIgSFg0XsOWGW5/RhNcSvPg==}
|
||||||
cpu: [x64]
|
cpu: [x64]
|
||||||
os: [win32]
|
os: [win32]
|
||||||
|
|
||||||
@@ -956,8 +956,8 @@ packages:
|
|||||||
rollup: ^3.29.4 || ^4
|
rollup: ^3.29.4 || ^4
|
||||||
typescript: ^4.5 || ^5.0
|
typescript: ^4.5 || ^5.0
|
||||||
|
|
||||||
rollup@4.53.5:
|
rollup@4.54.0:
|
||||||
resolution: {integrity: sha512-iTNAbFSlRpcHeeWu73ywU/8KuU/LZmNCSxp6fjQkJBD3ivUb8tpDrXhIxEzA05HlYMEwmtaUnb3RP+YNv162OQ==}
|
resolution: {integrity: sha512-3nk8Y3a9Ea8szgKhinMlGMhGMw89mqule3KWczxhIzqudyHdCIOHw8WJlj/r329fACjKLEh13ZSk7oE22kyeIw==}
|
||||||
engines: {node: '>=18.0.0', npm: '>=8.0.0'}
|
engines: {node: '>=18.0.0', npm: '>=8.0.0'}
|
||||||
hasBin: true
|
hasBin: true
|
||||||
|
|
||||||
@@ -971,8 +971,8 @@ packages:
|
|||||||
resolution: {integrity: sha512-eflK8wEtyOE6+hsaRVPxvUKYCpRgzLqDTb8krvAsRIwOGlHoSgYLgBXoubGgLd2fT41/OUYdb48v4k4WWHQurA==}
|
resolution: {integrity: sha512-eflK8wEtyOE6+hsaRVPxvUKYCpRgzLqDTb8krvAsRIwOGlHoSgYLgBXoubGgLd2fT41/OUYdb48v4k4WWHQurA==}
|
||||||
engines: {node: '>= 10.13.0'}
|
engines: {node: '>= 10.13.0'}
|
||||||
|
|
||||||
selfsigned@5.2.0:
|
selfsigned@5.4.0:
|
||||||
resolution: {integrity: sha512-QKF6fsJgdKn5Cy1SekTuwUQ6LOLUdnO4gVne1+TGSAyL/CD1aznNCmBna+bQB9xyon7DiYbDtTR1cLaxDXuaVA==}
|
resolution: {integrity: sha512-Yn8qZOOJv+NhcGY19iC+ngW6hlUCNpvWEkrKllXNhmkLgR9fcErm8EqZ/wev7/tiwjKC9qj17Fa/PtBNzb6q8g==}
|
||||||
engines: {node: '>=15.6.0'}
|
engines: {node: '>=15.6.0'}
|
||||||
|
|
||||||
semver@7.7.3:
|
semver@7.7.3:
|
||||||
@@ -1256,7 +1256,7 @@ snapshots:
|
|||||||
|
|
||||||
'@kevisual/local-proxy@0.0.8': {}
|
'@kevisual/local-proxy@0.0.8': {}
|
||||||
|
|
||||||
'@kevisual/query@0.0.32': {}
|
'@kevisual/query@0.0.33': {}
|
||||||
|
|
||||||
'@kevisual/ws@8.0.0': {}
|
'@kevisual/ws@8.0.0': {}
|
||||||
|
|
||||||
@@ -1352,13 +1352,13 @@ snapshots:
|
|||||||
tslib: 2.8.1
|
tslib: 2.8.1
|
||||||
tsyringe: 4.10.0
|
tsyringe: 4.10.0
|
||||||
|
|
||||||
'@rollup/plugin-alias@6.0.0(rollup@4.53.5)':
|
'@rollup/plugin-alias@6.0.0(rollup@4.54.0)':
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
|
|
||||||
'@rollup/plugin-commonjs@29.0.0(rollup@4.53.5)':
|
'@rollup/plugin-commonjs@29.0.0(rollup@4.54.0)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@rollup/pluginutils': 5.3.0(rollup@4.53.5)
|
'@rollup/pluginutils': 5.3.0(rollup@4.54.0)
|
||||||
commondir: 1.0.1
|
commondir: 1.0.1
|
||||||
estree-walker: 2.0.2
|
estree-walker: 2.0.2
|
||||||
fdir: 6.5.0(picomatch@4.0.3)
|
fdir: 6.5.0(picomatch@4.0.3)
|
||||||
@@ -1366,99 +1366,99 @@ snapshots:
|
|||||||
magic-string: 0.30.21
|
magic-string: 0.30.21
|
||||||
picomatch: 4.0.3
|
picomatch: 4.0.3
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
|
|
||||||
'@rollup/plugin-node-resolve@16.0.3(rollup@4.53.5)':
|
'@rollup/plugin-node-resolve@16.0.3(rollup@4.54.0)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@rollup/pluginutils': 5.3.0(rollup@4.53.5)
|
'@rollup/pluginutils': 5.3.0(rollup@4.54.0)
|
||||||
'@types/resolve': 1.20.2
|
'@types/resolve': 1.20.2
|
||||||
deepmerge: 4.3.1
|
deepmerge: 4.3.1
|
||||||
is-module: 1.0.0
|
is-module: 1.0.0
|
||||||
resolve: 1.22.11
|
resolve: 1.22.11
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
|
|
||||||
'@rollup/plugin-typescript@12.3.0(rollup@4.53.5)(tslib@2.8.1)(typescript@5.9.3)':
|
'@rollup/plugin-typescript@12.3.0(rollup@4.54.0)(tslib@2.8.1)(typescript@5.9.3)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@rollup/pluginutils': 5.3.0(rollup@4.53.5)
|
'@rollup/pluginutils': 5.3.0(rollup@4.54.0)
|
||||||
resolve: 1.22.11
|
resolve: 1.22.11
|
||||||
typescript: 5.9.3
|
typescript: 5.9.3
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
tslib: 2.8.1
|
tslib: 2.8.1
|
||||||
|
|
||||||
'@rollup/pluginutils@5.3.0(rollup@4.53.5)':
|
'@rollup/pluginutils@5.3.0(rollup@4.54.0)':
|
||||||
dependencies:
|
dependencies:
|
||||||
'@types/estree': 1.0.8
|
'@types/estree': 1.0.8
|
||||||
estree-walker: 2.0.2
|
estree-walker: 2.0.2
|
||||||
picomatch: 4.0.3
|
picomatch: 4.0.3
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
|
|
||||||
'@rollup/rollup-android-arm-eabi@4.53.5':
|
'@rollup/rollup-android-arm-eabi@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-android-arm64@4.53.5':
|
'@rollup/rollup-android-arm64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-darwin-arm64@4.53.5':
|
'@rollup/rollup-darwin-arm64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-darwin-x64@4.53.5':
|
'@rollup/rollup-darwin-x64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-freebsd-arm64@4.53.5':
|
'@rollup/rollup-freebsd-arm64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-freebsd-x64@4.53.5':
|
'@rollup/rollup-freebsd-x64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm-gnueabihf@4.53.5':
|
'@rollup/rollup-linux-arm-gnueabihf@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm-musleabihf@4.53.5':
|
'@rollup/rollup-linux-arm-musleabihf@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm64-gnu@4.53.5':
|
'@rollup/rollup-linux-arm64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-arm64-musl@4.53.5':
|
'@rollup/rollup-linux-arm64-musl@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-loong64-gnu@4.53.5':
|
'@rollup/rollup-linux-loong64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-ppc64-gnu@4.53.5':
|
'@rollup/rollup-linux-ppc64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-riscv64-gnu@4.53.5':
|
'@rollup/rollup-linux-riscv64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-riscv64-musl@4.53.5':
|
'@rollup/rollup-linux-riscv64-musl@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-s390x-gnu@4.53.5':
|
'@rollup/rollup-linux-s390x-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-x64-gnu@4.53.5':
|
'@rollup/rollup-linux-x64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-linux-x64-musl@4.53.5':
|
'@rollup/rollup-linux-x64-musl@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-openharmony-arm64@4.53.5':
|
'@rollup/rollup-openharmony-arm64@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-win32-arm64-msvc@4.53.5':
|
'@rollup/rollup-win32-arm64-msvc@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-win32-ia32-msvc@4.53.5':
|
'@rollup/rollup-win32-ia32-msvc@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-win32-x64-gnu@4.53.5':
|
'@rollup/rollup-win32-x64-gnu@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@rollup/rollup-win32-x64-msvc@4.53.5':
|
'@rollup/rollup-win32-x64-msvc@4.54.0':
|
||||||
optional: true
|
optional: true
|
||||||
|
|
||||||
'@tsconfig/node10@1.0.12': {}
|
'@tsconfig/node10@1.0.12': {}
|
||||||
@@ -1893,40 +1893,40 @@ snapshots:
|
|||||||
path-parse: 1.0.7
|
path-parse: 1.0.7
|
||||||
supports-preserve-symlinks-flag: 1.0.0
|
supports-preserve-symlinks-flag: 1.0.0
|
||||||
|
|
||||||
rollup-plugin-dts@6.3.0(rollup@4.53.5)(typescript@5.9.3):
|
rollup-plugin-dts@6.3.0(rollup@4.54.0)(typescript@5.9.3):
|
||||||
dependencies:
|
dependencies:
|
||||||
magic-string: 0.30.21
|
magic-string: 0.30.21
|
||||||
rollup: 4.53.5
|
rollup: 4.54.0
|
||||||
typescript: 5.9.3
|
typescript: 5.9.3
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
'@babel/code-frame': 7.27.1
|
'@babel/code-frame': 7.27.1
|
||||||
|
|
||||||
rollup@4.53.5:
|
rollup@4.54.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@types/estree': 1.0.8
|
'@types/estree': 1.0.8
|
||||||
optionalDependencies:
|
optionalDependencies:
|
||||||
'@rollup/rollup-android-arm-eabi': 4.53.5
|
'@rollup/rollup-android-arm-eabi': 4.54.0
|
||||||
'@rollup/rollup-android-arm64': 4.53.5
|
'@rollup/rollup-android-arm64': 4.54.0
|
||||||
'@rollup/rollup-darwin-arm64': 4.53.5
|
'@rollup/rollup-darwin-arm64': 4.54.0
|
||||||
'@rollup/rollup-darwin-x64': 4.53.5
|
'@rollup/rollup-darwin-x64': 4.54.0
|
||||||
'@rollup/rollup-freebsd-arm64': 4.53.5
|
'@rollup/rollup-freebsd-arm64': 4.54.0
|
||||||
'@rollup/rollup-freebsd-x64': 4.53.5
|
'@rollup/rollup-freebsd-x64': 4.54.0
|
||||||
'@rollup/rollup-linux-arm-gnueabihf': 4.53.5
|
'@rollup/rollup-linux-arm-gnueabihf': 4.54.0
|
||||||
'@rollup/rollup-linux-arm-musleabihf': 4.53.5
|
'@rollup/rollup-linux-arm-musleabihf': 4.54.0
|
||||||
'@rollup/rollup-linux-arm64-gnu': 4.53.5
|
'@rollup/rollup-linux-arm64-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-arm64-musl': 4.53.5
|
'@rollup/rollup-linux-arm64-musl': 4.54.0
|
||||||
'@rollup/rollup-linux-loong64-gnu': 4.53.5
|
'@rollup/rollup-linux-loong64-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-ppc64-gnu': 4.53.5
|
'@rollup/rollup-linux-ppc64-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-riscv64-gnu': 4.53.5
|
'@rollup/rollup-linux-riscv64-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-riscv64-musl': 4.53.5
|
'@rollup/rollup-linux-riscv64-musl': 4.54.0
|
||||||
'@rollup/rollup-linux-s390x-gnu': 4.53.5
|
'@rollup/rollup-linux-s390x-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-x64-gnu': 4.53.5
|
'@rollup/rollup-linux-x64-gnu': 4.54.0
|
||||||
'@rollup/rollup-linux-x64-musl': 4.53.5
|
'@rollup/rollup-linux-x64-musl': 4.54.0
|
||||||
'@rollup/rollup-openharmony-arm64': 4.53.5
|
'@rollup/rollup-openharmony-arm64': 4.54.0
|
||||||
'@rollup/rollup-win32-arm64-msvc': 4.53.5
|
'@rollup/rollup-win32-arm64-msvc': 4.54.0
|
||||||
'@rollup/rollup-win32-ia32-msvc': 4.53.5
|
'@rollup/rollup-win32-ia32-msvc': 4.54.0
|
||||||
'@rollup/rollup-win32-x64-gnu': 4.53.5
|
'@rollup/rollup-win32-x64-gnu': 4.54.0
|
||||||
'@rollup/rollup-win32-x64-msvc': 4.53.5
|
'@rollup/rollup-win32-x64-msvc': 4.54.0
|
||||||
fsevents: 2.3.3
|
fsevents: 2.3.3
|
||||||
|
|
||||||
safe-buffer@5.2.1: {}
|
safe-buffer@5.2.1: {}
|
||||||
@@ -1940,7 +1940,7 @@ snapshots:
|
|||||||
ajv-formats: 2.1.1(ajv@8.17.1)
|
ajv-formats: 2.1.1(ajv@8.17.1)
|
||||||
ajv-keywords: 5.1.0(ajv@8.17.1)
|
ajv-keywords: 5.1.0(ajv@8.17.1)
|
||||||
|
|
||||||
selfsigned@5.2.0:
|
selfsigned@5.4.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
'@peculiar/x509': 1.14.2
|
'@peculiar/x509': 1.14.2
|
||||||
pkijs: 3.3.3
|
pkijs: 3.3.3
|
||||||
|
|||||||
10
src/route.ts
10
src/route.ts
@@ -576,10 +576,16 @@ export class QueryRouter {
|
|||||||
* -- .on
|
* -- .on
|
||||||
* -- .send
|
* -- .send
|
||||||
*/
|
*/
|
||||||
wait(params?: { path?: string; key?: string; payload?: any }, opts?: { emitter?: any, timeout?: number, getList?: boolean }) {
|
wait(params?: { path?: string; key?: string; payload?: any }, opts?: {
|
||||||
|
emitter?: any,
|
||||||
|
timeout?: number,
|
||||||
|
getList?: boolean
|
||||||
|
force?: boolean
|
||||||
|
filter?: (route: Route) => boolean
|
||||||
|
}) {
|
||||||
const getList = opts?.getList ?? true;
|
const getList = opts?.getList ?? true;
|
||||||
if (getList) {
|
if (getList) {
|
||||||
this.createRouteList();
|
this.createRouteList(opts?.force ?? false, opts?.filter);
|
||||||
}
|
}
|
||||||
return listenProcess({ app: this, params, ...opts });
|
return listenProcess({ app: this, params, ...opts });
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,34 @@
|
|||||||
import xml2js from 'xml2js';
|
import xml2js from 'xml2js';
|
||||||
|
import { isBun } from '../utils/is-engine.ts';
|
||||||
export const parseXml = async (req: any): Promise<any> => {
|
import http from 'http';
|
||||||
|
export const xms2jsParser = async (data: string): Promise<any> => {
|
||||||
|
try {
|
||||||
|
// 使用xml2js解析XML
|
||||||
|
const xml = await xml2js.parseStringPromise(data);
|
||||||
|
return xml;
|
||||||
|
} catch (error) {
|
||||||
|
console.error('XML解析错误:', error);
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
export const parseXml = async (req: http.IncomingMessage): Promise<any> => {
|
||||||
|
if (isBun) {
|
||||||
|
// @ts-ignore
|
||||||
|
const body = req.body;
|
||||||
|
let xmlString = '';
|
||||||
|
if (body) {
|
||||||
|
xmlString = body;
|
||||||
|
}
|
||||||
|
if (!xmlString) {
|
||||||
|
// @ts-ignore
|
||||||
|
xmlString = await req.bun?.request?.text?.();
|
||||||
|
}
|
||||||
|
if (xmlString) {
|
||||||
|
return await xms2jsParser(xmlString)
|
||||||
|
}
|
||||||
|
console.error('没有读取到请求体');
|
||||||
|
return null;
|
||||||
|
}
|
||||||
return await new Promise((resolve) => {
|
return await new Promise((resolve) => {
|
||||||
// 读取请求数据
|
// 读取请求数据
|
||||||
let data = '';
|
let data = '';
|
||||||
@@ -12,15 +40,8 @@ export const parseXml = async (req: any): Promise<any> => {
|
|||||||
// 当请求结束时处理数据
|
// 当请求结束时处理数据
|
||||||
req.on('end', () => {
|
req.on('end', () => {
|
||||||
try {
|
try {
|
||||||
// 使用xml2js解析XML
|
xms2jsParser(data).then((result) => {
|
||||||
xml2js.parseString(data, function (err, result) {
|
resolve(result);
|
||||||
if (err) {
|
|
||||||
console.error('XML解析错误:', err);
|
|
||||||
resolve(null);
|
|
||||||
} else {
|
|
||||||
const jsonString = JSON.stringify(result);
|
|
||||||
resolve(jsonString);
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error('处理请求时出错:', error);
|
console.error('处理请求时出错:', error);
|
||||||
|
|||||||
Reference in New Issue
Block a user