Stuff
This commit is contained in:
@@ -1,5 +1,15 @@
|
||||
import fs from "fs"
|
||||
import fs from "node:fs"
|
||||
import { basename } from "node:path"
|
||||
|
||||
class UploadFile extends File {
|
||||
constructor(filepath) {
|
||||
super([], basename(filepath))
|
||||
}
|
||||
|
||||
stream() {
|
||||
return fs.createReadStream(this.filepath)
|
||||
}
|
||||
}
|
||||
|
||||
const apiKeySockenklaus = "bxmlNuUlPiY4YRRIcRuJ5eflZCU7aOHQPOgGmts4f8"
|
||||
const apiKeyTestUser = "xOUY572Rd6Fw3qoE3EFBFy3G3sITaIQsgPPc8TAbQ"
|
||||
@@ -13,7 +23,7 @@ const settings = {
|
||||
|
||||
const args = {
|
||||
tdarrPath: "/immich/6c0138fb-62c4-4a99-aeed-721a845f90f3/2025/07/SampleVideo_1280x720_10mb.mp4",
|
||||
newFile: "/home/socrates/Entwicklung/immich-api-test/javascript/SampleVideo_1280x720_30mb.mp4"
|
||||
newFile: "./SampleVideo_1280x720_30mb.mp4"
|
||||
}
|
||||
|
||||
const originalPath = args.tdarrPath.replace(settings.immichMount, "")
|
||||
@@ -23,12 +33,67 @@ const headers = {
|
||||
"x-api-key": settings.apiKey
|
||||
}
|
||||
|
||||
const searchRequest = new Request(settings.apiBaseUrl + "search/metadata", {
|
||||
method: "POST",
|
||||
body: JSON.stringify({ originalPath: originalPath }),
|
||||
headers: headers
|
||||
})
|
||||
async function getAssetByOriginalPath(path) {
|
||||
const searchRequest = new Request(settings.apiBaseUrl + "search/metadata", {
|
||||
method: "POST",
|
||||
body: JSON.stringify({ originalPath: path }),
|
||||
headers: headers
|
||||
})
|
||||
|
||||
try {
|
||||
const responsePromise = await fetch(searchRequest)
|
||||
const responseBody = await responsePromise.json()
|
||||
|
||||
if(responseBody.assets.total !== 1) {
|
||||
console.error(`Found ${body.assets.total} assets, stopping here`)
|
||||
return {}
|
||||
}
|
||||
|
||||
return {
|
||||
id: responseBody.assets.items[0].id,
|
||||
deviceAssetId: responseBody.assets.items[0].deviceAssetId,
|
||||
deviceId: responseBody.assets.items[0].deviceId,
|
||||
fileCreatedAt: responseBody.assets.items[0].fileCreatedAt,
|
||||
fileModifiedAt: responseBody.assets.items[0].fileModifiedAt
|
||||
}
|
||||
}
|
||||
catch(error) {
|
||||
console.error(error)
|
||||
}
|
||||
}
|
||||
|
||||
async function replaceAsset(assetInfo, newFilePath) {
|
||||
//const file = await fs.createReadStream(newFilePath)
|
||||
const file = await fs.readFile(newFilePath)
|
||||
|
||||
const uploadData = new FormData()
|
||||
uploadData.set("assetData", file)
|
||||
uploadData.set("deviceAssetId", assetInfo.deviceAssetId)
|
||||
uploadData.set("deviceId", assetInfo.deviceId)
|
||||
uploadData.set("fileCreatedAt", assetInfo.fileCreatedAt)
|
||||
uploadData.set("fileModifiedAt", assetInfo.fileModifiedAt)
|
||||
|
||||
const replaceRequest = new Request(settings.apiBaseUrl + "assets/"+assetInfo.id+"/original", {
|
||||
method: "PUT",
|
||||
headers: {
|
||||
"Accept": "application/json",
|
||||
"x-api-key": settings.apiKey
|
||||
},
|
||||
body: uploadData
|
||||
})
|
||||
const responsePromise = await fetch(replaceRequest)
|
||||
const responseBody = await responsePromise.json()
|
||||
|
||||
return responseBody
|
||||
}
|
||||
|
||||
const assetInfo = await getAssetByOriginalPath(originalPath)
|
||||
|
||||
console.log(JSON.stringify(assetInfo, undefined, 2))
|
||||
|
||||
console.log(await replaceAsset(assetInfo, args.newFile))
|
||||
|
||||
/*
|
||||
fetch(searchRequest)
|
||||
.then(response => {
|
||||
if(!response.ok){
|
||||
@@ -83,6 +148,6 @@ fetch(searchRequest)
|
||||
.catch(error => console.log(error))
|
||||
|
||||
|
||||
|
||||
*/
|
||||
//await fetch(replaceRequest)
|
||||
// .then(response => response.json())
|
||||
159
getAndReplacecAsset.ts
Normal file
159
getAndReplacecAsset.ts
Normal file
@@ -0,0 +1,159 @@
|
||||
import fs from "fs"
|
||||
import { basename } from "node:path"
|
||||
|
||||
class UploadFile extends File {
|
||||
constructor(
|
||||
private filepath: string,
|
||||
//private _size: number
|
||||
) {
|
||||
super([], basename(filepath))
|
||||
}
|
||||
|
||||
//get size() {
|
||||
// return this._size
|
||||
//}
|
||||
|
||||
stream() {
|
||||
return fs.createReadStream(this.filepath)
|
||||
}
|
||||
}
|
||||
|
||||
const apiKeySockenklaus = "bxmlNuUlPiY4YRRIcRuJ5eflZCU7aOHQPOgGmts4f8"
|
||||
const apiKeyTestUser = "xOUY572Rd6Fw3qoE3EFBFy3G3sITaIQsgPPc8TAbQ"
|
||||
|
||||
const settings = {
|
||||
apiBaseUrl: "https://immich.sockenklaus.duckdns.org/api/",
|
||||
apiKey: apiKeyTestUser,
|
||||
immichMount: "/immich/"
|
||||
|
||||
}
|
||||
|
||||
const args = {
|
||||
tdarrPath: "/immich/6c0138fb-62c4-4a99-aeed-721a845f90f3/2025/07/SampleVideo_1280x720_10mb.mp4",
|
||||
newFile: "./SampleVideo_1280x720_30mb.mp4"
|
||||
}
|
||||
|
||||
const originalPath = args.tdarrPath.replace(settings.immichMount, "")
|
||||
|
||||
const headers = {
|
||||
"Accept": "application/json",
|
||||
"x-api-key": settings.apiKey
|
||||
}
|
||||
|
||||
async function getAssetByOriginalPath(path) {
|
||||
const searchRequest = new Request(settings.apiBaseUrl + "search/metadata", {
|
||||
method: "POST",
|
||||
body: JSON.stringify({ originalPath: path }),
|
||||
headers: headers
|
||||
})
|
||||
|
||||
try {
|
||||
const responsePromise = await fetch(searchRequest)
|
||||
const responseBody = await responsePromise.json()
|
||||
|
||||
if(responseBody.assets.total !== 1) {
|
||||
console.error(`Found ${body.assets.total} assets, stopping here`)
|
||||
return {}
|
||||
}
|
||||
|
||||
return {
|
||||
id: responseBody.assets.items[0].id,
|
||||
deviceAssetId: responseBody.assets.items[0].deviceAssetId,
|
||||
deviceId: responseBody.assets.items[0].deviceId,
|
||||
fileCreatedAt: responseBody.assets.items[0].fileCreatedAt,
|
||||
fileModifiedAt: responseBody.assets.items[0].fileModifiedAt
|
||||
}
|
||||
}
|
||||
catch(error) {
|
||||
console.error(error)
|
||||
}
|
||||
}
|
||||
|
||||
async function replaceAsset(assetInfo, newFilePath) {
|
||||
const file = new UploadFile(newFilePath)
|
||||
|
||||
const uploadData = new FormData()
|
||||
uploadData.set("assetData", file)
|
||||
uploadData.set("deviceAssetId", assetInfo.deviceAssetId)
|
||||
uploadData.set("deviceId", assetInfo.deviceId)
|
||||
uploadData.set("fileCreatedAt", assetInfo.fileCreatedAt)
|
||||
uploadData.set("fileModifiedAt", assetInfo.fileModifiedAt)
|
||||
|
||||
const replaceRequest = new Request(settings.apiBaseUrl + "assets/"+assetInfo.id+"/original", {
|
||||
method: "PUT",
|
||||
headers: {
|
||||
"Accept": "application/json",
|
||||
"x-api-key": settings.apiKey
|
||||
},
|
||||
body: uploadData
|
||||
})
|
||||
const responsePromise = await fetch(replaceRequest)
|
||||
const responseBody = await responsePromise.json()
|
||||
|
||||
return responseBody
|
||||
}
|
||||
|
||||
const assetInfo = await getAssetByOriginalPath(originalPath)
|
||||
|
||||
console.log(JSON.stringify(assetInfo, undefined, 2))
|
||||
|
||||
console.log(replaceAsset(assetInfo, args.newFile))
|
||||
|
||||
/*
|
||||
fetch(searchRequest)
|
||||
.then(response => {
|
||||
if(!response.ok){
|
||||
throw new Error(`Search failed: ${response.status} - ${response.statusText}`)
|
||||
}
|
||||
return response.json()
|
||||
})
|
||||
.then(body => {
|
||||
console.log(JSON.stringify(body, undefined, 2))
|
||||
|
||||
if (body.assets.total !== 1) {
|
||||
console.log(`Found ${body.assets.total} assets, stopping here`)
|
||||
return Promise.resolve(null)
|
||||
}
|
||||
|
||||
const id = body.assets.items[0].id
|
||||
|
||||
const file = fs.readFileSync(args.newFile)
|
||||
|
||||
const uploadData = new FormData()
|
||||
uploadData.set("assetData", file)
|
||||
uploadData.set("deviceAssetId", body.assets.items[0].deviceAssetId)
|
||||
uploadData.set("deviceId", body.assets.items[0].deviceId)
|
||||
uploadData.set("fileCreatedAt", body.assets.items[0].fileCreatedAt)
|
||||
uploadData.set("fileModifiedAt", body.assets.items[0].fileModifiedAt)
|
||||
|
||||
//console.dir(uploadData.get("assetData"))
|
||||
|
||||
const replaceRequest = new Request(settings.apiBaseUrl + "assets/"+id+"/original", {
|
||||
method: "PUT",
|
||||
headers: {
|
||||
"Accept": "application/json",
|
||||
"x-api-key": settings.apiKey
|
||||
},
|
||||
body: uploadData
|
||||
})
|
||||
|
||||
return fetch(replaceRequest)
|
||||
})
|
||||
.then(putResponse => {
|
||||
if(!putResponse) {
|
||||
throw new Error(`No put request was made`)
|
||||
}
|
||||
if(!putResponse.ok) {
|
||||
throw new Error(`Replace failed: ${putResponse.status} - ${putResponse.statusText}`)
|
||||
}
|
||||
return putResponse.json()
|
||||
})
|
||||
.then(replaceBody => {
|
||||
console.log(JSON.stringify(replaceBody, undefined, 2))
|
||||
})
|
||||
.catch(error => console.log(error))
|
||||
|
||||
|
||||
*/
|
||||
//await fetch(replaceRequest)
|
||||
// .then(response => response.json())
|
||||
12
node_modules/.bin/esbuild
generated
vendored
Normal file
12
node_modules/.bin/esbuild
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*) basedir=`cygpath -w "$basedir"`;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../esbuild/bin/esbuild" "$@"
|
||||
else
|
||||
exec node "$basedir/../esbuild/bin/esbuild" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/esbuild.cmd
generated
vendored
Normal file
17
node_modules/.bin/esbuild.cmd
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\esbuild\bin\esbuild" %*
|
||||
28
node_modules/.bin/esbuild.ps1
generated
vendored
Normal file
28
node_modules/.bin/esbuild.ps1
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../esbuild/bin/esbuild" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
12
node_modules/.bin/tsx
generated
vendored
Normal file
12
node_modules/.bin/tsx
generated
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
|
||||
|
||||
case `uname` in
|
||||
*CYGWIN*|*MINGW*|*MSYS*) basedir=`cygpath -w "$basedir"`;;
|
||||
esac
|
||||
|
||||
if [ -x "$basedir/node" ]; then
|
||||
exec "$basedir/node" "$basedir/../tsx/dist/cli.mjs" "$@"
|
||||
else
|
||||
exec node "$basedir/../tsx/dist/cli.mjs" "$@"
|
||||
fi
|
||||
17
node_modules/.bin/tsx.cmd
generated
vendored
Normal file
17
node_modules/.bin/tsx.cmd
generated
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
@ECHO off
|
||||
GOTO start
|
||||
:find_dp0
|
||||
SET dp0=%~dp0
|
||||
EXIT /b
|
||||
:start
|
||||
SETLOCAL
|
||||
CALL :find_dp0
|
||||
|
||||
IF EXIST "%dp0%\node.exe" (
|
||||
SET "_prog=%dp0%\node.exe"
|
||||
) ELSE (
|
||||
SET "_prog=node"
|
||||
SET PATHEXT=%PATHEXT:;.JS;=;%
|
||||
)
|
||||
|
||||
endLocal & goto #_undefined_# 2>NUL || title %COMSPEC% & "%_prog%" "%dp0%\..\tsx\dist\cli.mjs" %*
|
||||
28
node_modules/.bin/tsx.ps1
generated
vendored
Normal file
28
node_modules/.bin/tsx.ps1
generated
vendored
Normal file
@@ -0,0 +1,28 @@
|
||||
#!/usr/bin/env pwsh
|
||||
$basedir=Split-Path $MyInvocation.MyCommand.Definition -Parent
|
||||
|
||||
$exe=""
|
||||
if ($PSVersionTable.PSVersion -lt "6.0" -or $IsWindows) {
|
||||
# Fix case when both the Windows and Linux builds of Node
|
||||
# are installed in the same directory
|
||||
$exe=".exe"
|
||||
}
|
||||
$ret=0
|
||||
if (Test-Path "$basedir/node$exe") {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "$basedir/node$exe" "$basedir/../tsx/dist/cli.mjs" $args
|
||||
} else {
|
||||
& "$basedir/node$exe" "$basedir/../tsx/dist/cli.mjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
} else {
|
||||
# Support pipeline input
|
||||
if ($MyInvocation.ExpectingInput) {
|
||||
$input | & "node$exe" "$basedir/../tsx/dist/cli.mjs" $args
|
||||
} else {
|
||||
& "node$exe" "$basedir/../tsx/dist/cli.mjs" $args
|
||||
}
|
||||
$ret=$LASTEXITCODE
|
||||
}
|
||||
exit $ret
|
||||
104
node_modules/.package-lock.json
generated
vendored
Normal file
104
node_modules/.package-lock.json
generated
vendored
Normal file
@@ -0,0 +1,104 @@
|
||||
{
|
||||
"name": "immich-api-test",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"node_modules/@esbuild/win32-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-NgJPHHbEpLQgDH2MjQu90pzW/5vvXIZ7KOnPyNBm92A6WgZ/7b6fJyUBjoumLqeOQQGqY2QjQxRo97ah4Sj0cA==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"win32"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/esbuild": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.6.tgz",
|
||||
"integrity": "sha512-GVuzuUwtdsghE3ocJ9Bs8PNoF13HNQ5TXbEi2AhvVb8xU1Iwt9Fos9FEamfoee+u/TOsn7GUWc04lz46n2bbTg==",
|
||||
"dev": true,
|
||||
"hasInstallScript": true,
|
||||
"bin": {
|
||||
"esbuild": "bin/esbuild"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"@esbuild/aix-ppc64": "0.25.6",
|
||||
"@esbuild/android-arm": "0.25.6",
|
||||
"@esbuild/android-arm64": "0.25.6",
|
||||
"@esbuild/android-x64": "0.25.6",
|
||||
"@esbuild/darwin-arm64": "0.25.6",
|
||||
"@esbuild/darwin-x64": "0.25.6",
|
||||
"@esbuild/freebsd-arm64": "0.25.6",
|
||||
"@esbuild/freebsd-x64": "0.25.6",
|
||||
"@esbuild/linux-arm": "0.25.6",
|
||||
"@esbuild/linux-arm64": "0.25.6",
|
||||
"@esbuild/linux-ia32": "0.25.6",
|
||||
"@esbuild/linux-loong64": "0.25.6",
|
||||
"@esbuild/linux-mips64el": "0.25.6",
|
||||
"@esbuild/linux-ppc64": "0.25.6",
|
||||
"@esbuild/linux-riscv64": "0.25.6",
|
||||
"@esbuild/linux-s390x": "0.25.6",
|
||||
"@esbuild/linux-x64": "0.25.6",
|
||||
"@esbuild/netbsd-arm64": "0.25.6",
|
||||
"@esbuild/netbsd-x64": "0.25.6",
|
||||
"@esbuild/openbsd-arm64": "0.25.6",
|
||||
"@esbuild/openbsd-x64": "0.25.6",
|
||||
"@esbuild/openharmony-arm64": "0.25.6",
|
||||
"@esbuild/sunos-x64": "0.25.6",
|
||||
"@esbuild/win32-arm64": "0.25.6",
|
||||
"@esbuild/win32-ia32": "0.25.6",
|
||||
"@esbuild/win32-x64": "0.25.6"
|
||||
}
|
||||
},
|
||||
"node_modules/get-tsconfig": {
|
||||
"version": "4.10.1",
|
||||
"resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.1.tgz",
|
||||
"integrity": "sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"resolve-pkg-maps": "^1.0.0"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/privatenumber/get-tsconfig?sponsor=1"
|
||||
}
|
||||
},
|
||||
"node_modules/resolve-pkg-maps": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz",
|
||||
"integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==",
|
||||
"dev": true,
|
||||
"funding": {
|
||||
"url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1"
|
||||
}
|
||||
},
|
||||
"node_modules/tsx": {
|
||||
"version": "4.20.3",
|
||||
"resolved": "https://registry.npmjs.org/tsx/-/tsx-4.20.3.tgz",
|
||||
"integrity": "sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"esbuild": "~0.25.0",
|
||||
"get-tsconfig": "^4.7.5"
|
||||
},
|
||||
"bin": {
|
||||
"tsx": "dist/cli.mjs"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.0.0"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"fsevents": "~2.3.3"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
3
node_modules/@esbuild/win32-x64/README.md
generated
vendored
Normal file
3
node_modules/@esbuild/win32-x64/README.md
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
# esbuild
|
||||
|
||||
This is the Windows 64-bit binary for esbuild, a JavaScript bundler and minifier. See https://github.com/evanw/esbuild for details.
|
||||
BIN
node_modules/@esbuild/win32-x64/esbuild.exe
generated
vendored
Normal file
BIN
node_modules/@esbuild/win32-x64/esbuild.exe
generated
vendored
Normal file
Binary file not shown.
20
node_modules/@esbuild/win32-x64/package.json
generated
vendored
Normal file
20
node_modules/@esbuild/win32-x64/package.json
generated
vendored
Normal file
@@ -0,0 +1,20 @@
|
||||
{
|
||||
"name": "@esbuild/win32-x64",
|
||||
"version": "0.25.6",
|
||||
"description": "The Windows 64-bit binary for esbuild, a JavaScript bundler.",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/evanw/esbuild.git"
|
||||
},
|
||||
"license": "MIT",
|
||||
"preferUnplugged": true,
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
},
|
||||
"os": [
|
||||
"win32"
|
||||
],
|
||||
"cpu": [
|
||||
"x64"
|
||||
]
|
||||
}
|
||||
21
node_modules/esbuild/LICENSE.md
generated
vendored
Normal file
21
node_modules/esbuild/LICENSE.md
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) 2020 Evan Wallace
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
3
node_modules/esbuild/README.md
generated
vendored
Normal file
3
node_modules/esbuild/README.md
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
# esbuild
|
||||
|
||||
This is a JavaScript bundler and minifier. See https://github.com/evanw/esbuild and the [JavaScript API documentation](https://esbuild.github.io/api/) for details.
|
||||
223
node_modules/esbuild/bin/esbuild
generated
vendored
Normal file
223
node_modules/esbuild/bin/esbuild
generated
vendored
Normal file
@@ -0,0 +1,223 @@
|
||||
#!/usr/bin/env node
|
||||
"use strict";
|
||||
var __create = Object.create;
|
||||
var __defProp = Object.defineProperty;
|
||||
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
||||
var __getOwnPropNames = Object.getOwnPropertyNames;
|
||||
var __getProtoOf = Object.getPrototypeOf;
|
||||
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
||||
var __copyProps = (to, from, except, desc) => {
|
||||
if (from && typeof from === "object" || typeof from === "function") {
|
||||
for (let key of __getOwnPropNames(from))
|
||||
if (!__hasOwnProp.call(to, key) && key !== except)
|
||||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
||||
}
|
||||
return to;
|
||||
};
|
||||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
||||
// If the importer is in node compatibility mode or this is not an ESM
|
||||
// file that has been converted to a CommonJS file using a Babel-
|
||||
// compatible transform (i.e. "__esModule" has not been set), then set
|
||||
// "default" to the CommonJS "module.exports" for node compatibility.
|
||||
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
||||
mod
|
||||
));
|
||||
|
||||
// lib/npm/node-platform.ts
|
||||
var fs = require("fs");
|
||||
var os = require("os");
|
||||
var path = require("path");
|
||||
var ESBUILD_BINARY_PATH = process.env.ESBUILD_BINARY_PATH || ESBUILD_BINARY_PATH;
|
||||
var isValidBinaryPath = (x) => !!x && x !== "/usr/bin/esbuild";
|
||||
var packageDarwin_arm64 = "@esbuild/darwin-arm64";
|
||||
var packageDarwin_x64 = "@esbuild/darwin-x64";
|
||||
var knownWindowsPackages = {
|
||||
"win32 arm64 LE": "@esbuild/win32-arm64",
|
||||
"win32 ia32 LE": "@esbuild/win32-ia32",
|
||||
"win32 x64 LE": "@esbuild/win32-x64"
|
||||
};
|
||||
var knownUnixlikePackages = {
|
||||
"aix ppc64 BE": "@esbuild/aix-ppc64",
|
||||
"android arm64 LE": "@esbuild/android-arm64",
|
||||
"darwin arm64 LE": "@esbuild/darwin-arm64",
|
||||
"darwin x64 LE": "@esbuild/darwin-x64",
|
||||
"freebsd arm64 LE": "@esbuild/freebsd-arm64",
|
||||
"freebsd x64 LE": "@esbuild/freebsd-x64",
|
||||
"linux arm LE": "@esbuild/linux-arm",
|
||||
"linux arm64 LE": "@esbuild/linux-arm64",
|
||||
"linux ia32 LE": "@esbuild/linux-ia32",
|
||||
"linux mips64el LE": "@esbuild/linux-mips64el",
|
||||
"linux ppc64 LE": "@esbuild/linux-ppc64",
|
||||
"linux riscv64 LE": "@esbuild/linux-riscv64",
|
||||
"linux s390x BE": "@esbuild/linux-s390x",
|
||||
"linux x64 LE": "@esbuild/linux-x64",
|
||||
"linux loong64 LE": "@esbuild/linux-loong64",
|
||||
"netbsd arm64 LE": "@esbuild/netbsd-arm64",
|
||||
"netbsd x64 LE": "@esbuild/netbsd-x64",
|
||||
"openbsd arm64 LE": "@esbuild/openbsd-arm64",
|
||||
"openbsd x64 LE": "@esbuild/openbsd-x64",
|
||||
"sunos x64 LE": "@esbuild/sunos-x64"
|
||||
};
|
||||
var knownWebAssemblyFallbackPackages = {
|
||||
"android arm LE": "@esbuild/android-arm",
|
||||
"android x64 LE": "@esbuild/android-x64",
|
||||
"openharmony arm64 LE": "@esbuild/openharmony-arm64"
|
||||
};
|
||||
function pkgAndSubpathForCurrentPlatform() {
|
||||
let pkg;
|
||||
let subpath;
|
||||
let isWASM2 = false;
|
||||
let platformKey = `${process.platform} ${os.arch()} ${os.endianness()}`;
|
||||
if (platformKey in knownWindowsPackages) {
|
||||
pkg = knownWindowsPackages[platformKey];
|
||||
subpath = "esbuild.exe";
|
||||
} else if (platformKey in knownUnixlikePackages) {
|
||||
pkg = knownUnixlikePackages[platformKey];
|
||||
subpath = "bin/esbuild";
|
||||
} else if (platformKey in knownWebAssemblyFallbackPackages) {
|
||||
pkg = knownWebAssemblyFallbackPackages[platformKey];
|
||||
subpath = "bin/esbuild";
|
||||
isWASM2 = true;
|
||||
} else {
|
||||
throw new Error(`Unsupported platform: ${platformKey}`);
|
||||
}
|
||||
return { pkg, subpath, isWASM: isWASM2 };
|
||||
}
|
||||
function pkgForSomeOtherPlatform() {
|
||||
const libMainJS = require.resolve("esbuild");
|
||||
const nodeModulesDirectory = path.dirname(path.dirname(path.dirname(libMainJS)));
|
||||
if (path.basename(nodeModulesDirectory) === "node_modules") {
|
||||
for (const unixKey in knownUnixlikePackages) {
|
||||
try {
|
||||
const pkg = knownUnixlikePackages[unixKey];
|
||||
if (fs.existsSync(path.join(nodeModulesDirectory, pkg))) return pkg;
|
||||
} catch {
|
||||
}
|
||||
}
|
||||
for (const windowsKey in knownWindowsPackages) {
|
||||
try {
|
||||
const pkg = knownWindowsPackages[windowsKey];
|
||||
if (fs.existsSync(path.join(nodeModulesDirectory, pkg))) return pkg;
|
||||
} catch {
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
function downloadedBinPath(pkg, subpath) {
|
||||
const esbuildLibDir = path.dirname(require.resolve("esbuild"));
|
||||
return path.join(esbuildLibDir, `downloaded-${pkg.replace("/", "-")}-${path.basename(subpath)}`);
|
||||
}
|
||||
function generateBinPath() {
|
||||
if (isValidBinaryPath(ESBUILD_BINARY_PATH)) {
|
||||
if (!fs.existsSync(ESBUILD_BINARY_PATH)) {
|
||||
console.warn(`[esbuild] Ignoring bad configuration: ESBUILD_BINARY_PATH=${ESBUILD_BINARY_PATH}`);
|
||||
} else {
|
||||
return { binPath: ESBUILD_BINARY_PATH, isWASM: false };
|
||||
}
|
||||
}
|
||||
const { pkg, subpath, isWASM: isWASM2 } = pkgAndSubpathForCurrentPlatform();
|
||||
let binPath2;
|
||||
try {
|
||||
binPath2 = require.resolve(`${pkg}/${subpath}`);
|
||||
} catch (e) {
|
||||
binPath2 = downloadedBinPath(pkg, subpath);
|
||||
if (!fs.existsSync(binPath2)) {
|
||||
try {
|
||||
require.resolve(pkg);
|
||||
} catch {
|
||||
const otherPkg = pkgForSomeOtherPlatform();
|
||||
if (otherPkg) {
|
||||
let suggestions = `
|
||||
Specifically the "${otherPkg}" package is present but this platform
|
||||
needs the "${pkg}" package instead. People often get into this
|
||||
situation by installing esbuild on Windows or macOS and copying "node_modules"
|
||||
into a Docker image that runs Linux, or by copying "node_modules" between
|
||||
Windows and WSL environments.
|
||||
|
||||
If you are installing with npm, you can try not copying the "node_modules"
|
||||
directory when you copy the files over, and running "npm ci" or "npm install"
|
||||
on the destination platform after the copy. Or you could consider using yarn
|
||||
instead of npm which has built-in support for installing a package on multiple
|
||||
platforms simultaneously.
|
||||
|
||||
If you are installing with yarn, you can try listing both this platform and the
|
||||
other platform in your ".yarnrc.yml" file using the "supportedArchitectures"
|
||||
feature: https://yarnpkg.com/configuration/yarnrc/#supportedArchitectures
|
||||
Keep in mind that this means multiple copies of esbuild will be present.
|
||||
`;
|
||||
if (pkg === packageDarwin_x64 && otherPkg === packageDarwin_arm64 || pkg === packageDarwin_arm64 && otherPkg === packageDarwin_x64) {
|
||||
suggestions = `
|
||||
Specifically the "${otherPkg}" package is present but this platform
|
||||
needs the "${pkg}" package instead. People often get into this
|
||||
situation by installing esbuild with npm running inside of Rosetta 2 and then
|
||||
trying to use it with node running outside of Rosetta 2, or vice versa (Rosetta
|
||||
2 is Apple's on-the-fly x86_64-to-arm64 translation service).
|
||||
|
||||
If you are installing with npm, you can try ensuring that both npm and node are
|
||||
not running under Rosetta 2 and then reinstalling esbuild. This likely involves
|
||||
changing how you installed npm and/or node. For example, installing node with
|
||||
the universal installer here should work: https://nodejs.org/en/download/. Or
|
||||
you could consider using yarn instead of npm which has built-in support for
|
||||
installing a package on multiple platforms simultaneously.
|
||||
|
||||
If you are installing with yarn, you can try listing both "arm64" and "x64"
|
||||
in your ".yarnrc.yml" file using the "supportedArchitectures" feature:
|
||||
https://yarnpkg.com/configuration/yarnrc/#supportedArchitectures
|
||||
Keep in mind that this means multiple copies of esbuild will be present.
|
||||
`;
|
||||
}
|
||||
throw new Error(`
|
||||
You installed esbuild for another platform than the one you're currently using.
|
||||
This won't work because esbuild is written with native code and needs to
|
||||
install a platform-specific binary executable.
|
||||
${suggestions}
|
||||
Another alternative is to use the "esbuild-wasm" package instead, which works
|
||||
the same way on all platforms. But it comes with a heavy performance cost and
|
||||
can sometimes be 10x slower than the "esbuild" package, so you may also not
|
||||
want to do that.
|
||||
`);
|
||||
}
|
||||
throw new Error(`The package "${pkg}" could not be found, and is needed by esbuild.
|
||||
|
||||
If you are installing esbuild with npm, make sure that you don't specify the
|
||||
"--no-optional" or "--omit=optional" flags. The "optionalDependencies" feature
|
||||
of "package.json" is used by esbuild to install the correct binary executable
|
||||
for your current platform.`);
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
if (/\.zip\//.test(binPath2)) {
|
||||
let pnpapi;
|
||||
try {
|
||||
pnpapi = require("pnpapi");
|
||||
} catch (e) {
|
||||
}
|
||||
if (pnpapi) {
|
||||
const root = pnpapi.getPackageInformation(pnpapi.topLevel).packageLocation;
|
||||
const binTargetPath = path.join(
|
||||
root,
|
||||
"node_modules",
|
||||
".cache",
|
||||
"esbuild",
|
||||
`pnpapi-${pkg.replace("/", "-")}-${"0.25.6"}-${path.basename(subpath)}`
|
||||
);
|
||||
if (!fs.existsSync(binTargetPath)) {
|
||||
fs.mkdirSync(path.dirname(binTargetPath), { recursive: true });
|
||||
fs.copyFileSync(binPath2, binTargetPath);
|
||||
fs.chmodSync(binTargetPath, 493);
|
||||
}
|
||||
return { binPath: binTargetPath, isWASM: isWASM2 };
|
||||
}
|
||||
}
|
||||
return { binPath: binPath2, isWASM: isWASM2 };
|
||||
}
|
||||
|
||||
// lib/npm/node-shim.ts
|
||||
var { binPath, isWASM } = generateBinPath();
|
||||
if (isWASM) {
|
||||
require("child_process").execFileSync("node", [binPath].concat(process.argv.slice(2)), { stdio: "inherit" });
|
||||
} else {
|
||||
require("child_process").execFileSync(binPath, process.argv.slice(2), { stdio: "inherit" });
|
||||
}
|
||||
289
node_modules/esbuild/install.js
generated
vendored
Normal file
289
node_modules/esbuild/install.js
generated
vendored
Normal file
@@ -0,0 +1,289 @@
|
||||
"use strict";
|
||||
var __create = Object.create;
|
||||
var __defProp = Object.defineProperty;
|
||||
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
||||
var __getOwnPropNames = Object.getOwnPropertyNames;
|
||||
var __getProtoOf = Object.getPrototypeOf;
|
||||
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
||||
var __copyProps = (to, from, except, desc) => {
|
||||
if (from && typeof from === "object" || typeof from === "function") {
|
||||
for (let key of __getOwnPropNames(from))
|
||||
if (!__hasOwnProp.call(to, key) && key !== except)
|
||||
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
||||
}
|
||||
return to;
|
||||
};
|
||||
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
||||
// If the importer is in node compatibility mode or this is not an ESM
|
||||
// file that has been converted to a CommonJS file using a Babel-
|
||||
// compatible transform (i.e. "__esModule" has not been set), then set
|
||||
// "default" to the CommonJS "module.exports" for node compatibility.
|
||||
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
||||
mod
|
||||
));
|
||||
|
||||
// lib/npm/node-platform.ts
|
||||
var fs = require("fs");
|
||||
var os = require("os");
|
||||
var path = require("path");
|
||||
var ESBUILD_BINARY_PATH = process.env.ESBUILD_BINARY_PATH || ESBUILD_BINARY_PATH;
|
||||
var isValidBinaryPath = (x) => !!x && x !== "/usr/bin/esbuild";
|
||||
var knownWindowsPackages = {
|
||||
"win32 arm64 LE": "@esbuild/win32-arm64",
|
||||
"win32 ia32 LE": "@esbuild/win32-ia32",
|
||||
"win32 x64 LE": "@esbuild/win32-x64"
|
||||
};
|
||||
var knownUnixlikePackages = {
|
||||
"aix ppc64 BE": "@esbuild/aix-ppc64",
|
||||
"android arm64 LE": "@esbuild/android-arm64",
|
||||
"darwin arm64 LE": "@esbuild/darwin-arm64",
|
||||
"darwin x64 LE": "@esbuild/darwin-x64",
|
||||
"freebsd arm64 LE": "@esbuild/freebsd-arm64",
|
||||
"freebsd x64 LE": "@esbuild/freebsd-x64",
|
||||
"linux arm LE": "@esbuild/linux-arm",
|
||||
"linux arm64 LE": "@esbuild/linux-arm64",
|
||||
"linux ia32 LE": "@esbuild/linux-ia32",
|
||||
"linux mips64el LE": "@esbuild/linux-mips64el",
|
||||
"linux ppc64 LE": "@esbuild/linux-ppc64",
|
||||
"linux riscv64 LE": "@esbuild/linux-riscv64",
|
||||
"linux s390x BE": "@esbuild/linux-s390x",
|
||||
"linux x64 LE": "@esbuild/linux-x64",
|
||||
"linux loong64 LE": "@esbuild/linux-loong64",
|
||||
"netbsd arm64 LE": "@esbuild/netbsd-arm64",
|
||||
"netbsd x64 LE": "@esbuild/netbsd-x64",
|
||||
"openbsd arm64 LE": "@esbuild/openbsd-arm64",
|
||||
"openbsd x64 LE": "@esbuild/openbsd-x64",
|
||||
"sunos x64 LE": "@esbuild/sunos-x64"
|
||||
};
|
||||
var knownWebAssemblyFallbackPackages = {
|
||||
"android arm LE": "@esbuild/android-arm",
|
||||
"android x64 LE": "@esbuild/android-x64",
|
||||
"openharmony arm64 LE": "@esbuild/openharmony-arm64"
|
||||
};
|
||||
function pkgAndSubpathForCurrentPlatform() {
|
||||
let pkg;
|
||||
let subpath;
|
||||
let isWASM = false;
|
||||
let platformKey = `${process.platform} ${os.arch()} ${os.endianness()}`;
|
||||
if (platformKey in knownWindowsPackages) {
|
||||
pkg = knownWindowsPackages[platformKey];
|
||||
subpath = "esbuild.exe";
|
||||
} else if (platformKey in knownUnixlikePackages) {
|
||||
pkg = knownUnixlikePackages[platformKey];
|
||||
subpath = "bin/esbuild";
|
||||
} else if (platformKey in knownWebAssemblyFallbackPackages) {
|
||||
pkg = knownWebAssemblyFallbackPackages[platformKey];
|
||||
subpath = "bin/esbuild";
|
||||
isWASM = true;
|
||||
} else {
|
||||
throw new Error(`Unsupported platform: ${platformKey}`);
|
||||
}
|
||||
return { pkg, subpath, isWASM };
|
||||
}
|
||||
function downloadedBinPath(pkg, subpath) {
|
||||
const esbuildLibDir = path.dirname(require.resolve("esbuild"));
|
||||
return path.join(esbuildLibDir, `downloaded-${pkg.replace("/", "-")}-${path.basename(subpath)}`);
|
||||
}
|
||||
|
||||
// lib/npm/node-install.ts
|
||||
var fs2 = require("fs");
|
||||
var os2 = require("os");
|
||||
var path2 = require("path");
|
||||
var zlib = require("zlib");
|
||||
var https = require("https");
|
||||
var child_process = require("child_process");
|
||||
var versionFromPackageJSON = require(path2.join(__dirname, "package.json")).version;
|
||||
var toPath = path2.join(__dirname, "bin", "esbuild");
|
||||
var isToPathJS = true;
|
||||
function validateBinaryVersion(...command) {
|
||||
command.push("--version");
|
||||
let stdout;
|
||||
try {
|
||||
stdout = child_process.execFileSync(command.shift(), command, {
|
||||
// Without this, this install script strangely crashes with the error
|
||||
// "EACCES: permission denied, write" but only on Ubuntu Linux when node is
|
||||
// installed from the Snap Store. This is not a problem when you download
|
||||
// the official version of node. The problem appears to be that stderr
|
||||
// (i.e. file descriptor 2) isn't writable?
|
||||
//
|
||||
// More info:
|
||||
// - https://snapcraft.io/ (what the Snap Store is)
|
||||
// - https://nodejs.org/dist/ (download the official version of node)
|
||||
// - https://github.com/evanw/esbuild/issues/1711#issuecomment-1027554035
|
||||
//
|
||||
stdio: "pipe"
|
||||
}).toString().trim();
|
||||
} catch (err) {
|
||||
if (os2.platform() === "darwin" && /_SecTrustEvaluateWithError/.test(err + "")) {
|
||||
let os3 = "this version of macOS";
|
||||
try {
|
||||
os3 = "macOS " + child_process.execFileSync("sw_vers", ["-productVersion"]).toString().trim();
|
||||
} catch {
|
||||
}
|
||||
throw new Error(`The "esbuild" package cannot be installed because ${os3} is too outdated.
|
||||
|
||||
The Go compiler (which esbuild relies on) no longer supports ${os3},
|
||||
which means the "esbuild" binary executable can't be run. You can either:
|
||||
|
||||
* Update your version of macOS to one that the Go compiler supports
|
||||
* Use the "esbuild-wasm" package instead of the "esbuild" package
|
||||
* Build esbuild yourself using an older version of the Go compiler
|
||||
`);
|
||||
}
|
||||
throw err;
|
||||
}
|
||||
if (stdout !== versionFromPackageJSON) {
|
||||
throw new Error(`Expected ${JSON.stringify(versionFromPackageJSON)} but got ${JSON.stringify(stdout)}`);
|
||||
}
|
||||
}
|
||||
function isYarn() {
|
||||
const { npm_config_user_agent } = process.env;
|
||||
if (npm_config_user_agent) {
|
||||
return /\byarn\//.test(npm_config_user_agent);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
function fetch(url) {
|
||||
return new Promise((resolve, reject) => {
|
||||
https.get(url, (res) => {
|
||||
if ((res.statusCode === 301 || res.statusCode === 302) && res.headers.location)
|
||||
return fetch(res.headers.location).then(resolve, reject);
|
||||
if (res.statusCode !== 200)
|
||||
return reject(new Error(`Server responded with ${res.statusCode}`));
|
||||
let chunks = [];
|
||||
res.on("data", (chunk) => chunks.push(chunk));
|
||||
res.on("end", () => resolve(Buffer.concat(chunks)));
|
||||
}).on("error", reject);
|
||||
});
|
||||
}
|
||||
function extractFileFromTarGzip(buffer, subpath) {
|
||||
try {
|
||||
buffer = zlib.unzipSync(buffer);
|
||||
} catch (err) {
|
||||
throw new Error(`Invalid gzip data in archive: ${err && err.message || err}`);
|
||||
}
|
||||
let str = (i, n) => String.fromCharCode(...buffer.subarray(i, i + n)).replace(/\0.*$/, "");
|
||||
let offset = 0;
|
||||
subpath = `package/${subpath}`;
|
||||
while (offset < buffer.length) {
|
||||
let name = str(offset, 100);
|
||||
let size = parseInt(str(offset + 124, 12), 8);
|
||||
offset += 512;
|
||||
if (!isNaN(size)) {
|
||||
if (name === subpath) return buffer.subarray(offset, offset + size);
|
||||
offset += size + 511 & ~511;
|
||||
}
|
||||
}
|
||||
throw new Error(`Could not find ${JSON.stringify(subpath)} in archive`);
|
||||
}
|
||||
function installUsingNPM(pkg, subpath, binPath) {
|
||||
const env = { ...process.env, npm_config_global: void 0 };
|
||||
const esbuildLibDir = path2.dirname(require.resolve("esbuild"));
|
||||
const installDir = path2.join(esbuildLibDir, "npm-install");
|
||||
fs2.mkdirSync(installDir);
|
||||
try {
|
||||
fs2.writeFileSync(path2.join(installDir, "package.json"), "{}");
|
||||
child_process.execSync(
|
||||
`npm install --loglevel=error --prefer-offline --no-audit --progress=false ${pkg}@${versionFromPackageJSON}`,
|
||||
{ cwd: installDir, stdio: "pipe", env }
|
||||
);
|
||||
const installedBinPath = path2.join(installDir, "node_modules", pkg, subpath);
|
||||
fs2.renameSync(installedBinPath, binPath);
|
||||
} finally {
|
||||
try {
|
||||
removeRecursive(installDir);
|
||||
} catch {
|
||||
}
|
||||
}
|
||||
}
|
||||
function removeRecursive(dir) {
|
||||
for (const entry of fs2.readdirSync(dir)) {
|
||||
const entryPath = path2.join(dir, entry);
|
||||
let stats;
|
||||
try {
|
||||
stats = fs2.lstatSync(entryPath);
|
||||
} catch {
|
||||
continue;
|
||||
}
|
||||
if (stats.isDirectory()) removeRecursive(entryPath);
|
||||
else fs2.unlinkSync(entryPath);
|
||||
}
|
||||
fs2.rmdirSync(dir);
|
||||
}
|
||||
function applyManualBinaryPathOverride(overridePath) {
|
||||
const pathString = JSON.stringify(overridePath);
|
||||
fs2.writeFileSync(toPath, `#!/usr/bin/env node
|
||||
require('child_process').execFileSync(${pathString}, process.argv.slice(2), { stdio: 'inherit' });
|
||||
`);
|
||||
const libMain = path2.join(__dirname, "lib", "main.js");
|
||||
const code = fs2.readFileSync(libMain, "utf8");
|
||||
fs2.writeFileSync(libMain, `var ESBUILD_BINARY_PATH = ${pathString};
|
||||
${code}`);
|
||||
}
|
||||
function maybeOptimizePackage(binPath) {
|
||||
const { isWASM } = pkgAndSubpathForCurrentPlatform();
|
||||
if (os2.platform() !== "win32" && !isYarn() && !isWASM) {
|
||||
const tempPath = path2.join(__dirname, "bin-esbuild");
|
||||
try {
|
||||
fs2.linkSync(binPath, tempPath);
|
||||
fs2.renameSync(tempPath, toPath);
|
||||
isToPathJS = false;
|
||||
fs2.unlinkSync(tempPath);
|
||||
} catch {
|
||||
}
|
||||
}
|
||||
}
|
||||
async function downloadDirectlyFromNPM(pkg, subpath, binPath) {
|
||||
const url = `https://registry.npmjs.org/${pkg}/-/${pkg.replace("@esbuild/", "")}-${versionFromPackageJSON}.tgz`;
|
||||
console.error(`[esbuild] Trying to download ${JSON.stringify(url)}`);
|
||||
try {
|
||||
fs2.writeFileSync(binPath, extractFileFromTarGzip(await fetch(url), subpath));
|
||||
fs2.chmodSync(binPath, 493);
|
||||
} catch (e) {
|
||||
console.error(`[esbuild] Failed to download ${JSON.stringify(url)}: ${e && e.message || e}`);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
async function checkAndPreparePackage() {
|
||||
if (isValidBinaryPath(ESBUILD_BINARY_PATH)) {
|
||||
if (!fs2.existsSync(ESBUILD_BINARY_PATH)) {
|
||||
console.warn(`[esbuild] Ignoring bad configuration: ESBUILD_BINARY_PATH=${ESBUILD_BINARY_PATH}`);
|
||||
} else {
|
||||
applyManualBinaryPathOverride(ESBUILD_BINARY_PATH);
|
||||
return;
|
||||
}
|
||||
}
|
||||
const { pkg, subpath } = pkgAndSubpathForCurrentPlatform();
|
||||
let binPath;
|
||||
try {
|
||||
binPath = require.resolve(`${pkg}/${subpath}`);
|
||||
} catch (e) {
|
||||
console.error(`[esbuild] Failed to find package "${pkg}" on the file system
|
||||
|
||||
This can happen if you use the "--no-optional" flag. The "optionalDependencies"
|
||||
package.json feature is used by esbuild to install the correct binary executable
|
||||
for your current platform. This install script will now attempt to work around
|
||||
this. If that fails, you need to remove the "--no-optional" flag to use esbuild.
|
||||
`);
|
||||
binPath = downloadedBinPath(pkg, subpath);
|
||||
try {
|
||||
console.error(`[esbuild] Trying to install package "${pkg}" using npm`);
|
||||
installUsingNPM(pkg, subpath, binPath);
|
||||
} catch (e2) {
|
||||
console.error(`[esbuild] Failed to install package "${pkg}" using npm: ${e2 && e2.message || e2}`);
|
||||
try {
|
||||
await downloadDirectlyFromNPM(pkg, subpath, binPath);
|
||||
} catch (e3) {
|
||||
throw new Error(`Failed to install package "${pkg}"`);
|
||||
}
|
||||
}
|
||||
}
|
||||
maybeOptimizePackage(binPath);
|
||||
}
|
||||
checkAndPreparePackage().then(() => {
|
||||
if (isToPathJS) {
|
||||
validateBinaryVersion(process.execPath, toPath);
|
||||
} else {
|
||||
validateBinaryVersion(toPath);
|
||||
}
|
||||
});
|
||||
713
node_modules/esbuild/lib/main.d.ts
generated
vendored
Normal file
713
node_modules/esbuild/lib/main.d.ts
generated
vendored
Normal file
@@ -0,0 +1,713 @@
|
||||
export type Platform = 'browser' | 'node' | 'neutral'
|
||||
export type Format = 'iife' | 'cjs' | 'esm'
|
||||
export type Loader = 'base64' | 'binary' | 'copy' | 'css' | 'dataurl' | 'default' | 'empty' | 'file' | 'js' | 'json' | 'jsx' | 'local-css' | 'text' | 'ts' | 'tsx'
|
||||
export type LogLevel = 'verbose' | 'debug' | 'info' | 'warning' | 'error' | 'silent'
|
||||
export type Charset = 'ascii' | 'utf8'
|
||||
export type Drop = 'console' | 'debugger'
|
||||
|
||||
interface CommonOptions {
|
||||
/** Documentation: https://esbuild.github.io/api/#sourcemap */
|
||||
sourcemap?: boolean | 'linked' | 'inline' | 'external' | 'both'
|
||||
/** Documentation: https://esbuild.github.io/api/#legal-comments */
|
||||
legalComments?: 'none' | 'inline' | 'eof' | 'linked' | 'external'
|
||||
/** Documentation: https://esbuild.github.io/api/#source-root */
|
||||
sourceRoot?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#sources-content */
|
||||
sourcesContent?: boolean
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#format */
|
||||
format?: Format
|
||||
/** Documentation: https://esbuild.github.io/api/#global-name */
|
||||
globalName?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#target */
|
||||
target?: string | string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#supported */
|
||||
supported?: Record<string, boolean>
|
||||
/** Documentation: https://esbuild.github.io/api/#platform */
|
||||
platform?: Platform
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#mangle-props */
|
||||
mangleProps?: RegExp
|
||||
/** Documentation: https://esbuild.github.io/api/#mangle-props */
|
||||
reserveProps?: RegExp
|
||||
/** Documentation: https://esbuild.github.io/api/#mangle-props */
|
||||
mangleQuoted?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#mangle-props */
|
||||
mangleCache?: Record<string, string | false>
|
||||
/** Documentation: https://esbuild.github.io/api/#drop */
|
||||
drop?: Drop[]
|
||||
/** Documentation: https://esbuild.github.io/api/#drop-labels */
|
||||
dropLabels?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#minify */
|
||||
minify?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#minify */
|
||||
minifyWhitespace?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#minify */
|
||||
minifyIdentifiers?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#minify */
|
||||
minifySyntax?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#line-limit */
|
||||
lineLimit?: number
|
||||
/** Documentation: https://esbuild.github.io/api/#charset */
|
||||
charset?: Charset
|
||||
/** Documentation: https://esbuild.github.io/api/#tree-shaking */
|
||||
treeShaking?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#ignore-annotations */
|
||||
ignoreAnnotations?: boolean
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx */
|
||||
jsx?: 'transform' | 'preserve' | 'automatic'
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx-factory */
|
||||
jsxFactory?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx-fragment */
|
||||
jsxFragment?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx-import-source */
|
||||
jsxImportSource?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx-development */
|
||||
jsxDev?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#jsx-side-effects */
|
||||
jsxSideEffects?: boolean
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#define */
|
||||
define?: { [key: string]: string }
|
||||
/** Documentation: https://esbuild.github.io/api/#pure */
|
||||
pure?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#keep-names */
|
||||
keepNames?: boolean
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#color */
|
||||
color?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#log-level */
|
||||
logLevel?: LogLevel
|
||||
/** Documentation: https://esbuild.github.io/api/#log-limit */
|
||||
logLimit?: number
|
||||
/** Documentation: https://esbuild.github.io/api/#log-override */
|
||||
logOverride?: Record<string, LogLevel>
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#tsconfig-raw */
|
||||
tsconfigRaw?: string | TsconfigRaw
|
||||
}
|
||||
|
||||
export interface TsconfigRaw {
|
||||
compilerOptions?: {
|
||||
alwaysStrict?: boolean
|
||||
baseUrl?: string
|
||||
experimentalDecorators?: boolean
|
||||
importsNotUsedAsValues?: 'remove' | 'preserve' | 'error'
|
||||
jsx?: 'preserve' | 'react-native' | 'react' | 'react-jsx' | 'react-jsxdev'
|
||||
jsxFactory?: string
|
||||
jsxFragmentFactory?: string
|
||||
jsxImportSource?: string
|
||||
paths?: Record<string, string[]>
|
||||
preserveValueImports?: boolean
|
||||
strict?: boolean
|
||||
target?: string
|
||||
useDefineForClassFields?: boolean
|
||||
verbatimModuleSyntax?: boolean
|
||||
}
|
||||
}
|
||||
|
||||
export interface BuildOptions extends CommonOptions {
|
||||
/** Documentation: https://esbuild.github.io/api/#bundle */
|
||||
bundle?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#splitting */
|
||||
splitting?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#preserve-symlinks */
|
||||
preserveSymlinks?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#outfile */
|
||||
outfile?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#metafile */
|
||||
metafile?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#outdir */
|
||||
outdir?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#outbase */
|
||||
outbase?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#external */
|
||||
external?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#packages */
|
||||
packages?: 'bundle' | 'external'
|
||||
/** Documentation: https://esbuild.github.io/api/#alias */
|
||||
alias?: Record<string, string>
|
||||
/** Documentation: https://esbuild.github.io/api/#loader */
|
||||
loader?: { [ext: string]: Loader }
|
||||
/** Documentation: https://esbuild.github.io/api/#resolve-extensions */
|
||||
resolveExtensions?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#main-fields */
|
||||
mainFields?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#conditions */
|
||||
conditions?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#write */
|
||||
write?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#allow-overwrite */
|
||||
allowOverwrite?: boolean
|
||||
/** Documentation: https://esbuild.github.io/api/#tsconfig */
|
||||
tsconfig?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#out-extension */
|
||||
outExtension?: { [ext: string]: string }
|
||||
/** Documentation: https://esbuild.github.io/api/#public-path */
|
||||
publicPath?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#entry-names */
|
||||
entryNames?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#chunk-names */
|
||||
chunkNames?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#asset-names */
|
||||
assetNames?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#inject */
|
||||
inject?: string[]
|
||||
/** Documentation: https://esbuild.github.io/api/#banner */
|
||||
banner?: { [type: string]: string }
|
||||
/** Documentation: https://esbuild.github.io/api/#footer */
|
||||
footer?: { [type: string]: string }
|
||||
/** Documentation: https://esbuild.github.io/api/#entry-points */
|
||||
entryPoints?: (string | { in: string, out: string })[] | Record<string, string>
|
||||
/** Documentation: https://esbuild.github.io/api/#stdin */
|
||||
stdin?: StdinOptions
|
||||
/** Documentation: https://esbuild.github.io/plugins/ */
|
||||
plugins?: Plugin[]
|
||||
/** Documentation: https://esbuild.github.io/api/#working-directory */
|
||||
absWorkingDir?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#node-paths */
|
||||
nodePaths?: string[]; // The "NODE_PATH" variable from Node.js
|
||||
}
|
||||
|
||||
export interface StdinOptions {
|
||||
contents: string | Uint8Array
|
||||
resolveDir?: string
|
||||
sourcefile?: string
|
||||
loader?: Loader
|
||||
}
|
||||
|
||||
export interface Message {
|
||||
id: string
|
||||
pluginName: string
|
||||
text: string
|
||||
location: Location | null
|
||||
notes: Note[]
|
||||
|
||||
/**
|
||||
* Optional user-specified data that is passed through unmodified. You can
|
||||
* use this to stash the original error, for example.
|
||||
*/
|
||||
detail: any
|
||||
}
|
||||
|
||||
export interface Note {
|
||||
text: string
|
||||
location: Location | null
|
||||
}
|
||||
|
||||
export interface Location {
|
||||
file: string
|
||||
namespace: string
|
||||
/** 1-based */
|
||||
line: number
|
||||
/** 0-based, in bytes */
|
||||
column: number
|
||||
/** in bytes */
|
||||
length: number
|
||||
lineText: string
|
||||
suggestion: string
|
||||
}
|
||||
|
||||
export interface OutputFile {
|
||||
path: string
|
||||
contents: Uint8Array
|
||||
hash: string
|
||||
/** "contents" as text (changes automatically with "contents") */
|
||||
readonly text: string
|
||||
}
|
||||
|
||||
export interface BuildResult<ProvidedOptions extends BuildOptions = BuildOptions> {
|
||||
errors: Message[]
|
||||
warnings: Message[]
|
||||
/** Only when "write: false" */
|
||||
outputFiles: OutputFile[] | (ProvidedOptions['write'] extends false ? never : undefined)
|
||||
/** Only when "metafile: true" */
|
||||
metafile: Metafile | (ProvidedOptions['metafile'] extends true ? never : undefined)
|
||||
/** Only when "mangleCache" is present */
|
||||
mangleCache: Record<string, string | false> | (ProvidedOptions['mangleCache'] extends Object ? never : undefined)
|
||||
}
|
||||
|
||||
export interface BuildFailure extends Error {
|
||||
errors: Message[]
|
||||
warnings: Message[]
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#serve-arguments */
|
||||
export interface ServeOptions {
|
||||
port?: number
|
||||
host?: string
|
||||
servedir?: string
|
||||
keyfile?: string
|
||||
certfile?: string
|
||||
fallback?: string
|
||||
cors?: CORSOptions
|
||||
onRequest?: (args: ServeOnRequestArgs) => void
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#cors */
|
||||
export interface CORSOptions {
|
||||
origin?: string | string[]
|
||||
}
|
||||
|
||||
export interface ServeOnRequestArgs {
|
||||
remoteAddress: string
|
||||
method: string
|
||||
path: string
|
||||
status: number
|
||||
/** The time to generate the response, not to send it */
|
||||
timeInMS: number
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#serve-return-values */
|
||||
export interface ServeResult {
|
||||
port: number
|
||||
hosts: string[]
|
||||
}
|
||||
|
||||
export interface TransformOptions extends CommonOptions {
|
||||
/** Documentation: https://esbuild.github.io/api/#sourcefile */
|
||||
sourcefile?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#loader */
|
||||
loader?: Loader
|
||||
/** Documentation: https://esbuild.github.io/api/#banner */
|
||||
banner?: string
|
||||
/** Documentation: https://esbuild.github.io/api/#footer */
|
||||
footer?: string
|
||||
}
|
||||
|
||||
export interface TransformResult<ProvidedOptions extends TransformOptions = TransformOptions> {
|
||||
code: string
|
||||
map: string
|
||||
warnings: Message[]
|
||||
/** Only when "mangleCache" is present */
|
||||
mangleCache: Record<string, string | false> | (ProvidedOptions['mangleCache'] extends Object ? never : undefined)
|
||||
/** Only when "legalComments" is "external" */
|
||||
legalComments: string | (ProvidedOptions['legalComments'] extends 'external' ? never : undefined)
|
||||
}
|
||||
|
||||
export interface TransformFailure extends Error {
|
||||
errors: Message[]
|
||||
warnings: Message[]
|
||||
}
|
||||
|
||||
export interface Plugin {
|
||||
name: string
|
||||
setup: (build: PluginBuild) => (void | Promise<void>)
|
||||
}
|
||||
|
||||
export interface PluginBuild {
|
||||
/** Documentation: https://esbuild.github.io/plugins/#build-options */
|
||||
initialOptions: BuildOptions
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#resolve */
|
||||
resolve(path: string, options?: ResolveOptions): Promise<ResolveResult>
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-start */
|
||||
onStart(callback: () =>
|
||||
(OnStartResult | null | void | Promise<OnStartResult | null | void>)): void
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-end */
|
||||
onEnd(callback: (result: BuildResult) =>
|
||||
(OnEndResult | null | void | Promise<OnEndResult | null | void>)): void
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-resolve */
|
||||
onResolve(options: OnResolveOptions, callback: (args: OnResolveArgs) =>
|
||||
(OnResolveResult | null | undefined | Promise<OnResolveResult | null | undefined>)): void
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-load */
|
||||
onLoad(options: OnLoadOptions, callback: (args: OnLoadArgs) =>
|
||||
(OnLoadResult | null | undefined | Promise<OnLoadResult | null | undefined>)): void
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-dispose */
|
||||
onDispose(callback: () => void): void
|
||||
|
||||
// This is a full copy of the esbuild library in case you need it
|
||||
esbuild: {
|
||||
context: typeof context,
|
||||
build: typeof build,
|
||||
buildSync: typeof buildSync,
|
||||
transform: typeof transform,
|
||||
transformSync: typeof transformSync,
|
||||
formatMessages: typeof formatMessages,
|
||||
formatMessagesSync: typeof formatMessagesSync,
|
||||
analyzeMetafile: typeof analyzeMetafile,
|
||||
analyzeMetafileSync: typeof analyzeMetafileSync,
|
||||
initialize: typeof initialize,
|
||||
version: typeof version,
|
||||
}
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#resolve-options */
|
||||
export interface ResolveOptions {
|
||||
pluginName?: string
|
||||
importer?: string
|
||||
namespace?: string
|
||||
resolveDir?: string
|
||||
kind?: ImportKind
|
||||
pluginData?: any
|
||||
with?: Record<string, string>
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#resolve-results */
|
||||
export interface ResolveResult {
|
||||
errors: Message[]
|
||||
warnings: Message[]
|
||||
|
||||
path: string
|
||||
external: boolean
|
||||
sideEffects: boolean
|
||||
namespace: string
|
||||
suffix: string
|
||||
pluginData: any
|
||||
}
|
||||
|
||||
export interface OnStartResult {
|
||||
errors?: PartialMessage[]
|
||||
warnings?: PartialMessage[]
|
||||
}
|
||||
|
||||
export interface OnEndResult {
|
||||
errors?: PartialMessage[]
|
||||
warnings?: PartialMessage[]
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-resolve-options */
|
||||
export interface OnResolveOptions {
|
||||
filter: RegExp
|
||||
namespace?: string
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-resolve-arguments */
|
||||
export interface OnResolveArgs {
|
||||
path: string
|
||||
importer: string
|
||||
namespace: string
|
||||
resolveDir: string
|
||||
kind: ImportKind
|
||||
pluginData: any
|
||||
with: Record<string, string>
|
||||
}
|
||||
|
||||
export type ImportKind =
|
||||
| 'entry-point'
|
||||
|
||||
// JS
|
||||
| 'import-statement'
|
||||
| 'require-call'
|
||||
| 'dynamic-import'
|
||||
| 'require-resolve'
|
||||
|
||||
// CSS
|
||||
| 'import-rule'
|
||||
| 'composes-from'
|
||||
| 'url-token'
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-resolve-results */
|
||||
export interface OnResolveResult {
|
||||
pluginName?: string
|
||||
|
||||
errors?: PartialMessage[]
|
||||
warnings?: PartialMessage[]
|
||||
|
||||
path?: string
|
||||
external?: boolean
|
||||
sideEffects?: boolean
|
||||
namespace?: string
|
||||
suffix?: string
|
||||
pluginData?: any
|
||||
|
||||
watchFiles?: string[]
|
||||
watchDirs?: string[]
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-load-options */
|
||||
export interface OnLoadOptions {
|
||||
filter: RegExp
|
||||
namespace?: string
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-load-arguments */
|
||||
export interface OnLoadArgs {
|
||||
path: string
|
||||
namespace: string
|
||||
suffix: string
|
||||
pluginData: any
|
||||
with: Record<string, string>
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/plugins/#on-load-results */
|
||||
export interface OnLoadResult {
|
||||
pluginName?: string
|
||||
|
||||
errors?: PartialMessage[]
|
||||
warnings?: PartialMessage[]
|
||||
|
||||
contents?: string | Uint8Array
|
||||
resolveDir?: string
|
||||
loader?: Loader
|
||||
pluginData?: any
|
||||
|
||||
watchFiles?: string[]
|
||||
watchDirs?: string[]
|
||||
}
|
||||
|
||||
export interface PartialMessage {
|
||||
id?: string
|
||||
pluginName?: string
|
||||
text?: string
|
||||
location?: Partial<Location> | null
|
||||
notes?: PartialNote[]
|
||||
detail?: any
|
||||
}
|
||||
|
||||
export interface PartialNote {
|
||||
text?: string
|
||||
location?: Partial<Location> | null
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#metafile */
|
||||
export interface Metafile {
|
||||
inputs: {
|
||||
[path: string]: {
|
||||
bytes: number
|
||||
imports: {
|
||||
path: string
|
||||
kind: ImportKind
|
||||
external?: boolean
|
||||
original?: string
|
||||
with?: Record<string, string>
|
||||
}[]
|
||||
format?: 'cjs' | 'esm'
|
||||
with?: Record<string, string>
|
||||
}
|
||||
}
|
||||
outputs: {
|
||||
[path: string]: {
|
||||
bytes: number
|
||||
inputs: {
|
||||
[path: string]: {
|
||||
bytesInOutput: number
|
||||
}
|
||||
}
|
||||
imports: {
|
||||
path: string
|
||||
kind: ImportKind | 'file-loader'
|
||||
external?: boolean
|
||||
}[]
|
||||
exports: string[]
|
||||
entryPoint?: string
|
||||
cssBundle?: string
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export interface FormatMessagesOptions {
|
||||
kind: 'error' | 'warning'
|
||||
color?: boolean
|
||||
terminalWidth?: number
|
||||
}
|
||||
|
||||
export interface AnalyzeMetafileOptions {
|
||||
color?: boolean
|
||||
verbose?: boolean
|
||||
}
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#watch-arguments */
|
||||
export interface WatchOptions {
|
||||
delay?: number // In milliseconds
|
||||
}
|
||||
|
||||
export interface BuildContext<ProvidedOptions extends BuildOptions = BuildOptions> {
|
||||
/** Documentation: https://esbuild.github.io/api/#rebuild */
|
||||
rebuild(): Promise<BuildResult<ProvidedOptions>>
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#watch */
|
||||
watch(options?: WatchOptions): Promise<void>
|
||||
|
||||
/** Documentation: https://esbuild.github.io/api/#serve */
|
||||
serve(options?: ServeOptions): Promise<ServeResult>
|
||||
|
||||
cancel(): Promise<void>
|
||||
dispose(): Promise<void>
|
||||
}
|
||||
|
||||
// This is a TypeScript type-level function which replaces any keys in "In"
|
||||
// that aren't in "Out" with "never". We use this to reject properties with
|
||||
// typos in object literals. See: https://stackoverflow.com/questions/49580725
|
||||
type SameShape<Out, In extends Out> = In & { [Key in Exclude<keyof In, keyof Out>]: never }
|
||||
|
||||
/**
|
||||
* This function invokes the "esbuild" command-line tool for you. It returns a
|
||||
* promise that either resolves with a "BuildResult" object or rejects with a
|
||||
* "BuildFailure" object.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: yes
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#build
|
||||
*/
|
||||
export declare function build<T extends BuildOptions>(options: SameShape<BuildOptions, T>): Promise<BuildResult<T>>
|
||||
|
||||
/**
|
||||
* This is the advanced long-running form of "build" that supports additional
|
||||
* features such as watch mode and a local development server.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: no
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#build
|
||||
*/
|
||||
export declare function context<T extends BuildOptions>(options: SameShape<BuildOptions, T>): Promise<BuildContext<T>>
|
||||
|
||||
/**
|
||||
* This function transforms a single JavaScript file. It can be used to minify
|
||||
* JavaScript, convert TypeScript/JSX to JavaScript, or convert newer JavaScript
|
||||
* to older JavaScript. It returns a promise that is either resolved with a
|
||||
* "TransformResult" object or rejected with a "TransformFailure" object.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: yes
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#transform
|
||||
*/
|
||||
export declare function transform<T extends TransformOptions>(input: string | Uint8Array, options?: SameShape<TransformOptions, T>): Promise<TransformResult<T>>
|
||||
|
||||
/**
|
||||
* Converts log messages to formatted message strings suitable for printing in
|
||||
* the terminal. This allows you to reuse the built-in behavior of esbuild's
|
||||
* log message formatter. This is a batch-oriented API for efficiency.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: yes
|
||||
*/
|
||||
export declare function formatMessages(messages: PartialMessage[], options: FormatMessagesOptions): Promise<string[]>
|
||||
|
||||
/**
|
||||
* Pretty-prints an analysis of the metafile JSON to a string. This is just for
|
||||
* convenience to be able to match esbuild's pretty-printing exactly. If you want
|
||||
* to customize it, you can just inspect the data in the metafile yourself.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: yes
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#analyze
|
||||
*/
|
||||
export declare function analyzeMetafile(metafile: Metafile | string, options?: AnalyzeMetafileOptions): Promise<string>
|
||||
|
||||
/**
|
||||
* A synchronous version of "build".
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: no
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#build
|
||||
*/
|
||||
export declare function buildSync<T extends BuildOptions>(options: SameShape<BuildOptions, T>): BuildResult<T>
|
||||
|
||||
/**
|
||||
* A synchronous version of "transform".
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: no
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#transform
|
||||
*/
|
||||
export declare function transformSync<T extends TransformOptions>(input: string | Uint8Array, options?: SameShape<TransformOptions, T>): TransformResult<T>
|
||||
|
||||
/**
|
||||
* A synchronous version of "formatMessages".
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: no
|
||||
*/
|
||||
export declare function formatMessagesSync(messages: PartialMessage[], options: FormatMessagesOptions): string[]
|
||||
|
||||
/**
|
||||
* A synchronous version of "analyzeMetafile".
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: no
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#analyze
|
||||
*/
|
||||
export declare function analyzeMetafileSync(metafile: Metafile | string, options?: AnalyzeMetafileOptions): string
|
||||
|
||||
/**
|
||||
* This configures the browser-based version of esbuild. It is necessary to
|
||||
* call this first and wait for the returned promise to be resolved before
|
||||
* making other API calls when using esbuild in the browser.
|
||||
*
|
||||
* - Works in node: yes
|
||||
* - Works in browser: yes ("options" is required)
|
||||
*
|
||||
* Documentation: https://esbuild.github.io/api/#browser
|
||||
*/
|
||||
export declare function initialize(options: InitializeOptions): Promise<void>
|
||||
|
||||
export interface InitializeOptions {
|
||||
/**
|
||||
* The URL of the "esbuild.wasm" file. This must be provided when running
|
||||
* esbuild in the browser.
|
||||
*/
|
||||
wasmURL?: string | URL
|
||||
|
||||
/**
|
||||
* The result of calling "new WebAssembly.Module(buffer)" where "buffer"
|
||||
* is a typed array or ArrayBuffer containing the binary code of the
|
||||
* "esbuild.wasm" file.
|
||||
*
|
||||
* You can use this as an alternative to "wasmURL" for environments where it's
|
||||
* not possible to download the WebAssembly module.
|
||||
*/
|
||||
wasmModule?: WebAssembly.Module
|
||||
|
||||
/**
|
||||
* By default esbuild runs the WebAssembly-based browser API in a web worker
|
||||
* to avoid blocking the UI thread. This can be disabled by setting "worker"
|
||||
* to false.
|
||||
*/
|
||||
worker?: boolean
|
||||
}
|
||||
|
||||
export let version: string
|
||||
|
||||
// Call this function to terminate esbuild's child process. The child process
|
||||
// is not terminated and re-created after each API call because it's more
|
||||
// efficient to keep it around when there are multiple API calls.
|
||||
//
|
||||
// In node this happens automatically before the parent node process exits. So
|
||||
// you only need to call this if you know you will not make any more esbuild
|
||||
// API calls and you want to clean up resources.
|
||||
//
|
||||
// Unlike node, Deno lacks the necessary APIs to clean up child processes
|
||||
// automatically. You must manually call stop() in Deno when you're done
|
||||
// using esbuild or Deno will continue running forever.
|
||||
//
|
||||
// Another reason you might want to call this is if you are using esbuild from
|
||||
// within a Deno test. Deno fails tests that create a child process without
|
||||
// killing it before the test ends, so you have to call this function (and
|
||||
// await the returned promise) in every Deno test that uses esbuild.
|
||||
export declare function stop(): Promise<void>
|
||||
|
||||
// Note: These declarations exist to avoid type errors when you omit "dom" from
|
||||
// "lib" in your "tsconfig.json" file. TypeScript confusingly declares the
|
||||
// global "WebAssembly" type in "lib.dom.d.ts" even though it has nothing to do
|
||||
// with the browser DOM and is present in many non-browser JavaScript runtimes
|
||||
// (e.g. node and deno). Declaring it here allows esbuild's API to be used in
|
||||
// these scenarios.
|
||||
//
|
||||
// There's an open issue about getting this problem corrected (although these
|
||||
// declarations will need to remain even if this is fixed for backward
|
||||
// compatibility with older TypeScript versions):
|
||||
//
|
||||
// https://github.com/microsoft/TypeScript-DOM-lib-generator/issues/826
|
||||
//
|
||||
declare global {
|
||||
namespace WebAssembly {
|
||||
interface Module {
|
||||
}
|
||||
}
|
||||
interface URL {
|
||||
}
|
||||
}
|
||||
2240
node_modules/esbuild/lib/main.js
generated
vendored
Normal file
2240
node_modules/esbuild/lib/main.js
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
49
node_modules/esbuild/package.json
generated
vendored
Normal file
49
node_modules/esbuild/package.json
generated
vendored
Normal file
@@ -0,0 +1,49 @@
|
||||
{
|
||||
"name": "esbuild",
|
||||
"version": "0.25.6",
|
||||
"description": "An extremely fast JavaScript and CSS bundler and minifier.",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/evanw/esbuild.git"
|
||||
},
|
||||
"scripts": {
|
||||
"postinstall": "node install.js"
|
||||
},
|
||||
"main": "lib/main.js",
|
||||
"types": "lib/main.d.ts",
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
},
|
||||
"bin": {
|
||||
"esbuild": "bin/esbuild"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"@esbuild/aix-ppc64": "0.25.6",
|
||||
"@esbuild/android-arm": "0.25.6",
|
||||
"@esbuild/android-arm64": "0.25.6",
|
||||
"@esbuild/android-x64": "0.25.6",
|
||||
"@esbuild/darwin-arm64": "0.25.6",
|
||||
"@esbuild/darwin-x64": "0.25.6",
|
||||
"@esbuild/freebsd-arm64": "0.25.6",
|
||||
"@esbuild/freebsd-x64": "0.25.6",
|
||||
"@esbuild/linux-arm": "0.25.6",
|
||||
"@esbuild/linux-arm64": "0.25.6",
|
||||
"@esbuild/linux-ia32": "0.25.6",
|
||||
"@esbuild/linux-loong64": "0.25.6",
|
||||
"@esbuild/linux-mips64el": "0.25.6",
|
||||
"@esbuild/linux-ppc64": "0.25.6",
|
||||
"@esbuild/linux-riscv64": "0.25.6",
|
||||
"@esbuild/linux-s390x": "0.25.6",
|
||||
"@esbuild/linux-x64": "0.25.6",
|
||||
"@esbuild/netbsd-arm64": "0.25.6",
|
||||
"@esbuild/netbsd-x64": "0.25.6",
|
||||
"@esbuild/openbsd-arm64": "0.25.6",
|
||||
"@esbuild/openbsd-x64": "0.25.6",
|
||||
"@esbuild/openharmony-arm64": "0.25.6",
|
||||
"@esbuild/sunos-x64": "0.25.6",
|
||||
"@esbuild/win32-arm64": "0.25.6",
|
||||
"@esbuild/win32-ia32": "0.25.6",
|
||||
"@esbuild/win32-x64": "0.25.6"
|
||||
},
|
||||
"license": "MIT"
|
||||
}
|
||||
21
node_modules/get-tsconfig/LICENSE
generated
vendored
Normal file
21
node_modules/get-tsconfig/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) Hiroki Osame <hiroki.osame@gmail.com>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
235
node_modules/get-tsconfig/README.md
generated
vendored
Normal file
235
node_modules/get-tsconfig/README.md
generated
vendored
Normal file
@@ -0,0 +1,235 @@
|
||||
<p align="center">
|
||||
<img width="160" src=".github/logo.webp">
|
||||
</p>
|
||||
<h1 align="center">
|
||||
<sup>get-tsconfig</sup>
|
||||
<br>
|
||||
<a href="https://npm.im/get-tsconfig"><img src="https://badgen.net/npm/v/get-tsconfig"></a> <a href="https://npm.im/get-tsconfig"><img src="https://badgen.net/npm/dm/get-tsconfig"></a>
|
||||
</h1>
|
||||
|
||||
Find and parse `tsconfig.json` files.
|
||||
|
||||
### Features
|
||||
- Zero dependency (not even TypeScript)
|
||||
- Tested against TypeScript for correctness
|
||||
- Supports comments & dangling commas in `tsconfig.json`
|
||||
- Resolves [`extends`](https://www.typescriptlang.org/tsconfig/#extends)
|
||||
- Fully typed `tsconfig.json`
|
||||
- Validates and throws parsing errors
|
||||
- Tiny! `7 kB` Minified + Gzipped
|
||||
|
||||
<br>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://github.com/sponsors/privatenumber/sponsorships?tier_id=398771"><img width="412" src="https://raw.githubusercontent.com/privatenumber/sponsors/master/banners/assets/donate.webp"></a>
|
||||
<a href="https://github.com/sponsors/privatenumber/sponsorships?tier_id=397608"><img width="412" src="https://raw.githubusercontent.com/privatenumber/sponsors/master/banners/assets/sponsor.webp"></a>
|
||||
</p>
|
||||
<p align="center"><sup><i>Already a sponsor?</i> Join the discussion in the <a href="https://github.com/pvtnbr/get-tsconfig">Development repo</a>!</sup></p>
|
||||
|
||||
## Install
|
||||
|
||||
```bash
|
||||
npm install get-tsconfig
|
||||
```
|
||||
|
||||
## Why?
|
||||
For TypeScript related tooling to correctly parse `tsconfig.json` file without depending on TypeScript.
|
||||
|
||||
## API
|
||||
|
||||
### getTsconfig(searchPath?, configName?, cache?)
|
||||
|
||||
Searches for a tsconfig file (defaults to `tsconfig.json`) in the `searchPath` and parses it. (If you already know the tsconfig path, use [`parseTsconfig`](#parsetsconfigtsconfigpath-cache) instead). Returns `null` if a config file cannot be found, or an object containing the path and parsed TSConfig object if found.
|
||||
|
||||
Returns:
|
||||
|
||||
```ts
|
||||
type TsconfigResult = {
|
||||
|
||||
/**
|
||||
* The path to the tsconfig.json file
|
||||
*/
|
||||
path: string
|
||||
|
||||
/**
|
||||
* The resolved tsconfig.json file
|
||||
*/
|
||||
config: TsConfigJsonResolved
|
||||
}
|
||||
```
|
||||
|
||||
#### searchPath
|
||||
Type: `string`
|
||||
|
||||
Default: `process.cwd()`
|
||||
|
||||
Accepts a path to a file or directory to search up for a `tsconfig.json` file.
|
||||
|
||||
#### configName
|
||||
Type: `string`
|
||||
|
||||
Default: `tsconfig.json`
|
||||
|
||||
The file name of the TypeScript config file.
|
||||
|
||||
#### cache
|
||||
Type: `Map<string, any>`
|
||||
|
||||
Default: `new Map()`
|
||||
|
||||
Optional cache for fs operations.
|
||||
|
||||
#### Example
|
||||
|
||||
```ts
|
||||
import { getTsconfig } from 'get-tsconfig'
|
||||
|
||||
// Searches for tsconfig.json starting in the current directory
|
||||
console.log(getTsconfig())
|
||||
|
||||
// Find tsconfig.json from a TypeScript file path
|
||||
console.log(getTsconfig('./path/to/index.ts'))
|
||||
|
||||
// Find tsconfig.json from a directory file path
|
||||
console.log(getTsconfig('./path/to/directory'))
|
||||
|
||||
// Explicitly pass in tsconfig.json path
|
||||
console.log(getTsconfig('./path/to/tsconfig.json'))
|
||||
|
||||
// Search for jsconfig.json - https://code.visualstudio.com/docs/languages/jsconfig
|
||||
console.log(getTsconfig('.', 'jsconfig.json'))
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### parseTsconfig(tsconfigPath, cache?)
|
||||
|
||||
Parse the tsconfig file provided. Used internally by `getTsconfig`. Returns the parsed tsconfig as `TsConfigJsonResolved`.
|
||||
|
||||
#### tsconfigPath
|
||||
Type: `string`
|
||||
|
||||
Required path to the tsconfig file.
|
||||
|
||||
#### cache
|
||||
Type: `Map<string, any>`
|
||||
|
||||
Default: `new Map()`
|
||||
|
||||
Optional cache for fs operations.
|
||||
|
||||
#### Example
|
||||
|
||||
```ts
|
||||
import { parseTsconfig } from 'get-tsconfig'
|
||||
|
||||
// Must pass in a path to an existing tsconfig.json file
|
||||
console.log(parseTsconfig('./path/to/tsconfig.custom.json'))
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### createFileMatcher(tsconfig: TsconfigResult, caseSensitivePaths?: boolean)
|
||||
|
||||
Given a `tsconfig.json` file, it returns a file-matcher function that determines whether it should apply to a file path.
|
||||
|
||||
```ts
|
||||
type FileMatcher = (filePath: string) => TsconfigResult['config'] | undefined
|
||||
```
|
||||
|
||||
#### tsconfig
|
||||
Type: `TsconfigResult`
|
||||
|
||||
Pass in the return value from `getTsconfig`, or a `TsconfigResult` object.
|
||||
|
||||
#### caseSensitivePaths
|
||||
Type: `boolean`
|
||||
|
||||
By default, it uses [`is-fs-case-sensitive`](https://github.com/privatenumber/is-fs-case-sensitive) to detect whether the file-system is case-sensitive.
|
||||
|
||||
Pass in `true` to make it case-sensitive.
|
||||
|
||||
#### Example
|
||||
|
||||
For example, if it's called with a `tsconfig.json` file that has `include`/`exclude`/`files` defined, the file-matcher will return the config for files that match `include`/`files`, and return `undefined` for files that don't match or match `exclude`.
|
||||
|
||||
```ts
|
||||
const tsconfig = getTsconfig()
|
||||
const fileMatcher = tsconfig && createFileMatcher(tsconfig)
|
||||
|
||||
/*
|
||||
* Returns tsconfig.json if it matches the file,
|
||||
* undefined if not
|
||||
*/
|
||||
const configForFile = fileMatcher?.('/path/to/file.ts')
|
||||
const distCode = compileTypescript({
|
||||
code: sourceCode,
|
||||
tsconfig: configForFile
|
||||
})
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### createPathsMatcher(tsconfig: TsconfigResult)
|
||||
|
||||
Given a tsconfig with [`compilerOptions.paths`](https://www.typescriptlang.org/tsconfig#paths) defined, it returns a matcher function.
|
||||
|
||||
The matcher function accepts an [import specifier (the path to resolve)](https://nodejs.org/api/esm.html#terminology), checks it against `compilerOptions.paths`, and returns an array of possible paths to check:
|
||||
```ts
|
||||
function pathsMatcher(specifier: string): string[]
|
||||
```
|
||||
|
||||
This function only returns possible paths and doesn't actually do any resolution. This helps increase compatibility wtih file/build systems which usually have their own resolvers.
|
||||
|
||||
#### Example
|
||||
|
||||
```ts
|
||||
import { getTsconfig, createPathsMatcher } from 'get-tsconfig'
|
||||
|
||||
const tsconfig = getTsconfig()
|
||||
const pathsMatcher = createPathsMatcher(tsconfig)
|
||||
|
||||
const exampleResolver = (request: string) => {
|
||||
if (pathsMatcher) {
|
||||
const tryPaths = pathsMatcher(request)
|
||||
|
||||
// Check if paths in `tryPaths` exist
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## FAQ
|
||||
|
||||
### How can I use TypeScript to parse `tsconfig.json`?
|
||||
This package is a re-implementation of TypeScript's `tsconfig.json` parser.
|
||||
|
||||
However, if you already have TypeScript as a dependency, you can simply use it's API:
|
||||
|
||||
```ts
|
||||
import {
|
||||
sys as tsSys,
|
||||
findConfigFile,
|
||||
readConfigFile,
|
||||
parseJsonConfigFileContent
|
||||
} from 'typescript'
|
||||
|
||||
// Find tsconfig.json file
|
||||
const tsconfigPath = findConfigFile(process.cwd(), tsSys.fileExists, 'tsconfig.json')
|
||||
|
||||
// Read tsconfig.json file
|
||||
const tsconfigFile = readConfigFile(tsconfigPath, tsSys.readFile)
|
||||
|
||||
// Resolve extends
|
||||
const parsedTsconfig = parseJsonConfigFileContent(
|
||||
tsconfigFile.config,
|
||||
tsSys,
|
||||
path.dirname(tsconfigPath)
|
||||
)
|
||||
```
|
||||
|
||||
## Sponsors
|
||||
<p align="center">
|
||||
<a href="https://github.com/sponsors/privatenumber">
|
||||
<img src="https://cdn.jsdelivr.net/gh/privatenumber/sponsors/sponsorkit/sponsors.svg">
|
||||
</a>
|
||||
</p>
|
||||
7
node_modules/get-tsconfig/dist/index.cjs
generated
vendored
Normal file
7
node_modules/get-tsconfig/dist/index.cjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
1439
node_modules/get-tsconfig/dist/index.d.cts
generated
vendored
Normal file
1439
node_modules/get-tsconfig/dist/index.d.cts
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
1439
node_modules/get-tsconfig/dist/index.d.mts
generated
vendored
Normal file
1439
node_modules/get-tsconfig/dist/index.d.mts
generated
vendored
Normal file
File diff suppressed because it is too large
Load Diff
7
node_modules/get-tsconfig/dist/index.mjs
generated
vendored
Normal file
7
node_modules/get-tsconfig/dist/index.mjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
46
node_modules/get-tsconfig/package.json
generated
vendored
Normal file
46
node_modules/get-tsconfig/package.json
generated
vendored
Normal file
@@ -0,0 +1,46 @@
|
||||
{
|
||||
"name": "get-tsconfig",
|
||||
"version": "4.10.1",
|
||||
"description": "Find and parse the tsconfig.json file from a directory path",
|
||||
"keywords": [
|
||||
"get-tsconfig",
|
||||
"get",
|
||||
"typescript",
|
||||
"tsconfig",
|
||||
"tsconfig.json"
|
||||
],
|
||||
"license": "MIT",
|
||||
"repository": "privatenumber/get-tsconfig",
|
||||
"funding": "https://github.com/privatenumber/get-tsconfig?sponsor=1",
|
||||
"author": {
|
||||
"name": "Hiroki Osame",
|
||||
"email": "hiroki.osame@gmail.com"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"type": "module",
|
||||
"main": "./dist/index.cjs",
|
||||
"module": "./dist/index.mjs",
|
||||
"types": "./dist/index.d.cts",
|
||||
"exports": {
|
||||
"require": {
|
||||
"types": "./dist/index.d.cts",
|
||||
"default": "./dist/index.cjs"
|
||||
},
|
||||
"import": {
|
||||
"types": "./dist/index.d.mts",
|
||||
"default": "./dist/index.mjs"
|
||||
}
|
||||
},
|
||||
"imports": {
|
||||
"#get-tsconfig": {
|
||||
"types": "./src/index.ts",
|
||||
"development": "./src/index.ts",
|
||||
"default": "./dist/index.mjs"
|
||||
}
|
||||
},
|
||||
"dependencies": {
|
||||
"resolve-pkg-maps": "^1.0.0"
|
||||
}
|
||||
}
|
||||
21
node_modules/resolve-pkg-maps/LICENSE
generated
vendored
Normal file
21
node_modules/resolve-pkg-maps/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) Hiroki Osame <hiroki.osame@gmail.com>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
216
node_modules/resolve-pkg-maps/README.md
generated
vendored
Normal file
216
node_modules/resolve-pkg-maps/README.md
generated
vendored
Normal file
@@ -0,0 +1,216 @@
|
||||
# resolve-pkg-maps
|
||||
|
||||
Utils to resolve `package.json` subpath & conditional [`exports`](https://nodejs.org/api/packages.html#exports)/[`imports`](https://nodejs.org/api/packages.html#imports) in resolvers.
|
||||
|
||||
Implements the [ESM resolution algorithm](https://nodejs.org/api/esm.html#resolver-algorithm-specification). Tested [against Node.js](/tests/) for accuracy.
|
||||
|
||||
<sub>Support this project by ⭐️ starring and sharing it. [Follow me](https://github.com/privatenumber) to see what other cool projects I'm working on! ❤️</sub>
|
||||
|
||||
## Usage
|
||||
|
||||
### Resolving `exports`
|
||||
|
||||
_utils/package.json_
|
||||
```json5
|
||||
{
|
||||
// ...
|
||||
"exports": {
|
||||
"./reverse": {
|
||||
"require": "./file.cjs",
|
||||
"default": "./file.mjs"
|
||||
}
|
||||
},
|
||||
// ...
|
||||
}
|
||||
```
|
||||
|
||||
```ts
|
||||
import { resolveExports } from 'resolve-pkg-maps'
|
||||
|
||||
const [packageName, packageSubpath] = parseRequest('utils/reverse')
|
||||
|
||||
const resolvedPaths: string[] = resolveExports(
|
||||
getPackageJson(packageName).exports,
|
||||
packageSubpath,
|
||||
['import', ...otherConditions]
|
||||
)
|
||||
// => ['./file.mjs']
|
||||
```
|
||||
|
||||
### Resolving `imports`
|
||||
|
||||
_package.json_
|
||||
```json5
|
||||
{
|
||||
// ...
|
||||
"imports": {
|
||||
"#supports-color": {
|
||||
"node": "./index.js",
|
||||
"default": "./browser.js"
|
||||
}
|
||||
},
|
||||
// ...
|
||||
}
|
||||
```
|
||||
|
||||
```ts
|
||||
import { resolveImports } from 'resolve-pkg-maps'
|
||||
|
||||
const resolvedPaths: string[] = resolveImports(
|
||||
getPackageJson('.').imports,
|
||||
'#supports-color',
|
||||
['node', ...otherConditions]
|
||||
)
|
||||
// => ['./index.js']
|
||||
```
|
||||
|
||||
## API
|
||||
|
||||
### resolveExports(exports, request, conditions)
|
||||
|
||||
Returns: `string[]`
|
||||
|
||||
Resolves the `request` based on `exports` and `conditions`. Returns an array of paths (e.g. in case a fallback array is matched).
|
||||
|
||||
#### exports
|
||||
|
||||
Type:
|
||||
```ts
|
||||
type Exports = PathOrMap | readonly PathOrMap[]
|
||||
|
||||
type PathOrMap = string | PathConditionsMap
|
||||
|
||||
type PathConditionsMap = {
|
||||
[condition: string]: PathConditions | null
|
||||
}
|
||||
```
|
||||
|
||||
The [`exports` property](https://nodejs.org/api/packages.html#exports) value in `package.json`.
|
||||
|
||||
#### request
|
||||
|
||||
Type: `string`
|
||||
|
||||
The package subpath to resolve. Assumes a normalized path is passed in (eg. [repeating slashes `//`](https://github.com/nodejs/node/issues/44316)).
|
||||
|
||||
It _should not_ start with `/` or `./`.
|
||||
|
||||
Example: if the full import path is `some-package/subpath/file`, the request is `subpath/file`.
|
||||
|
||||
|
||||
#### conditions
|
||||
|
||||
Type: `readonly string[]`
|
||||
|
||||
An array of conditions to use when resolving the request. For reference, Node.js's default conditions are [`['node', 'import']`](https://nodejs.org/api/esm.html#:~:text=defaultConditions%20is%20the%20conditional%20environment%20name%20array%2C%20%5B%22node%22%2C%20%22import%22%5D.).
|
||||
|
||||
The order of this array does not matter; the order of condition keys in the export map is what matters instead.
|
||||
|
||||
Not all conditions in the array need to be met to resolve the request. It just needs enough to resolve to a path.
|
||||
|
||||
---
|
||||
|
||||
### resolveImports(imports, request, conditions)
|
||||
|
||||
Returns: `string[]`
|
||||
|
||||
Resolves the `request` based on `imports` and `conditions`. Returns an array of paths (e.g. in case a fallback array is matched).
|
||||
|
||||
#### imports
|
||||
|
||||
Type:
|
||||
```ts
|
||||
type Imports = {
|
||||
[condition: string]: PathOrMap | readonly PathOrMap[] | null
|
||||
}
|
||||
|
||||
type PathOrMap = string | Imports
|
||||
```
|
||||
|
||||
The [`imports` property](https://nodejs.org/api/packages.html#imports) value in `package.json`.
|
||||
|
||||
|
||||
#### request
|
||||
|
||||
Type: `string`
|
||||
|
||||
The request resolve. Assumes a normalized path is passed in (eg. [repeating slashes `//`](https://github.com/nodejs/node/issues/44316)).
|
||||
|
||||
> **Note:** In Node.js, imports resolutions are limited to requests prefixed with `#`. However, this package does not enforce that requirement in case you want to add custom support for non-prefixed entries.
|
||||
|
||||
#### conditions
|
||||
|
||||
Type: `readonly string[]`
|
||||
|
||||
An array of conditions to use when resolving the request. For reference, Node.js's default conditions are [`['node', 'import']`](https://nodejs.org/api/esm.html#:~:text=defaultConditions%20is%20the%20conditional%20environment%20name%20array%2C%20%5B%22node%22%2C%20%22import%22%5D.).
|
||||
|
||||
The order of this array does not matter; the order of condition keys in the import map is what matters instead.
|
||||
|
||||
Not all conditions in the array need to be met to resolve the request. It just needs enough to resolve to a path.
|
||||
|
||||
---
|
||||
|
||||
### Errors
|
||||
|
||||
#### `ERR_PACKAGE_PATH_NOT_EXPORTED`
|
||||
- If the request is not exported by the export map
|
||||
|
||||
#### `ERR_PACKAGE_IMPORT_NOT_DEFINED`
|
||||
- If the request is not defined by the import map
|
||||
|
||||
#### `ERR_INVALID_PACKAGE_CONFIG`
|
||||
|
||||
- If an object contains properties that are both paths and conditions (e.g. start with and without `.`)
|
||||
- If an object contains numeric properties
|
||||
|
||||
#### `ERR_INVALID_PACKAGE_TARGET`
|
||||
- If a resolved exports path is not a valid path (e.g. not relative or has protocol)
|
||||
- If a resolved path includes `..` or `node_modules`
|
||||
- If a resolved path is a type that cannot be parsed
|
||||
|
||||
## FAQ
|
||||
|
||||
### Why do the APIs return an array of paths?
|
||||
|
||||
`exports`/`imports` supports passing in a [fallback array](https://github.com/jkrems/proposal-pkg-exports/#:~:text=Whenever%20there%20is,to%20new%20cases.) to provide fallback paths if the previous one is invalid:
|
||||
|
||||
```json5
|
||||
{
|
||||
"exports": {
|
||||
"./feature": [
|
||||
"./file.js",
|
||||
"./fallback.js"
|
||||
]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
Node.js's implementation [picks the first valid path (without attempting to resolve it)](https://github.com/nodejs/node/issues/44282#issuecomment-1220151715) and throws an error if it can't be resolved. Node.js's fallback array is designed for [forward compatibility with features](https://github.com/jkrems/proposal-pkg-exports/#:~:text=providing%20forwards%20compatiblitiy%20for%20new%20features) (e.g. protocols) that can be immediately/inexpensively validated:
|
||||
|
||||
```json5
|
||||
{
|
||||
"exports": {
|
||||
"./core-polyfill": ["std:core-module", "./core-polyfill.js"]
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
However, [Webpack](https://webpack.js.org/guides/package-exports/#alternatives) and [TypeScript](https://github.com/microsoft/TypeScript/blob/71e852922888337ef51a0e48416034a94a6c34d9/src/compiler/moduleSpecifiers.ts#L695) have deviated from this behavior and attempts to resolve the next path if a path cannot be resolved.
|
||||
|
||||
By returning an array of matched paths instead of just the first one, the user can decide which behavior to adopt.
|
||||
|
||||
### How is it different from [`resolve.exports`](https://github.com/lukeed/resolve.exports)?
|
||||
|
||||
`resolve.exports` only resolves `exports`, whereas this package resolves both `exports` & `imports`. This comparison will only cover resolving `exports`.
|
||||
|
||||
- Despite it's name, `resolve.exports` handles more than just `exports`. It takes in the entire `package.json` object to handle resolving `.` and [self-references](https://nodejs.org/api/packages.html#self-referencing-a-package-using-its-name). This package only accepts `exports`/`imports` maps from `package.json` and is scoped to only resolving what's defined in the maps.
|
||||
|
||||
- `resolve.exports` accepts the full request (e.g. `foo/bar`), whereas this package only accepts the requested subpath (e.g. `bar`).
|
||||
|
||||
- `resolve.exports` only returns the first result in a fallback array. This package returns an array of results for the user to decide how to handle it.
|
||||
|
||||
- `resolve.exports` supports [subpath folder mapping](https://nodejs.org/docs/latest-v16.x/api/packages.html#subpath-folder-mappings) (deprecated in Node.js v16 & removed in v17) but seems to [have a bug](https://github.com/lukeed/resolve.exports/issues/7). This package does not support subpath folder mapping because Node.js has removed it in favor of using subpath patterns.
|
||||
|
||||
- Neither resolvers rely on a file-system
|
||||
|
||||
This package also addresses many of the bugs in `resolve.exports`, demonstrated in [this test](/tests/exports/compare-resolve.exports.ts).
|
||||
1
node_modules/resolve-pkg-maps/dist/index.cjs
generated
vendored
Normal file
1
node_modules/resolve-pkg-maps/dist/index.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});const d=r=>r!==null&&typeof r=="object",s=(r,t)=>Object.assign(new Error(`[${r}]: ${t}`),{code:r}),g="ERR_INVALID_PACKAGE_CONFIG",E="ERR_INVALID_PACKAGE_TARGET",I="ERR_PACKAGE_PATH_NOT_EXPORTED",P="ERR_PACKAGE_IMPORT_NOT_DEFINED",R=/^\d+$/,O=/^(\.{1,2}|node_modules)$/i,u=/\/|\\/;var h=(r=>(r.Export="exports",r.Import="imports",r))(h||{});const f=(r,t,n,o,c)=>{if(t==null)return[];if(typeof t=="string"){const[e,...i]=t.split(u);if(e===".."||i.some(l=>O.test(l)))throw s(E,`Invalid "${r}" target "${t}" defined in the package config`);return[c?t.replace(/\*/g,c):t]}if(Array.isArray(t))return t.flatMap(e=>f(r,e,n,o,c));if(d(t)){for(const e of Object.keys(t)){if(R.test(e))throw s(g,"Cannot contain numeric property keys");if(e==="default"||o.includes(e))return f(r,t[e],n,o,c)}return[]}throw s(E,`Invalid "${r}" target "${t}"`)},a="*",v=(r,t)=>{const n=r.indexOf(a),o=t.indexOf(a);return n===o?t.length>r.length:o>n};function A(r,t){if(!t.includes(a)&&r.hasOwnProperty(t))return[t];let n,o;for(const c of Object.keys(r))if(c.includes(a)){const[e,i,l]=c.split(a);if(l===void 0&&t.startsWith(e)&&t.endsWith(i)){const _=t.slice(e.length,-i.length||void 0);_&&(!n||v(n,c))&&(n=c,o=_)}}return[n,o]}const p=r=>Object.keys(r).reduce((t,n)=>{const o=n===""||n[0]!==".";if(t===void 0||t===o)return o;throw s(g,'"exports" cannot contain some keys starting with "." and some not')},void 0),w=/^\w+:/,m=(r,t,n)=>{if(!r)throw new Error('"exports" is required');t=t===""?".":`./${t}`,(typeof r=="string"||Array.isArray(r)||d(r)&&p(r))&&(r={".":r});const[o,c]=A(r,t),e=f(h.Export,r[o],t,n,c);if(e.length===0)throw s(I,t==="."?'No "exports" main defined':`Package subpath '${t}' is not defined by "exports"`);for(const i of e)if(!i.startsWith("./")&&!w.test(i))throw s(E,`Invalid "exports" target "${i}" defined in the package config`);return e},T=(r,t,n)=>{if(!r)throw new Error('"imports" is required');const[o,c]=A(r,t),e=f(h.Import,r[o],t,n,c);if(e.length===0)throw s(P,`Package import specifier "${t}" is not defined in package`);return e};exports.resolveExports=m,exports.resolveImports=T;
|
||||
11
node_modules/resolve-pkg-maps/dist/index.d.cts
generated
vendored
Normal file
11
node_modules/resolve-pkg-maps/dist/index.d.cts
generated
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
type PathConditionsMap = {
|
||||
[condition: string]: PathConditions | null;
|
||||
};
|
||||
type PathOrMap = string | PathConditionsMap;
|
||||
type PathConditions = PathOrMap | readonly PathOrMap[];
|
||||
|
||||
declare const resolveExports: (exports: PathConditions, request: string, conditions: readonly string[]) => string[];
|
||||
|
||||
declare const resolveImports: (imports: PathConditionsMap, request: string, conditions: readonly string[]) => string[];
|
||||
|
||||
export { PathConditions, PathConditionsMap, resolveExports, resolveImports };
|
||||
11
node_modules/resolve-pkg-maps/dist/index.d.mts
generated
vendored
Normal file
11
node_modules/resolve-pkg-maps/dist/index.d.mts
generated
vendored
Normal file
@@ -0,0 +1,11 @@
|
||||
type PathConditionsMap = {
|
||||
[condition: string]: PathConditions | null;
|
||||
};
|
||||
type PathOrMap = string | PathConditionsMap;
|
||||
type PathConditions = PathOrMap | readonly PathOrMap[];
|
||||
|
||||
declare const resolveExports: (exports: PathConditions, request: string, conditions: readonly string[]) => string[];
|
||||
|
||||
declare const resolveImports: (imports: PathConditionsMap, request: string, conditions: readonly string[]) => string[];
|
||||
|
||||
export { PathConditions, PathConditionsMap, resolveExports, resolveImports };
|
||||
1
node_modules/resolve-pkg-maps/dist/index.mjs
generated
vendored
Normal file
1
node_modules/resolve-pkg-maps/dist/index.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
const A=r=>r!==null&&typeof r=="object",a=(r,t)=>Object.assign(new Error(`[${r}]: ${t}`),{code:r}),_="ERR_INVALID_PACKAGE_CONFIG",E="ERR_INVALID_PACKAGE_TARGET",I="ERR_PACKAGE_PATH_NOT_EXPORTED",P="ERR_PACKAGE_IMPORT_NOT_DEFINED",R=/^\d+$/,O=/^(\.{1,2}|node_modules)$/i,w=/\/|\\/;var h=(r=>(r.Export="exports",r.Import="imports",r))(h||{});const f=(r,t,e,o,c)=>{if(t==null)return[];if(typeof t=="string"){const[n,...i]=t.split(w);if(n===".."||i.some(l=>O.test(l)))throw a(E,`Invalid "${r}" target "${t}" defined in the package config`);return[c?t.replace(/\*/g,c):t]}if(Array.isArray(t))return t.flatMap(n=>f(r,n,e,o,c));if(A(t)){for(const n of Object.keys(t)){if(R.test(n))throw a(_,"Cannot contain numeric property keys");if(n==="default"||o.includes(n))return f(r,t[n],e,o,c)}return[]}throw a(E,`Invalid "${r}" target "${t}"`)},s="*",m=(r,t)=>{const e=r.indexOf(s),o=t.indexOf(s);return e===o?t.length>r.length:o>e};function d(r,t){if(!t.includes(s)&&r.hasOwnProperty(t))return[t];let e,o;for(const c of Object.keys(r))if(c.includes(s)){const[n,i,l]=c.split(s);if(l===void 0&&t.startsWith(n)&&t.endsWith(i)){const g=t.slice(n.length,-i.length||void 0);g&&(!e||m(e,c))&&(e=c,o=g)}}return[e,o]}const p=r=>Object.keys(r).reduce((t,e)=>{const o=e===""||e[0]!==".";if(t===void 0||t===o)return o;throw a(_,'"exports" cannot contain some keys starting with "." and some not')},void 0),u=/^\w+:/,v=(r,t,e)=>{if(!r)throw new Error('"exports" is required');t=t===""?".":`./${t}`,(typeof r=="string"||Array.isArray(r)||A(r)&&p(r))&&(r={".":r});const[o,c]=d(r,t),n=f(h.Export,r[o],t,e,c);if(n.length===0)throw a(I,t==="."?'No "exports" main defined':`Package subpath '${t}' is not defined by "exports"`);for(const i of n)if(!i.startsWith("./")&&!u.test(i))throw a(E,`Invalid "exports" target "${i}" defined in the package config`);return n},T=(r,t,e)=>{if(!r)throw new Error('"imports" is required');const[o,c]=d(r,t),n=f(h.Import,r[o],t,e,c);if(n.length===0)throw a(P,`Package import specifier "${t}" is not defined in package`);return n};export{v as resolveExports,T as resolveImports};
|
||||
42
node_modules/resolve-pkg-maps/package.json
generated
vendored
Normal file
42
node_modules/resolve-pkg-maps/package.json
generated
vendored
Normal file
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"name": "resolve-pkg-maps",
|
||||
"version": "1.0.0",
|
||||
"description": "Resolve package.json exports & imports maps",
|
||||
"keywords": [
|
||||
"node.js",
|
||||
"package.json",
|
||||
"exports",
|
||||
"imports"
|
||||
],
|
||||
"license": "MIT",
|
||||
"repository": "privatenumber/resolve-pkg-maps",
|
||||
"funding": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1",
|
||||
"author": {
|
||||
"name": "Hiroki Osame",
|
||||
"email": "hiroki.osame@gmail.com"
|
||||
},
|
||||
"type": "module",
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"main": "./dist/index.cjs",
|
||||
"module": "./dist/index.mjs",
|
||||
"types": "./dist/index.d.cts",
|
||||
"exports": {
|
||||
"require": {
|
||||
"types": "./dist/index.d.cts",
|
||||
"default": "./dist/index.cjs"
|
||||
},
|
||||
"import": {
|
||||
"types": "./dist/index.d.mts",
|
||||
"default": "./dist/index.mjs"
|
||||
}
|
||||
},
|
||||
"imports": {
|
||||
"#resolve-pkg-maps": {
|
||||
"types": "./src/index.ts",
|
||||
"development": "./src/index.ts",
|
||||
"default": "./dist/index.mjs"
|
||||
}
|
||||
}
|
||||
}
|
||||
21
node_modules/tsx/LICENSE
generated
vendored
Normal file
21
node_modules/tsx/LICENSE
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
MIT License
|
||||
|
||||
Copyright (c) Hiroki Osame <hiroki.osame@gmail.com>
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
||||
32
node_modules/tsx/README.md
generated
vendored
Normal file
32
node_modules/tsx/README.md
generated
vendored
Normal file
@@ -0,0 +1,32 @@
|
||||
<h1 align="center">
|
||||
<br>
|
||||
<picture>
|
||||
<source media="(prefers-color-scheme: dark)" srcset=".github/logo-dark.svg">
|
||||
<img width="160" alt="tsx" src=".github/logo-light.svg">
|
||||
</picture>
|
||||
<br><br>
|
||||
<a href="https://npm.im/tsx"><img src="https://badgen.net/npm/v/tsx"></a> <a href="https://npm.im/tsx"><img src="https://badgen.net/npm/dm/tsx"></a>
|
||||
</h1>
|
||||
|
||||
<p align="center">
|
||||
TypeScript Execute (tsx): The easiest way to run TypeScript in Node.js
|
||||
<br><br>
|
||||
<a href="https://tsx.is">Documentation</a> | <a href="https://tsx.is/getting-started">Getting started →</a>
|
||||
</p>
|
||||
|
||||
<br>
|
||||
|
||||
<p align="center">
|
||||
<a href="https://github.com/sponsors/privatenumber/sponsorships?tier_id=398771"><img width="412" src="https://raw.githubusercontent.com/privatenumber/sponsors/master/banners/assets/donate.webp"></a>
|
||||
<a href="https://github.com/sponsors/privatenumber/sponsorships?tier_id=416984"><img width="412" src="https://raw.githubusercontent.com/privatenumber/sponsors/master/banners/assets/sponsor.webp"></a>
|
||||
</p>
|
||||
<p align="center"><sup><i>Already a sponsor?</i> Join the discussion in the <a href="https://github.com/pvtnbr/tsx">Development repo</a>!</sup></p>
|
||||
|
||||
## Sponsors
|
||||
|
||||
<p align="center">
|
||||
<a href="https://github.com/sponsors/privatenumber">
|
||||
<img src="https://cdn.jsdelivr.net/gh/privatenumber/sponsors/sponsorkit/sponsors.svg">
|
||||
</a>
|
||||
</p>
|
||||
|
||||
1
node_modules/tsx/dist/cjs/api/index.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/cjs/api/index.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";require("../../get-pipe-path-BoR10qr8.cjs");var r=require("../../register-D46fvsV_.cjs"),e=require("../../require-D4F1Lv60.cjs");require("module"),require("node:path"),require("../../temporary-directory-B83uKxJF.cjs"),require("node:os"),require("node:module"),require("node:url"),require("get-tsconfig"),require("node:fs"),require("../../index-gckBtVBf.cjs"),require("esbuild"),require("node:crypto"),require("../../client-D6NvIMSC.cjs"),require("node:net"),require("node:util"),require("../../index-BWFBUo6r.cjs"),exports.register=r.register,exports.require=e.tsxRequire;
|
||||
35
node_modules/tsx/dist/cjs/api/index.d.cts
generated
vendored
Normal file
35
node_modules/tsx/dist/cjs/api/index.d.cts
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
|
||||
|
||||
type RegisterOptions = {
|
||||
namespace?: string;
|
||||
};
|
||||
type Unregister = () => void;
|
||||
type ScopedRequire = (id: string, fromFile: string | URL) => any;
|
||||
type ScopedResolve = (id: string, fromFile: string | URL, resolveOptions?: {
|
||||
paths?: string[] | undefined;
|
||||
}) => string;
|
||||
type NamespacedUnregister = Unregister & {
|
||||
require: ScopedRequire;
|
||||
resolve: ScopedResolve;
|
||||
unregister: Unregister;
|
||||
};
|
||||
type Register = {
|
||||
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
|
||||
(options?: RegisterOptions): Unregister;
|
||||
};
|
||||
declare const register: Register;
|
||||
|
||||
declare const tsxRequire: {
|
||||
(id: string, fromFile: string | URL): any;
|
||||
resolve: {
|
||||
(id: string, fromFile: string | URL, options?: {
|
||||
paths?: string[] | undefined;
|
||||
}): string;
|
||||
paths: (request: string) => string[] | null;
|
||||
};
|
||||
main: NodeJS.Module | undefined;
|
||||
extensions: NodeJS.RequireExtensions;
|
||||
cache: NodeJS.Dict<NodeJS.Module>;
|
||||
};
|
||||
|
||||
export { register, tsxRequire as require };
|
||||
35
node_modules/tsx/dist/cjs/api/index.d.mts
generated
vendored
Normal file
35
node_modules/tsx/dist/cjs/api/index.d.mts
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
|
||||
|
||||
type RegisterOptions = {
|
||||
namespace?: string;
|
||||
};
|
||||
type Unregister = () => void;
|
||||
type ScopedRequire = (id: string, fromFile: string | URL) => any;
|
||||
type ScopedResolve = (id: string, fromFile: string | URL, resolveOptions?: {
|
||||
paths?: string[] | undefined;
|
||||
}) => string;
|
||||
type NamespacedUnregister = Unregister & {
|
||||
require: ScopedRequire;
|
||||
resolve: ScopedResolve;
|
||||
unregister: Unregister;
|
||||
};
|
||||
type Register = {
|
||||
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
|
||||
(options?: RegisterOptions): Unregister;
|
||||
};
|
||||
declare const register: Register;
|
||||
|
||||
declare const tsxRequire: {
|
||||
(id: string, fromFile: string | URL): any;
|
||||
resolve: {
|
||||
(id: string, fromFile: string | URL, options?: {
|
||||
paths?: string[] | undefined;
|
||||
}): string;
|
||||
paths: (request: string) => string[] | null;
|
||||
};
|
||||
main: NodeJS.Module | undefined;
|
||||
extensions: NodeJS.RequireExtensions;
|
||||
cache: NodeJS.Dict<NodeJS.Module>;
|
||||
};
|
||||
|
||||
export { register, tsxRequire as require };
|
||||
1
node_modules/tsx/dist/cjs/api/index.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/cjs/api/index.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
import"../../get-pipe-path-BHW2eJdv.mjs";import{r as j}from"../../register-CFH5oNdT.mjs";import{t as l}from"../../require-DQxpCAr4.mjs";import"module";import"node:path";import"../../temporary-directory-CwHp0_NW.mjs";import"node:os";import"node:module";import"node:url";import"get-tsconfig";import"node:fs";import"../../index-7AaEi15b.mjs";import"esbuild";import"node:crypto";import"../../client-BQVF1NaW.mjs";import"node:net";import"node:util";import"../../index-gbaejti9.mjs";export{j as register,l as require};
|
||||
1
node_modules/tsx/dist/cjs/index.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/cjs/index.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var r=require("../register-D46fvsV_.cjs");require("../get-pipe-path-BoR10qr8.cjs"),require("module"),require("node:path"),require("../temporary-directory-B83uKxJF.cjs"),require("node:os"),require("node:module"),require("node:url"),require("get-tsconfig"),require("node:fs"),require("../index-gckBtVBf.cjs"),require("esbuild"),require("node:crypto"),require("../client-D6NvIMSC.cjs"),require("node:net"),require("node:util"),require("../index-BWFBUo6r.cjs"),r.register();
|
||||
1
node_modules/tsx/dist/cjs/index.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/cjs/index.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
import{r}from"../register-CFH5oNdT.mjs";import"../get-pipe-path-BHW2eJdv.mjs";import"module";import"node:path";import"../temporary-directory-CwHp0_NW.mjs";import"node:os";import"node:module";import"node:url";import"get-tsconfig";import"node:fs";import"../index-7AaEi15b.mjs";import"esbuild";import"node:crypto";import"../client-BQVF1NaW.mjs";import"node:net";import"node:util";import"../index-gbaejti9.mjs";r();
|
||||
54
node_modules/tsx/dist/cli.cjs
generated
vendored
Normal file
54
node_modules/tsx/dist/cli.cjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
55
node_modules/tsx/dist/cli.mjs
generated
vendored
Normal file
55
node_modules/tsx/dist/cli.mjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
1
node_modules/tsx/dist/client-BQVF1NaW.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/client-BQVF1NaW.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var a=Object.defineProperty;var o=(e,n)=>a(e,"name",{value:n,configurable:!0});import p from"node:net";import{g}from"./get-pipe-path-BHW2eJdv.mjs";const m=o(()=>new Promise(e=>{const n=g(process.ppid),t=p.createConnection(n,()=>{e(o(i=>{const r=Buffer.from(JSON.stringify(i)),s=Buffer.alloc(4);s.writeInt32BE(r.length,0),t.write(Buffer.concat([s,r]))},"sendToParent"))});t.on("error",()=>{e()}),t.unref()}),"connectToServer"),c={send:void 0},f=m();f.then(e=>{c.send=e},()=>{});export{f as c,c as p};
|
||||
1
node_modules/tsx/dist/client-D6NvIMSC.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/client-D6NvIMSC.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var f=Object.defineProperty;var r=(e,n)=>f(e,"name",{value:n,configurable:!0});var p=require("node:net"),u=require("./get-pipe-path-BoR10qr8.cjs");const g=r(()=>new Promise(e=>{const n=u.getPipePath(process.ppid),t=p.createConnection(n,()=>{e(r(a=>{const o=Buffer.from(JSON.stringify(a)),c=Buffer.alloc(4);c.writeInt32BE(o.length,0),t.write(Buffer.concat([c,o]))},"sendToParent"))});t.on("error",()=>{e()}),t.unref()}),"connectToServer"),s={send:void 0},i=g();i.then(e=>{s.send=e},()=>{}),exports.connectingToServer=i,exports.parent=s;
|
||||
1
node_modules/tsx/dist/esm/api/index.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/esm/api/index.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var m=Object.defineProperty;var a=(r,e)=>m(r,"name",{value:e,configurable:!0});var q=require("../../register-2sWVXuRQ.cjs");require("../../get-pipe-path-BoR10qr8.cjs");var t=require("../../register-D46fvsV_.cjs");require("../../require-D4F1Lv60.cjs");var n=require("../../node-features-roYmp9jK.cjs");require("node:module"),require("node:worker_threads"),require("node:url"),require("module"),require("node:path"),require("../../temporary-directory-B83uKxJF.cjs"),require("node:os"),require("get-tsconfig"),require("node:fs"),require("../../index-gckBtVBf.cjs"),require("esbuild"),require("node:crypto"),require("../../client-D6NvIMSC.cjs"),require("node:net"),require("node:util"),require("../../index-BWFBUo6r.cjs");const c=a((r,e)=>{if(!e||typeof e=="object"&&!e.parentURL)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const i=typeof e=="string",u=i?e:e.parentURL,s=Date.now().toString(),o=t.register({namespace:s});return!n.isFeatureSupported(n.esmLoadReadFile)&&!t.isBarePackageNamePattern.test(r)&&t.cjsExtensionPattern.test(r)?Promise.resolve(o.require(r,u)):q.register({namespace:s,...i?{}:e}).import(r,u)},"tsImport");exports.register=q.register,exports.tsImport=c;
|
||||
35
node_modules/tsx/dist/esm/api/index.d.cts
generated
vendored
Normal file
35
node_modules/tsx/dist/esm/api/index.d.cts
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
import { MessagePort } from 'node:worker_threads';
|
||||
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
|
||||
|
||||
type ScopedImport = (specifier: string, parent: string) => Promise<any>;
|
||||
|
||||
type TsconfigOptions = false | string;
|
||||
type InitializationOptions = {
|
||||
namespace?: string;
|
||||
port?: MessagePort;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
type RegisterOptions = {
|
||||
namespace?: string;
|
||||
onImport?: (url: string) => void;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
type Unregister = () => Promise<void>;
|
||||
type NamespacedUnregister = Unregister & {
|
||||
import: ScopedImport;
|
||||
unregister: Unregister;
|
||||
};
|
||||
type Register = {
|
||||
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
|
||||
(options?: RegisterOptions): Unregister;
|
||||
};
|
||||
declare const register: Register;
|
||||
|
||||
type Options = {
|
||||
parentURL: string;
|
||||
onImport?: (url: string) => void;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
declare const tsImport: (specifier: string, options: string | Options) => Promise<any>;
|
||||
|
||||
export { type InitializationOptions, type NamespacedUnregister, type Register, type RegisterOptions, type ScopedImport, type Unregister, register, tsImport };
|
||||
35
node_modules/tsx/dist/esm/api/index.d.mts
generated
vendored
Normal file
35
node_modules/tsx/dist/esm/api/index.d.mts
generated
vendored
Normal file
@@ -0,0 +1,35 @@
|
||||
import { MessagePort } from 'node:worker_threads';
|
||||
import { R as RequiredProperty } from '../../types-Cxp8y2TL.js';
|
||||
|
||||
type ScopedImport = (specifier: string, parent: string) => Promise<any>;
|
||||
|
||||
type TsconfigOptions = false | string;
|
||||
type InitializationOptions = {
|
||||
namespace?: string;
|
||||
port?: MessagePort;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
type RegisterOptions = {
|
||||
namespace?: string;
|
||||
onImport?: (url: string) => void;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
type Unregister = () => Promise<void>;
|
||||
type NamespacedUnregister = Unregister & {
|
||||
import: ScopedImport;
|
||||
unregister: Unregister;
|
||||
};
|
||||
type Register = {
|
||||
(options: RequiredProperty<RegisterOptions, 'namespace'>): NamespacedUnregister;
|
||||
(options?: RegisterOptions): Unregister;
|
||||
};
|
||||
declare const register: Register;
|
||||
|
||||
type Options = {
|
||||
parentURL: string;
|
||||
onImport?: (url: string) => void;
|
||||
tsconfig?: TsconfigOptions;
|
||||
};
|
||||
declare const tsImport: (specifier: string, options: string | Options) => Promise<any>;
|
||||
|
||||
export { type InitializationOptions, type NamespacedUnregister, type Register, type RegisterOptions, type ScopedImport, type Unregister, register, tsImport };
|
||||
1
node_modules/tsx/dist/esm/api/index.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/esm/api/index.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var s=Object.defineProperty;var i=(r,t)=>s(r,"name",{value:t,configurable:!0});import{r as p}from"../../register-B7jrtLTO.mjs";import"../../get-pipe-path-BHW2eJdv.mjs";import{r as n,i as c,c as u}from"../../register-CFH5oNdT.mjs";import"../../require-DQxpCAr4.mjs";import{i as g,e as d}from"../../node-features-_8ZFwP_x.mjs";import"node:module";import"node:worker_threads";import"node:url";import"module";import"node:path";import"../../temporary-directory-CwHp0_NW.mjs";import"node:os";import"get-tsconfig";import"node:fs";import"../../index-7AaEi15b.mjs";import"esbuild";import"node:crypto";import"../../client-BQVF1NaW.mjs";import"node:net";import"node:util";import"../../index-gbaejti9.mjs";const f=i((r,t)=>{if(!t||typeof t=="object"&&!t.parentURL)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const e=typeof t=="string",o=e?t:t.parentURL,m=Date.now().toString(),a=n({namespace:m});return!g(d)&&!c.test(r)&&u.test(r)?Promise.resolve(a.require(r,o)):p({namespace:m,...e?{}:t}).import(r,o)},"tsImport");export{p as register,f as tsImport};
|
||||
2
node_modules/tsx/dist/esm/index.cjs
generated
vendored
Normal file
2
node_modules/tsx/dist/esm/index.cjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
2
node_modules/tsx/dist/esm/index.mjs
generated
vendored
Normal file
2
node_modules/tsx/dist/esm/index.mjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
1
node_modules/tsx/dist/get-pipe-path-BHW2eJdv.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/get-pipe-path-BHW2eJdv.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var p=Object.defineProperty;var e=(t,r)=>p(t,"name",{value:r,configurable:!0});import{createRequire as o}from"module";import a from"node:path";import{t as s}from"./temporary-directory-CwHp0_NW.mjs";var m=o(import.meta.url);const i=process.platform==="win32",n=e(t=>{const r=a.join(s,`${t}.pipe`);return i?`\\\\?\\pipe\\${r}`:r},"getPipePath");export{n as g,i,m as r};
|
||||
1
node_modules/tsx/dist/get-pipe-path-BoR10qr8.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/get-pipe-path-BoR10qr8.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var u=Object.defineProperty;var t=(r,e)=>u(r,"name",{value:e,configurable:!0});var d=require("module"),n=require("node:path"),p=require("./temporary-directory-B83uKxJF.cjs"),s=typeof document<"u"?document.currentScript:null,o=require;const i=process.platform==="win32",c=t(r=>{const e=n.join(p.tmpdir,`${r}.pipe`);return i?`\\\\?\\pipe\\${e}`:e},"getPipePath");exports.getPipePath=c,exports.isWindows=i,exports.require=o;
|
||||
14
node_modules/tsx/dist/index-7AaEi15b.mjs
generated
vendored
Normal file
14
node_modules/tsx/dist/index-7AaEi15b.mjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
1
node_modules/tsx/dist/index-BWFBUo6r.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/index-BWFBUo6r.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var b=Object.defineProperty;var p=(s,l)=>b(s,"name",{value:l,configurable:!0});let t=!0;const n=typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{};let r=0;if(n.process&&n.process.env&&n.process.stdout){const{FORCE_COLOR:s,NODE_DISABLE_COLORS:l,NO_COLOR:c,TERM:o,COLORTERM:i}=n.process.env;l||c||s==="0"?t=!1:s==="1"||s==="2"||s==="3"?t=!0:o==="dumb"?t=!1:"CI"in n.process.env&&["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE","DRONE"].some(g=>g in n.process.env)?t=!0:t=process.stdout.isTTY,t&&(process.platform==="win32"||i&&(i==="truecolor"||i==="24bit")?r=3:o&&(o.endsWith("-256color")||o.endsWith("256"))?r=2:r=1)}let a={enabled:t,supportLevel:r};function e(s,l,c=1){const o=`\x1B[${s}m`,i=`\x1B[${l}m`,g=new RegExp(`\\x1b\\[${l}m`,"g");return f=>a.enabled&&a.supportLevel>=c?o+(""+f).replace(g,o)+i:""+f}p(e,"kolorist");const u=e(30,39),d=e(33,39),O=e(90,39),C=e(92,39),L=e(95,39),R=e(96,39),y=e(44,49),I=e(100,49),h=e(103,49);exports.bgBlue=y,exports.bgGray=I,exports.bgLightYellow=h,exports.black=u,exports.gray=O,exports.lightCyan=R,exports.lightGreen=C,exports.lightMagenta=L,exports.options=a,exports.yellow=d;
|
||||
1
node_modules/tsx/dist/index-gbaejti9.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/index-gbaejti9.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var u=Object.defineProperty;var g=(s,n)=>u(s,"name",{value:n,configurable:!0});let t=!0;const l=typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{};let i=0;if(l.process&&l.process.env&&l.process.stdout){const{FORCE_COLOR:s,NODE_DISABLE_COLORS:n,NO_COLOR:r,TERM:o,COLORTERM:c}=l.process.env;n||r||s==="0"?t=!1:s==="1"||s==="2"||s==="3"?t=!0:o==="dumb"?t=!1:"CI"in l.process.env&&["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE","DRONE"].some(a=>a in l.process.env)?t=!0:t=process.stdout.isTTY,t&&(process.platform==="win32"||c&&(c==="truecolor"||c==="24bit")?i=3:o&&(o.endsWith("-256color")||o.endsWith("256"))?i=2:i=1)}let f={enabled:t,supportLevel:i};function e(s,n,r=1){const o=`\x1B[${s}m`,c=`\x1B[${n}m`,a=new RegExp(`\\x1b\\[${n}m`,"g");return p=>f.enabled&&f.supportLevel>=r?o+(""+p).replace(a,o)+c:""+p}g(e,"kolorist");const b=e(30,39),d=e(33,39),O=e(90,39),C=e(92,39),R=e(95,39),I=e(96,39),L=e(44,49),E=e(100,49),T=e(103,49);export{b as a,T as b,L as c,E as d,R as e,C as f,O as g,I as l,f as o,d as y};
|
||||
14
node_modules/tsx/dist/index-gckBtVBf.cjs
generated
vendored
Normal file
14
node_modules/tsx/dist/index-gckBtVBf.cjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
3
node_modules/tsx/dist/lexer-DQCqS3nf.mjs
generated
vendored
Normal file
3
node_modules/tsx/dist/lexer-DQCqS3nf.mjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
3
node_modules/tsx/dist/lexer-DgIbo0BU.cjs
generated
vendored
Normal file
3
node_modules/tsx/dist/lexer-DgIbo0BU.cjs
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
1
node_modules/tsx/dist/loader.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/loader.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var q=Object.defineProperty;var r=(i,u)=>q(i,"name",{value:u,configurable:!0});var t=require("./get-pipe-path-BoR10qr8.cjs"),e=require("./esm/index.cjs");require("module"),require("node:path"),require("./temporary-directory-B83uKxJF.cjs"),require("node:os"),require("node:worker_threads"),require("./node-features-roYmp9jK.cjs"),require("./register-2sWVXuRQ.cjs"),require("node:module"),require("./register-D46fvsV_.cjs"),require("node:url"),require("get-tsconfig"),require("node:fs"),require("./index-gckBtVBf.cjs"),require("esbuild"),require("node:crypto"),require("./client-D6NvIMSC.cjs"),require("node:net"),require("node:util"),require("./index-BWFBUo6r.cjs"),require("./require-D4F1Lv60.cjs"),require("node:fs/promises"),t.require("./cjs/index.cjs"),exports.globalPreload=e.globalPreload,exports.initialize=e.initialize,Object.defineProperty(exports,"load",{enumerable:!0,get:r(function(){return e.load},"get")}),Object.defineProperty(exports,"resolve",{enumerable:!0,get:r(function(){return e.resolve},"get")});
|
||||
1
node_modules/tsx/dist/loader.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/loader.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
import{r}from"./get-pipe-path-BHW2eJdv.mjs";import{globalPreload as w,initialize as y,load as A,resolve as B}from"./esm/index.mjs";import"module";import"node:path";import"./temporary-directory-CwHp0_NW.mjs";import"node:os";import"node:worker_threads";import"./node-features-_8ZFwP_x.mjs";import"./register-B7jrtLTO.mjs";import"node:module";import"./register-CFH5oNdT.mjs";import"node:url";import"get-tsconfig";import"node:fs";import"./index-7AaEi15b.mjs";import"esbuild";import"node:crypto";import"./client-BQVF1NaW.mjs";import"node:net";import"node:util";import"./index-gbaejti9.mjs";import"./require-DQxpCAr4.mjs";import"node:fs/promises";r("./cjs/index.cjs");export{w as globalPreload,y as initialize,A as load,B as resolve};
|
||||
1
node_modules/tsx/dist/node-features-_8ZFwP_x.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/node-features-_8ZFwP_x.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var i=Object.defineProperty;var o=(e,t)=>i(e,"name",{value:t,configurable:!0});const n=o((e,t)=>{const r=e[0]-t[0];if(r===0){const s=e[1]-t[1];return s===0?e[2]>=t[2]:s>0}return r>0},"isVersionGreaterOrEqual"),a=process.versions.node.split(".").map(Number),u=o((e,t=a)=>{for(let r=0;r<e.length;r+=1){const s=e[r];if(r===e.length-1||t[0]===s[0])return n(t,s)}return!1},"isFeatureSupported"),c=[[18,19,0],[20,6,0]],f=[[18,19,0],[20,10,0],[21,0,0]],l=[[21,0,0]],m=[[20,11,0],[21,3,0]];export{f as a,m as e,u as i,c as m,l as t};
|
||||
1
node_modules/tsx/dist/node-features-roYmp9jK.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/node-features-roYmp9jK.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var i=Object.defineProperty;var s=(e,t)=>i(e,"name",{value:t,configurable:!0});const n=s((e,t)=>{const r=e[0]-t[0];if(r===0){const o=e[1]-t[1];return o===0?e[2]>=t[2]:o>0}return r>0},"isVersionGreaterOrEqual"),u=process.versions.node.split(".").map(Number),l=s((e,t=u)=>{for(let r=0;r<e.length;r+=1){const o=e[r];if(r===e.length-1||t[0]===o[0])return n(t,o)}return!1},"isFeatureSupported"),a=[[18,19,0],[20,6,0]],c=[[18,19,0],[20,10,0],[21,0,0]],d=[[21,0,0]],f=[[20,11,0],[21,3,0]];exports.esmLoadReadFile=f,exports.importAttributes=c,exports.isFeatureSupported=l,exports.moduleRegister=a,exports.testRunnerGlob=d;
|
||||
1
node_modules/tsx/dist/package-BTMRuUqB.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/package-BTMRuUqB.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var r="4.20.3";exports.version=r;
|
||||
1
node_modules/tsx/dist/package-BgRDTLo0.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/package-BgRDTLo0.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var r="4.20.3";export{r as v};
|
||||
1
node_modules/tsx/dist/patch-repl.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/patch-repl.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var i=Object.defineProperty;var a=(r,t)=>i(r,"name",{value:t,configurable:!0});var n=require("node:repl"),u=require("esbuild");const f=a(r=>{const{eval:t}=r,c=a(async function(e,l,s,o){try{e=(await u.transform(e,{sourcefile:s,loader:"ts",tsconfigRaw:{compilerOptions:{preserveValueImports:!0}},define:{require:"global.require"}})).code}catch{}return t.call(this,e,l,s,o)},"preEval");r.eval=c},"patchEval"),{start:p}=n;n.start=function(){const r=Reflect.apply(p,this,arguments);return f(r),r};
|
||||
1
node_modules/tsx/dist/patch-repl.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/patch-repl.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var i=Object.defineProperty;var a=(t,r)=>i(t,"name",{value:r,configurable:!0});import s from"node:repl";import{transform as f}from"esbuild";const p=a(t=>{const{eval:r}=t,n=a(async function(e,c,o,l){try{e=(await f(e,{sourcefile:o,loader:"ts",tsconfigRaw:{compilerOptions:{preserveValueImports:!0}},define:{require:"global.require"}})).code}catch{}return r.call(this,e,c,o,l)},"preEval");t.eval=n},"patchEval"),{start:u}=s;s.start=function(){const t=Reflect.apply(u,this,arguments);return p(t),t};
|
||||
1
node_modules/tsx/dist/preflight.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/preflight.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var u=Object.defineProperty;var t=(e,n)=>u(e,"name",{value:n,configurable:!0});var a=require("./get-pipe-path-BoR10qr8.cjs"),l=require("node:os"),f=require("node:worker_threads"),p=require("./client-D6NvIMSC.cjs");require("./suppress-warnings.cjs"),require("module"),require("node:path"),require("./temporary-directory-B83uKxJF.cjs"),require("node:net");const d=t((e,n)=>{for(const r of e)process.on(r,s=>{n(s),process.listenerCount(r)===0&&process.exit(128+l.constants.signals[r])});const{listenerCount:i,listeners:o}=process;process.listenerCount=function(r){let s=Reflect.apply(i,this,arguments);return e.includes(r)&&(s-=1),s},process.listeners=function(r){const s=Reflect.apply(o,this,arguments);return e.includes(r)?s.filter(c=>c!==n):s}},"bindHiddenSignalsHandler");f.isMainThread&&(a.require("./cjs/index.cjs"),(async()=>{const e=await p.connectingToServer;e&&d(["SIGINT","SIGTERM"],n=>{e({type:"signal",signal:n})})})());
|
||||
1
node_modules/tsx/dist/preflight.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/preflight.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var p=Object.defineProperty;var n=(t,s)=>p(t,"name",{value:s,configurable:!0});import{r as f}from"./get-pipe-path-BHW2eJdv.mjs";import{constants as l}from"node:os";import{isMainThread as a}from"node:worker_threads";import{c as m}from"./client-BQVF1NaW.mjs";import"./suppress-warnings.mjs";import"module";import"node:path";import"./temporary-directory-CwHp0_NW.mjs";import"node:net";const u=n((t,s)=>{for(const e of t)process.on(e,r=>{s(r),process.listenerCount(e)===0&&process.exit(128+l.signals[e])});const{listenerCount:i,listeners:o}=process;process.listenerCount=function(e){let r=Reflect.apply(i,this,arguments);return t.includes(e)&&(r-=1),r},process.listeners=function(e){const r=Reflect.apply(o,this,arguments);return t.includes(e)?r.filter(c=>c!==s):r}},"bindHiddenSignalsHandler");a&&(f("./cjs/index.cjs"),(async()=>{const t=await m;t&&u(["SIGINT","SIGTERM"],s=>{t({type:"signal",signal:s})})})());
|
||||
1
node_modules/tsx/dist/register-2sWVXuRQ.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/register-2sWVXuRQ.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var g=Object.defineProperty;var o=(r,s)=>g(r,"name",{value:s,configurable:!0});var p=require("node:module"),v=require("node:worker_threads"),f=require("./register-D46fvsV_.cjs"),h=require("node:url"),m=typeof document<"u"?document.currentScript:null;const w=o(r=>(s,e)=>{if(!e)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const n=e.startsWith(f.fileUrlPrefix)?e:h.pathToFileURL(e).toString();return import(`tsx://${JSON.stringify({specifier:s,parentURL:n,namespace:r})}`)},"createScopedImport");let l=!1;const _=o(r=>{if(!p.register)throw new Error(`This version of Node.js (${process.version}) does not support module.register(). Please upgrade to Node v18.19 or v20.6 and above.`);if(!l){const{_resolveFilename:t}=p;p._resolveFilename=(c,...u)=>t(f.interopCjsExports(c),...u),l=!0}const{sourceMapsEnabled:s}=process;process.setSourceMapsEnabled(!0);const{port1:e,port2:n}=new v.MessageChannel;p.register(`./esm/index.mjs?${Date.now()}`,{parentURL:typeof document>"u"?require("url").pathToFileURL(__filename).href:m&&m.src||new URL("register-2sWVXuRQ.cjs",document.baseURI).href,data:{port:n,namespace:r?.namespace,tsconfig:r?.tsconfig},transferList:[n]});const d=r?.onImport,a=d&&(t=>{t.type==="load"&&d(t.url)});a&&(e.on("message",a),e.unref());const i=o(()=>(s===!1&&process.setSourceMapsEnabled(!1),a&&e.off("message",a),e.postMessage("deactivate"),new Promise(t=>{const c=o(u=>{u.type==="deactivated"&&(t(),e.off("message",c))},"onDeactivated");e.on("message",c)})),"unregister");return r?.namespace&&(i.import=w(r.namespace),i.unregister=i),i},"register");exports.register=_;
|
||||
1
node_modules/tsx/dist/register-B7jrtLTO.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/register-B7jrtLTO.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var d=Object.defineProperty;var o=(r,s)=>d(r,"name",{value:s,configurable:!0});import m from"node:module";import{MessageChannel as u}from"node:worker_threads";import{f as g,a as v}from"./register-CFH5oNdT.mjs";import{pathToFileURL as h}from"node:url";const w=o(r=>(s,e)=>{if(!e)throw new Error("The current file path (import.meta.url) must be provided in the second argument of tsImport()");const a=e.startsWith(g)?e:h(e).toString();return import(`tsx://${JSON.stringify({specifier:s,parentURL:a,namespace:r})}`)},"createScopedImport");let l=!1;const E=o(r=>{if(!m.register)throw new Error(`This version of Node.js (${process.version}) does not support module.register(). Please upgrade to Node v18.19 or v20.6 and above.`);if(!l){const{_resolveFilename:t}=m;m._resolveFilename=(p,...c)=>t(v(p),...c),l=!0}const{sourceMapsEnabled:s}=process;process.setSourceMapsEnabled(!0);const{port1:e,port2:a}=new u;m.register(`./esm/index.mjs?${Date.now()}`,{parentURL:import.meta.url,data:{port:a,namespace:r?.namespace,tsconfig:r?.tsconfig},transferList:[a]});const f=r?.onImport,n=f&&(t=>{t.type==="load"&&f(t.url)});n&&(e.on("message",n),e.unref());const i=o(()=>(s===!1&&process.setSourceMapsEnabled(!1),n&&e.off("message",n),e.postMessage("deactivate"),new Promise(t=>{const p=o(c=>{c.type==="deactivated"&&(t(),e.off("message",p))},"onDeactivated");e.on("message",p)})),"unregister");return r?.namespace&&(i.import=w(r.namespace),i.unregister=i),i},"register");export{E as r};
|
||||
4
node_modules/tsx/dist/register-CFH5oNdT.mjs
generated
vendored
Normal file
4
node_modules/tsx/dist/register-CFH5oNdT.mjs
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
var K=Object.defineProperty;var o=(s,e)=>K(s,"name",{value:e,configurable:!0});import{r as Y}from"./get-pipe-path-BHW2eJdv.mjs";import d from"node:module";import p from"node:path";import{fileURLToPath as O}from"node:url";import{parseTsconfig as V,getTsconfig as Z,createFilesMatcher as q,createPathsMatcher as ee}from"get-tsconfig";import se,{writeSync as te}from"node:fs";import{b as ne,i as ae,a as re}from"./index-7AaEi15b.mjs";import{p as U}from"./client-BQVF1NaW.mjs";import{inspect as oe}from"node:util";import{b as ce,a as ie,c as le,d as fe,o as W}from"./index-gbaejti9.mjs";const R=o(s=>{if(!s.startsWith("data:text/javascript,"))return;const e=s.indexOf("?");if(e===-1)return;const n=new URLSearchParams(s.slice(e+1)).get("filePath");if(n)return n},"getOriginalFilePath"),D=o(s=>{const e=R(s);return e&&(d._cache[e]=d._cache[s],delete d._cache[s],s=e),s},"interopCjsExports"),me=o(s=>{const e=s.indexOf(":");if(e!==-1)return s.slice(0,e)},"getScheme"),N=o(s=>s[0]==="."&&(s[1]==="/"||s[1]==="."||s[2]==="/"),"isRelativePath"),j=o(s=>N(s)||p.isAbsolute(s),"isFilePath"),pe=o(s=>{if(j(s))return!0;const e=me(s);return e&&e!=="node"},"requestAcceptsQuery"),y="file://",he=[".ts",".tsx",".jsx",".mts",".cts"],C=/\.([cm]?ts|[tj]sx)($|\?)/,de=/[/\\].+\.(?:cts|cjs)(?:$|\?)/,ue=/\.json($|\?)/,E=/\/(?:$|\?)/,ge=/^(?:@[^/]+\/)?[^/\\]+$/,Q=`${p.sep}node_modules${p.sep}`;let M,_,S=!1;const A=o(s=>{let e=null;if(s){const a=p.resolve(s);e={path:a,config:V(a)}}else{try{e=Z()}catch{}if(!e)return}M=q(e),_=ee(e),S=e?.config.compilerOptions?.allowJs??!1},"loadTsconfig"),T=o(s=>Array.from(s).length>0?`?${s.toString()}`:"","urlSearchParamsStringify"),Pe=`
|
||||
//# sourceMappingURL=data:application/json;base64,`,I=o(()=>process.sourceMapsEnabled??!0,"shouldApplySourceMap"),F=o(({code:s,map:e})=>s+Pe+Buffer.from(JSON.stringify(e),"utf8").toString("base64"),"inlineSourceMap"),v=Number(process.env.TSX_DEBUG);v&&(W.enabled=!0,W.supportLevel=3);const J=o(s=>(e,...a)=>{if(!v||e>v)return;const n=`${fe(` tsx P${process.pid} `)} ${s}`,t=a.map(r=>typeof r=="string"?r:oe(r,{colors:!0})).join(" ");te(1,`${n} ${t}
|
||||
`)},"createLog"),P=J(ce(ie(" CJS "))),je=J(le(" ESM ")),be=[".cts",".mts",".ts",".tsx",".jsx"],xe=[".js",".cjs",".mjs"],k=[".ts",".tsx",".jsx"],$=o((s,e,a,n)=>{const t=Object.getOwnPropertyDescriptor(s,e);t?.set?s[e]=a:(!t||t.configurable)&&Object.defineProperty(s,e,{value:a,enumerable:t?.enumerable||n?.enumerable,writable:n?.writable??(t?t.writable:!0),configurable:n?.configurable??(t?t.configurable:!0)})},"safeSet"),ye=o((s,e,a)=>{const n=e[".js"],t=o((r,c)=>{if(s.enabled===!1)return n(r,c);const[i,f]=c.split("?");if((new URLSearchParams(f).get("namespace")??void 0)!==a)return n(r,c);P(2,"load",{filePath:c}),r.id.startsWith("data:text/javascript,")&&(r.path=p.dirname(i)),U?.send&&U.send({type:"dependency",path:i});const u=be.some(m=>i.endsWith(m)),g=xe.some(m=>i.endsWith(m));if(!u&&!g)return n(r,i);let h=se.readFileSync(i,"utf8");if(i.endsWith(".cjs")){const m=ne(c,h);m&&(h=I()?F(m):m.code)}else if(u||ae(h)){const m=re(h,c,{tsconfigRaw:M?.(i)});h=I()?F(m):m.code}P(1,"loaded",{filePath:i}),r._compile(h,i)},"transformer");$(e,".js",t);for(const r of k)$(e,r,t,{enumerable:!a,writable:!0,configurable:!0});return $(e,".mjs",t,{writable:!0,configurable:!0}),()=>{e[".js"]===t&&(e[".js"]=n);for(const r of[...k,".mjs"])e[r]===t&&delete e[r]}},"createExtensions"),Ee=o(s=>e=>{if((e==="."||e===".."||e.endsWith("/.."))&&(e+="/"),E.test(e)){let a=p.join(e,"index.js");e.startsWith("./")&&(a=`./${a}`);try{return s(a)}catch{}}try{return s(e)}catch(a){const n=a;if(n.code==="MODULE_NOT_FOUND")try{return s(`${e}${p.sep}index.js`)}catch{}throw n}},"createImplicitResolver"),B=[".js",".json"],G=[".ts",".tsx",".jsx"],_e=[...G,...B],Se=[...B,...G],b=Object.create(null);b[".js"]=[".ts",".tsx",".js",".jsx"],b[".jsx"]=[".tsx",".ts",".jsx",".js"],b[".cjs"]=[".cts"],b[".mjs"]=[".mts"];const X=o(s=>{const e=s.split("?"),a=e[1]?`?${e[1]}`:"",[n]=e,t=p.extname(n),r=[],c=b[t];if(c){const f=n.slice(0,-t.length);r.push(...c.map(l=>f+l+a))}const i=!(s.startsWith(y)||j(n))||n.includes(Q)||n.includes("/node_modules/")?Se:_e;return r.push(...i.map(f=>n+f+a)),r},"mapTsExtensions"),w=o((s,e,a)=>{if(P(3,"resolveTsFilename",{request:e,isDirectory:E.test(e),isTsParent:a,allowJs:S}),E.test(e)||!a&&!S)return;const n=X(e);if(n)for(const t of n)try{return s(t)}catch(r){const{code:c}=r;if(c!=="MODULE_NOT_FOUND"&&c!=="ERR_PACKAGE_PATH_NOT_EXPORTED")throw r}},"resolveTsFilename"),ve=o((s,e)=>a=>{if(P(3,"resolveTsFilename",{request:a,isTsParent:e,isFilePath:j(a)}),j(a)){const n=w(s,a,e);if(n)return n}try{return s(a)}catch(n){const t=n;if(t.code==="MODULE_NOT_FOUND"){if(t.path){const c=t.message.match(/^Cannot find module '([^']+)'$/);if(c){const f=c[1],l=w(s,f,e);if(l)return l}const i=t.message.match(/^Cannot find module '([^']+)'. Please verify that the package.json has a valid "main" entry$/);if(i){const f=i[1],l=w(s,f,e);if(l)return l}}const r=w(s,a,e);if(r)return r}throw t}},"createTsExtensionResolver"),z="at cjsPreparseModuleExports (node:internal",we=o(s=>{const e=s.stack.split(`
|
||||
`).slice(1);return e[1].includes(z)||e[2].includes(z)},"isFromCjsLexer"),Me=o((s,e)=>{const a=s.split("?"),n=new URLSearchParams(a[1]);if(e?.filename){const t=R(e.filename);let r;if(t){const f=t.split("?"),l=f[0];r=f[1],e.filename=l,e.path=p.dirname(l),e.paths=d._nodeModulePaths(e.path),d._cache[l]=e}r||(r=e.filename.split("?")[1]);const i=new URLSearchParams(r).get("namespace");i&&n.append("namespace",i)}return[a[0],n,(t,r)=>(p.isAbsolute(t)&&!t.endsWith(".json")&&!t.endsWith(".node")&&!(r===0&&we(new Error))&&(t+=T(n)),t)]},"preserveQuery"),Te=o((s,e,a)=>{if(s.startsWith(y)&&(s=O(s)),_&&!j(s)&&!e?.filename?.includes(Q)){const n=_(s);for(const t of n)try{return a(t)}catch{}}return a(s)},"resolveTsPaths"),Fe=o((s,e,a)=>(n,t,...r)=>{if(s.enabled===!1)return e(n,t,...r);n=D(n);const[c,i,f]=Me(n,t);if((i.get("namespace")??void 0)!==a)return e(n,t,...r);P(2,"resolve",{request:n,parent:t?.filename??t,restOfArgs:r});let l=o(g=>e(g,t,...r),"nextResolveSimple");l=ve(l,!!(a||t?.filename&&C.test(t.filename))),l=Ee(l);const u=f(Te(c,t,l),r.length);return P(1,"resolved",{request:n,parent:t?.filename??t,resolved:u}),u},"createResolveFilename"),H=o((s,e)=>{if(!e)throw new Error("The current file path (__filename or import.meta.url) must be provided in the second argument of tsx.require()");return s.startsWith(".")?((typeof e=="string"&&e.startsWith(y)||e instanceof URL)&&(e=O(e)),p.resolve(p.dirname(e),s)):s},"resolveContext"),$e=o(s=>{const{sourceMapsEnabled:e}=process,a={enabled:!0};A(process.env.TSX_TSCONFIG_PATH),process.setSourceMapsEnabled(!0);const n=d._resolveFilename,t=Fe(a,n,s?.namespace);d._resolveFilename=t;const r=ye(a,d._extensions,s?.namespace),c=o(()=>{e===!1&&process.setSourceMapsEnabled(!1),a.enabled=!1,d._resolveFilename===t&&(d._resolveFilename=n),r()},"unregister");if(s?.namespace){const i=o((l,u)=>{const g=H(l,u),[h,m]=g.split("?"),x=new URLSearchParams(m);return s.namespace&&!h.startsWith("node:")&&x.set("namespace",s.namespace),Y(h+T(x))},"scopedRequire");c.require=i;const f=o((l,u,g)=>{const h=H(l,u),[m,x]=h.split("?"),L=new URLSearchParams(x);return s.namespace&&!m.startsWith("node:")&&L.set("namespace",s.namespace),t(m+T(L),module,!1,g)},"scopedResolve");c.resolve=f,c.unregister=c}return c},"register");export{D as a,ue as b,de as c,je as d,C as e,y as f,M as g,F as h,ge as i,v as j,pe as k,A as l,_ as m,E as n,X as o,N as p,S as q,$e as r,he as t};
|
||||
4
node_modules/tsx/dist/register-D46fvsV_.cjs
generated
vendored
Normal file
4
node_modules/tsx/dist/register-D46fvsV_.cjs
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
"use strict";var K=Object.defineProperty;var o=(s,e)=>K(s,"name",{value:e,configurable:!0});var Y=require("./get-pipe-path-BoR10qr8.cjs"),u=require("node:module"),m=require("node:path"),L=require("node:url"),b=require("get-tsconfig"),O=require("node:fs"),w=require("./index-gckBtVBf.cjs"),R=require("./client-D6NvIMSC.cjs"),V=require("node:util"),g=require("./index-BWFBUo6r.cjs");const W=o(s=>{if(!s.startsWith("data:text/javascript,"))return;const e=s.indexOf("?");if(e===-1)return;const n=new URLSearchParams(s.slice(e+1)).get("filePath");if(n)return n},"getOriginalFilePath"),D=o(s=>{const e=W(s);return e&&(u._cache[e]=u._cache[s],delete u._cache[s],s=e),s},"interopCjsExports"),Z=o(s=>{const e=s.indexOf(":");if(e!==-1)return s.slice(0,e)},"getScheme"),N=o(s=>s[0]==="."&&(s[1]==="/"||s[1]==="."||s[2]==="/"),"isRelativePath"),j=o(s=>N(s)||m.isAbsolute(s),"isFilePath"),q=o(s=>{if(j(s))return!0;const e=Z(s);return e&&e!=="node"},"requestAcceptsQuery"),v="file://",ee=[".ts",".tsx",".jsx",".mts",".cts"],C=/\.([cm]?ts|[tj]sx)($|\?)/,se=/[/\\].+\.(?:cts|cjs)(?:$|\?)/,te=/\.json($|\?)/,_=/\/(?:$|\?)/,ne=/^(?:@[^/]+\/)?[^/\\]+$/,J=`${m.sep}node_modules${m.sep}`;exports.fileMatcher=void 0,exports.tsconfigPathsMatcher=void 0,exports.allowJs=!1;const Q=o(s=>{let e=null;if(s){const r=m.resolve(s);e={path:r,config:b.parseTsconfig(r)}}else{try{e=b.getTsconfig()}catch{}if(!e)return}exports.fileMatcher=b.createFilesMatcher(e),exports.tsconfigPathsMatcher=b.createPathsMatcher(e),exports.allowJs=e?.config.compilerOptions?.allowJs??!1},"loadTsconfig"),T=o(s=>Array.from(s).length>0?`?${s.toString()}`:"","urlSearchParamsStringify"),re=`
|
||||
//# sourceMappingURL=data:application/json;base64,`,A=o(()=>process.sourceMapsEnabled??!0,"shouldApplySourceMap"),$=o(({code:s,map:e})=>s+re+Buffer.from(JSON.stringify(e),"utf8").toString("base64"),"inlineSourceMap"),M=Number(process.env.TSX_DEBUG);M&&(g.options.enabled=!0,g.options.supportLevel=3);const I=o(s=>(e,...r)=>{if(!M||e>M)return;const n=`${g.bgGray(` tsx P${process.pid} `)} ${s}`,t=r.map(a=>typeof a=="string"?a:V.inspect(a,{colors:!0})).join(" ");O.writeSync(1,`${n} ${t}
|
||||
`)},"createLog"),x=I(g.bgLightYellow(g.black(" CJS "))),ae=I(g.bgBlue(" ESM ")),oe=[".cts",".mts",".ts",".tsx",".jsx"],ie=[".js",".cjs",".mjs"],k=[".ts",".tsx",".jsx"],F=o((s,e,r,n)=>{const t=Object.getOwnPropertyDescriptor(s,e);t?.set?s[e]=r:(!t||t.configurable)&&Object.defineProperty(s,e,{value:r,enumerable:t?.enumerable||n?.enumerable,writable:n?.writable??(t?t.writable:!0),configurable:n?.configurable??(t?t.configurable:!0)})},"safeSet"),ce=o((s,e,r)=>{const n=e[".js"],t=o((a,i)=>{if(s.enabled===!1)return n(a,i);const[c,f]=i.split("?");if((new URLSearchParams(f).get("namespace")??void 0)!==r)return n(a,i);x(2,"load",{filePath:i}),a.id.startsWith("data:text/javascript,")&&(a.path=m.dirname(c)),R.parent?.send&&R.parent.send({type:"dependency",path:c});const p=oe.some(h=>c.endsWith(h)),P=ie.some(h=>c.endsWith(h));if(!p&&!P)return n(a,c);let d=O.readFileSync(c,"utf8");if(c.endsWith(".cjs")){const h=w.transformDynamicImport(i,d);h&&(d=A()?$(h):h.code)}else if(p||w.isESM(d)){const h=w.transformSync(d,i,{tsconfigRaw:exports.fileMatcher?.(c)});d=A()?$(h):h.code}x(1,"loaded",{filePath:c}),a._compile(d,c)},"transformer");F(e,".js",t);for(const a of k)F(e,a,t,{enumerable:!r,writable:!0,configurable:!0});return F(e,".mjs",t,{writable:!0,configurable:!0}),()=>{e[".js"]===t&&(e[".js"]=n);for(const a of[...k,".mjs"])e[a]===t&&delete e[a]}},"createExtensions"),le=o(s=>e=>{if((e==="."||e===".."||e.endsWith("/.."))&&(e+="/"),_.test(e)){let r=m.join(e,"index.js");e.startsWith("./")&&(r=`./${r}`);try{return s(r)}catch{}}try{return s(e)}catch(r){const n=r;if(n.code==="MODULE_NOT_FOUND")try{return s(`${e}${m.sep}index.js`)}catch{}throw n}},"createImplicitResolver"),B=[".js",".json"],G=[".ts",".tsx",".jsx"],fe=[...G,...B],he=[...B,...G],y=Object.create(null);y[".js"]=[".ts",".tsx",".js",".jsx"],y[".jsx"]=[".tsx",".ts",".jsx",".js"],y[".cjs"]=[".cts"],y[".mjs"]=[".mts"];const X=o(s=>{const e=s.split("?"),r=e[1]?`?${e[1]}`:"",[n]=e,t=m.extname(n),a=[],i=y[t];if(i){const f=n.slice(0,-t.length);a.push(...i.map(l=>f+l+r))}const c=!(s.startsWith(v)||j(n))||n.includes(J)||n.includes("/node_modules/")?he:fe;return a.push(...c.map(f=>n+f+r)),a},"mapTsExtensions"),S=o((s,e,r)=>{if(x(3,"resolveTsFilename",{request:e,isDirectory:_.test(e),isTsParent:r,allowJs:exports.allowJs}),_.test(e)||!r&&!exports.allowJs)return;const n=X(e);if(n)for(const t of n)try{return s(t)}catch(a){const{code:i}=a;if(i!=="MODULE_NOT_FOUND"&&i!=="ERR_PACKAGE_PATH_NOT_EXPORTED")throw a}},"resolveTsFilename"),me=o((s,e)=>r=>{if(x(3,"resolveTsFilename",{request:r,isTsParent:e,isFilePath:j(r)}),j(r)){const n=S(s,r,e);if(n)return n}try{return s(r)}catch(n){const t=n;if(t.code==="MODULE_NOT_FOUND"){if(t.path){const i=t.message.match(/^Cannot find module '([^']+)'$/);if(i){const f=i[1],l=S(s,f,e);if(l)return l}const c=t.message.match(/^Cannot find module '([^']+)'. Please verify that the package.json has a valid "main" entry$/);if(c){const f=c[1],l=S(s,f,e);if(l)return l}}const a=S(s,r,e);if(a)return a}throw t}},"createTsExtensionResolver"),z="at cjsPreparseModuleExports (node:internal",de=o(s=>{const e=s.stack.split(`
|
||||
`).slice(1);return e[1].includes(z)||e[2].includes(z)},"isFromCjsLexer"),ue=o((s,e)=>{const r=s.split("?"),n=new URLSearchParams(r[1]);if(e?.filename){const t=W(e.filename);let a;if(t){const f=t.split("?"),l=f[0];a=f[1],e.filename=l,e.path=m.dirname(l),e.paths=u._nodeModulePaths(e.path),u._cache[l]=e}a||(a=e.filename.split("?")[1]);const c=new URLSearchParams(a).get("namespace");c&&n.append("namespace",c)}return[r[0],n,(t,a)=>(m.isAbsolute(t)&&!t.endsWith(".json")&&!t.endsWith(".node")&&!(a===0&&de(new Error))&&(t+=T(n)),t)]},"preserveQuery"),pe=o((s,e,r)=>{if(s.startsWith(v)&&(s=L.fileURLToPath(s)),exports.tsconfigPathsMatcher&&!j(s)&&!e?.filename?.includes(J)){const n=exports.tsconfigPathsMatcher(s);for(const t of n)try{return r(t)}catch{}}return r(s)},"resolveTsPaths"),Pe=o((s,e,r)=>(n,t,...a)=>{if(s.enabled===!1)return e(n,t,...a);n=D(n);const[i,c,f]=ue(n,t);if((c.get("namespace")??void 0)!==r)return e(n,t,...a);x(2,"resolve",{request:n,parent:t?.filename??t,restOfArgs:a});let l=o(P=>e(P,t,...a),"nextResolveSimple");l=me(l,!!(r||t?.filename&&C.test(t.filename))),l=le(l);const p=f(pe(i,t,l),a.length);return x(1,"resolved",{request:n,parent:t?.filename??t,resolved:p}),p},"createResolveFilename"),H=o((s,e)=>{if(!e)throw new Error("The current file path (__filename or import.meta.url) must be provided in the second argument of tsx.require()");return s.startsWith(".")?((typeof e=="string"&&e.startsWith(v)||e instanceof URL)&&(e=L.fileURLToPath(e)),m.resolve(m.dirname(e),s)):s},"resolveContext"),ge=o(s=>{const{sourceMapsEnabled:e}=process,r={enabled:!0};Q(process.env.TSX_TSCONFIG_PATH),process.setSourceMapsEnabled(!0);const n=u._resolveFilename,t=Pe(r,n,s?.namespace);u._resolveFilename=t;const a=ce(r,u._extensions,s?.namespace),i=o(()=>{e===!1&&process.setSourceMapsEnabled(!1),r.enabled=!1,u._resolveFilename===t&&(u._resolveFilename=n),a()},"unregister");if(s?.namespace){const c=o((l,p)=>{const P=H(l,p),[d,h]=P.split("?"),E=new URLSearchParams(h);return s.namespace&&!d.startsWith("node:")&&E.set("namespace",s.namespace),Y.require(d+T(E))},"scopedRequire");i.require=c;const f=o((l,p,P)=>{const d=H(l,p),[h,E]=d.split("?"),U=new URLSearchParams(E);return s.namespace&&!h.startsWith("node:")&&U.set("namespace",s.namespace),t(h+T(U),module,!1,P)},"scopedResolve");i.resolve=f,i.unregister=i}return i},"register");exports.cjsExtensionPattern=se,exports.debugEnabled=M,exports.fileUrlPrefix=v,exports.inlineSourceMap=$,exports.interopCjsExports=D,exports.isBarePackageNamePattern=ne,exports.isDirectoryPattern=_,exports.isJsonPattern=te,exports.isRelativePath=N,exports.loadTsconfig=Q,exports.logEsm=ae,exports.mapTsExtensions=X,exports.register=ge,exports.requestAcceptsQuery=q,exports.tsExtensions=ee,exports.tsExtensionsPattern=C;
|
||||
3
node_modules/tsx/dist/repl.cjs
generated
vendored
Normal file
3
node_modules/tsx/dist/repl.cjs
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";var c=Object.defineProperty;var s=(e,r)=>c(e,"name",{value:r,configurable:!0});var l=require("node:repl"),u=require("./package-BTMRuUqB.cjs"),q=require("./index-gckBtVBf.cjs");require("node:url"),require("esbuild"),require("node:crypto"),require("node:fs"),require("node:path"),require("node:os"),require("./temporary-directory-B83uKxJF.cjs"),console.log(`Welcome to tsx v${u.version} (Node.js ${process.version}).
|
||||
Type ".help" for more information.`);const t=l.start(),{eval:p}=t,v=s(async function(e,r,o,i){const a=await q.transform(e,o,{loader:"ts",tsconfigRaw:{compilerOptions:{preserveValueImports:!0}},define:{require:"global.require"}}).catch(n=>(console.log(n.message),{code:`
|
||||
`}));return p.call(this,a.code,r,o,i)},"preEval");t.eval=v;
|
||||
3
node_modules/tsx/dist/repl.mjs
generated
vendored
Normal file
3
node_modules/tsx/dist/repl.mjs
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
var m=Object.defineProperty;var t=(o,r)=>m(o,"name",{value:r,configurable:!0});import p from"node:repl";import{v as l}from"./package-BgRDTLo0.mjs";import{t as c}from"./index-7AaEi15b.mjs";import"node:url";import"esbuild";import"node:crypto";import"node:fs";import"node:path";import"node:os";import"./temporary-directory-CwHp0_NW.mjs";console.log(`Welcome to tsx v${l} (Node.js ${process.version}).
|
||||
Type ".help" for more information.`);const s=p.start(),{eval:f}=s,v=t(async function(o,r,e,i){const n=await c(o,e,{loader:"ts",tsconfigRaw:{compilerOptions:{preserveValueImports:!0}},define:{require:"global.require"}}).catch(a=>(console.log(a.message),{code:`
|
||||
`}));return f.call(this,n.code,r,e,i)},"preEval");s.eval=v;
|
||||
1
node_modules/tsx/dist/require-D4F1Lv60.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/require-D4F1Lv60.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var c=Object.defineProperty;var a=(r,t)=>c(r,"name",{value:t,configurable:!0});var s=require("./get-pipe-path-BoR10qr8.cjs"),n=require("./register-D46fvsV_.cjs");let e;const i=a((r,t)=>(e||(e=n.register({namespace:Date.now().toString()})),e.require(r,t)),"tsxRequire"),o=a((r,t,u)=>(e||(e=n.register({namespace:Date.now().toString()})),e.resolve(r,t,u)),"resolve");o.paths=s.require.resolve.paths,i.resolve=o,i.main=s.require.main,i.extensions=s.require.extensions,i.cache=s.require.cache,exports.tsxRequire=i;
|
||||
1
node_modules/tsx/dist/require-DQxpCAr4.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/require-DQxpCAr4.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
var m=Object.defineProperty;var a=(r,t)=>m(r,"name",{value:t,configurable:!0});import{r as o}from"./get-pipe-path-BHW2eJdv.mjs";import{r as n}from"./register-CFH5oNdT.mjs";let e;const s=a((r,t)=>(e||(e=n({namespace:Date.now().toString()})),e.require(r,t)),"tsxRequire"),i=a((r,t,c)=>(e||(e=n({namespace:Date.now().toString()})),e.resolve(r,t,c)),"resolve");i.paths=o.resolve.paths,s.resolve=i,s.main=o.main,s.extensions=o.extensions,s.cache=o.cache;export{s as t};
|
||||
1
node_modules/tsx/dist/suppress-warnings.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/suppress-warnings.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";const a=new Set(["Custom ESM Loaders is an experimental feature. This feature could change at any time","Custom ESM Loaders is an experimental feature and might change at any time","Import assertions are not a stable feature of the JavaScript language. Avoid relying on their current behavior and syntax as those might change in a future version of Node.js."]),{emit:n}=process;process.emit=function(e,t){if(!(e==="warning"&&a.has(t.message)))return Reflect.apply(n,this,arguments)};
|
||||
1
node_modules/tsx/dist/suppress-warnings.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/suppress-warnings.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
const t=new Set(["Custom ESM Loaders is an experimental feature. This feature could change at any time","Custom ESM Loaders is an experimental feature and might change at any time","Import assertions are not a stable feature of the JavaScript language. Avoid relying on their current behavior and syntax as those might change in a future version of Node.js."]),{emit:n}=process;process.emit=function(e,a){if(!(e==="warning"&&t.has(a.message)))return Reflect.apply(n,this,arguments)};
|
||||
1
node_modules/tsx/dist/temporary-directory-B83uKxJF.cjs
generated
vendored
Normal file
1
node_modules/tsx/dist/temporary-directory-B83uKxJF.cjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
"use strict";var s=require("node:path"),r=require("node:os");const{geteuid:e}=process,t=e?e():r.userInfo().username,i=s.join(r.tmpdir(),`tsx-${t}`);exports.tmpdir=i;
|
||||
1
node_modules/tsx/dist/temporary-directory-CwHp0_NW.mjs
generated
vendored
Normal file
1
node_modules/tsx/dist/temporary-directory-CwHp0_NW.mjs
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
import r from"node:path";import o from"node:os";const{geteuid:t}=process,s=t?t():o.userInfo().username,e=r.join(o.tmpdir(),`tsx-${s}`);export{e as t};
|
||||
5
node_modules/tsx/dist/types-Cxp8y2TL.d.ts
generated
vendored
Normal file
5
node_modules/tsx/dist/types-Cxp8y2TL.d.ts
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
type RequiredProperty<Type, Keys extends keyof Type> = Type & {
|
||||
[P in Keys]-?: Type[P];
|
||||
};
|
||||
|
||||
export type { RequiredProperty as R };
|
||||
68
node_modules/tsx/package.json
generated
vendored
Normal file
68
node_modules/tsx/package.json
generated
vendored
Normal file
@@ -0,0 +1,68 @@
|
||||
{
|
||||
"name": "tsx",
|
||||
"version": "4.20.3",
|
||||
"description": "TypeScript Execute (tsx): Node.js enhanced with esbuild to run TypeScript & ESM files",
|
||||
"keywords": [
|
||||
"cli",
|
||||
"runtime",
|
||||
"node",
|
||||
"cjs",
|
||||
"commonjs",
|
||||
"esm",
|
||||
"typescript",
|
||||
"typescript runner"
|
||||
],
|
||||
"license": "MIT",
|
||||
"repository": "privatenumber/tsx",
|
||||
"author": {
|
||||
"name": "Hiroki Osame",
|
||||
"email": "hiroki.osame@gmail.com"
|
||||
},
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"type": "module",
|
||||
"bin": "./dist/cli.mjs",
|
||||
"exports": {
|
||||
"./package.json": "./package.json",
|
||||
".": "./dist/loader.mjs",
|
||||
"./patch-repl": "./dist/patch-repl.cjs",
|
||||
"./cjs": "./dist/cjs/index.cjs",
|
||||
"./cjs/api": {
|
||||
"import": {
|
||||
"types": "./dist/cjs/api/index.d.mts",
|
||||
"default": "./dist/cjs/api/index.mjs"
|
||||
},
|
||||
"require": {
|
||||
"types": "./dist/cjs/api/index.d.cts",
|
||||
"default": "./dist/cjs/api/index.cjs"
|
||||
}
|
||||
},
|
||||
"./esm": "./dist/esm/index.mjs",
|
||||
"./esm/api": {
|
||||
"import": {
|
||||
"types": "./dist/esm/api/index.d.mts",
|
||||
"default": "./dist/esm/api/index.mjs"
|
||||
},
|
||||
"require": {
|
||||
"types": "./dist/esm/api/index.d.cts",
|
||||
"default": "./dist/esm/api/index.cjs"
|
||||
}
|
||||
},
|
||||
"./cli": "./dist/cli.mjs",
|
||||
"./suppress-warnings": "./dist/suppress-warnings.cjs",
|
||||
"./preflight": "./dist/preflight.cjs",
|
||||
"./repl": "./dist/repl.mjs"
|
||||
},
|
||||
"homepage": "https://tsx.is",
|
||||
"engines": {
|
||||
"node": ">=18.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"esbuild": "~0.25.0",
|
||||
"get-tsconfig": "^4.7.5"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"fsevents": "~2.3.3"
|
||||
}
|
||||
}
|
||||
774
package-lock.json
generated
Normal file
774
package-lock.json
generated
Normal file
@@ -0,0 +1,774 @@
|
||||
{
|
||||
"name": "immich-api-test",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"devDependencies": {
|
||||
"tsx": "^4.20.3"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/aix-ppc64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.6.tgz",
|
||||
"integrity": "sha512-ShbM/3XxwuxjFiuVBHA+d3j5dyac0aEVVq1oluIDf71hUw0aRF59dV/efUsIwFnR6m8JNM2FjZOzmaZ8yG61kw==",
|
||||
"cpu": [
|
||||
"ppc64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"aix"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/android-arm": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.6.tgz",
|
||||
"integrity": "sha512-S8ToEOVfg++AU/bHwdksHNnyLyVM+eMVAOf6yRKFitnwnbwwPNqKr3srzFRe7nzV69RQKb5DgchIX5pt3L53xg==",
|
||||
"cpu": [
|
||||
"arm"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"android"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/android-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-hd5zdUarsK6strW+3Wxi5qWws+rJhCCbMiC9QZyzoxfk5uHRIE8T287giQxzVpEvCwuJ9Qjg6bEjcRJcgfLqoA==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"android"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/android-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-0Z7KpHSr3VBIO9A/1wcT3NTy7EB4oNC4upJ5ye3R7taCc2GUdeynSLArnon5G8scPwaU866d3H4BCrE5xLW25A==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"android"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/darwin-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-FFCssz3XBavjxcFxKsGy2DYK5VSvJqa6y5HXljKzhRZ87LvEi13brPrf/wdyl/BbpbMKJNOr1Sd0jtW4Ge1pAA==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"darwin"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/darwin-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-GfXs5kry/TkGM2vKqK2oyiLFygJRqKVhawu3+DOCk7OxLy/6jYkWXhlHwOoTb0WqGnWGAS7sooxbZowy+pK9Yg==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"darwin"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/freebsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-aoLF2c3OvDn2XDTRvn8hN6DRzVVpDlj2B/F66clWd/FHLiHaG3aVZjxQX2DYphA5y/evbdGvC6Us13tvyt4pWg==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"freebsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/freebsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-2SkqTjTSo2dYi/jzFbU9Plt1vk0+nNg8YC8rOXXea+iA3hfNJWebKYPs3xnOUf9+ZWhKAaxnQNUf2X9LOpeiMQ==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"freebsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-arm": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.6.tgz",
|
||||
"integrity": "sha512-SZHQlzvqv4Du5PrKE2faN0qlbsaW/3QQfUUc6yO2EjFcA83xnwm91UbEEVx4ApZ9Z5oG8Bxz4qPE+HFwtVcfyw==",
|
||||
"cpu": [
|
||||
"arm"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-b967hU0gqKd9Drsh/UuAm21Khpoh6mPBSgz8mKRq4P5mVK8bpA+hQzmm/ZwGVULSNBzKdZPQBRT3+WuVavcWsQ==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-ia32": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.6.tgz",
|
||||
"integrity": "sha512-aHWdQ2AAltRkLPOsKdi3xv0mZ8fUGPdlKEjIEhxCPm5yKEThcUjHpWB1idN74lfXGnZ5SULQSgtr5Qos5B0bPw==",
|
||||
"cpu": [
|
||||
"ia32"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-loong64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.6.tgz",
|
||||
"integrity": "sha512-VgKCsHdXRSQ7E1+QXGdRPlQ/e08bN6WMQb27/TMfV+vPjjTImuT9PmLXupRlC90S1JeNNW5lzkAEO/McKeJ2yg==",
|
||||
"cpu": [
|
||||
"loong64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-mips64el": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.6.tgz",
|
||||
"integrity": "sha512-WViNlpivRKT9/py3kCmkHnn44GkGXVdXfdc4drNmRl15zVQ2+D2uFwdlGh6IuK5AAnGTo2qPB1Djppj+t78rzw==",
|
||||
"cpu": [
|
||||
"mips64el"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-ppc64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.6.tgz",
|
||||
"integrity": "sha512-wyYKZ9NTdmAMb5730I38lBqVu6cKl4ZfYXIs31Baf8aoOtB4xSGi3THmDYt4BTFHk7/EcVixkOV2uZfwU3Q2Jw==",
|
||||
"cpu": [
|
||||
"ppc64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-riscv64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.6.tgz",
|
||||
"integrity": "sha512-KZh7bAGGcrinEj4qzilJ4hqTY3Dg2U82c8bv+e1xqNqZCrCyc+TL9AUEn5WGKDzm3CfC5RODE/qc96OcbIe33w==",
|
||||
"cpu": [
|
||||
"riscv64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-s390x": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.6.tgz",
|
||||
"integrity": "sha512-9N1LsTwAuE9oj6lHMyyAM+ucxGiVnEqUdp4v7IaMmrwb06ZTEVCIs3oPPplVsnjPfyjmxwHxHMF8b6vzUVAUGw==",
|
||||
"cpu": [
|
||||
"s390x"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/linux-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-A6bJB41b4lKFWRKNrWoP2LHsjVzNiaurf7wyj/XtFNTsnPuxwEBWHLty+ZE0dWBKuSK1fvKgrKaNjBS7qbFKig==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"linux"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/netbsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-IjA+DcwoVpjEvyxZddDqBY+uJ2Snc6duLpjmkXm/v4xuS3H+3FkLZlDm9ZsAbF9rsfP3zeA0/ArNDORZgrxR/Q==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"netbsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/netbsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-dUXuZr5WenIDlMHdMkvDc1FAu4xdWixTCRgP7RQLBOkkGgwuuzaGSYcOpW4jFxzpzL1ejb8yF620UxAqnBrR9g==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"netbsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/openbsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-l8ZCvXP0tbTJ3iaqdNf3pjaOSd5ex/e6/omLIQCVBLmHTlfXW3zAxQ4fnDmPLOB1x9xrcSi/xtCWFwCZRIaEwg==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"openbsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/openbsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-hKrmDa0aOFOr71KQ/19JC7az1P0GWtCN1t2ahYAf4O007DHZt/dW8ym5+CUdJhQ/qkZmI1HAF8KkJbEFtCL7gw==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"openbsd"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/openharmony-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-+SqBcAWoB1fYKmpWoQP4pGtx+pUUC//RNYhFdbcSA16617cchuryuhOCRpPsjCblKukAckWsV+aQ3UKT/RMPcA==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"openharmony"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/sunos-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-dyCGxv1/Br7MiSC42qinGL8KkG4kX0pEsdb0+TKhmJZgCUDBGmyo1/ArCjNGiOLiIAgdbWgmWgib4HoCi5t7kA==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"sunos"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/win32-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-42QOgcZeZOvXfsCBJF5Afw73t4veOId//XD3i+/9gSkhSV6Gk3VPlWncctI+JcOyERv85FUo7RxuxGy+z8A43Q==",
|
||||
"cpu": [
|
||||
"arm64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"win32"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/win32-ia32": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.6.tgz",
|
||||
"integrity": "sha512-4AWhgXmDuYN7rJI6ORB+uU9DHLq/erBbuMoAuB4VWJTu5KtCgcKYPynF0YI1VkBNuEfjNlLrFr9KZPJzrtLkrQ==",
|
||||
"cpu": [
|
||||
"ia32"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"win32"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/@esbuild/win32-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-NgJPHHbEpLQgDH2MjQu90pzW/5vvXIZ7KOnPyNBm92A6WgZ/7b6fJyUBjoumLqeOQQGqY2QjQxRo97ah4Sj0cA==",
|
||||
"cpu": [
|
||||
"x64"
|
||||
],
|
||||
"dev": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"win32"
|
||||
],
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
}
|
||||
},
|
||||
"node_modules/esbuild": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.6.tgz",
|
||||
"integrity": "sha512-GVuzuUwtdsghE3ocJ9Bs8PNoF13HNQ5TXbEi2AhvVb8xU1Iwt9Fos9FEamfoee+u/TOsn7GUWc04lz46n2bbTg==",
|
||||
"dev": true,
|
||||
"hasInstallScript": true,
|
||||
"bin": {
|
||||
"esbuild": "bin/esbuild"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"@esbuild/aix-ppc64": "0.25.6",
|
||||
"@esbuild/android-arm": "0.25.6",
|
||||
"@esbuild/android-arm64": "0.25.6",
|
||||
"@esbuild/android-x64": "0.25.6",
|
||||
"@esbuild/darwin-arm64": "0.25.6",
|
||||
"@esbuild/darwin-x64": "0.25.6",
|
||||
"@esbuild/freebsd-arm64": "0.25.6",
|
||||
"@esbuild/freebsd-x64": "0.25.6",
|
||||
"@esbuild/linux-arm": "0.25.6",
|
||||
"@esbuild/linux-arm64": "0.25.6",
|
||||
"@esbuild/linux-ia32": "0.25.6",
|
||||
"@esbuild/linux-loong64": "0.25.6",
|
||||
"@esbuild/linux-mips64el": "0.25.6",
|
||||
"@esbuild/linux-ppc64": "0.25.6",
|
||||
"@esbuild/linux-riscv64": "0.25.6",
|
||||
"@esbuild/linux-s390x": "0.25.6",
|
||||
"@esbuild/linux-x64": "0.25.6",
|
||||
"@esbuild/netbsd-arm64": "0.25.6",
|
||||
"@esbuild/netbsd-x64": "0.25.6",
|
||||
"@esbuild/openbsd-arm64": "0.25.6",
|
||||
"@esbuild/openbsd-x64": "0.25.6",
|
||||
"@esbuild/openharmony-arm64": "0.25.6",
|
||||
"@esbuild/sunos-x64": "0.25.6",
|
||||
"@esbuild/win32-arm64": "0.25.6",
|
||||
"@esbuild/win32-ia32": "0.25.6",
|
||||
"@esbuild/win32-x64": "0.25.6"
|
||||
}
|
||||
},
|
||||
"node_modules/fsevents": {
|
||||
"version": "2.3.3",
|
||||
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
|
||||
"integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
|
||||
"dev": true,
|
||||
"hasInstallScript": true,
|
||||
"optional": true,
|
||||
"os": [
|
||||
"darwin"
|
||||
],
|
||||
"engines": {
|
||||
"node": "^8.16.0 || ^10.6.0 || >=11.0.0"
|
||||
}
|
||||
},
|
||||
"node_modules/get-tsconfig": {
|
||||
"version": "4.10.1",
|
||||
"resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.1.tgz",
|
||||
"integrity": "sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"resolve-pkg-maps": "^1.0.0"
|
||||
},
|
||||
"funding": {
|
||||
"url": "https://github.com/privatenumber/get-tsconfig?sponsor=1"
|
||||
}
|
||||
},
|
||||
"node_modules/resolve-pkg-maps": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz",
|
||||
"integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==",
|
||||
"dev": true,
|
||||
"funding": {
|
||||
"url": "https://github.com/privatenumber/resolve-pkg-maps?sponsor=1"
|
||||
}
|
||||
},
|
||||
"node_modules/tsx": {
|
||||
"version": "4.20.3",
|
||||
"resolved": "https://registry.npmjs.org/tsx/-/tsx-4.20.3.tgz",
|
||||
"integrity": "sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==",
|
||||
"dev": true,
|
||||
"dependencies": {
|
||||
"esbuild": "~0.25.0",
|
||||
"get-tsconfig": "^4.7.5"
|
||||
},
|
||||
"bin": {
|
||||
"tsx": "dist/cli.mjs"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.0.0"
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"fsevents": "~2.3.3"
|
||||
}
|
||||
}
|
||||
},
|
||||
"dependencies": {
|
||||
"@esbuild/aix-ppc64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.6.tgz",
|
||||
"integrity": "sha512-ShbM/3XxwuxjFiuVBHA+d3j5dyac0aEVVq1oluIDf71hUw0aRF59dV/efUsIwFnR6m8JNM2FjZOzmaZ8yG61kw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/android-arm": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.6.tgz",
|
||||
"integrity": "sha512-S8ToEOVfg++AU/bHwdksHNnyLyVM+eMVAOf6yRKFitnwnbwwPNqKr3srzFRe7nzV69RQKb5DgchIX5pt3L53xg==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/android-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-hd5zdUarsK6strW+3Wxi5qWws+rJhCCbMiC9QZyzoxfk5uHRIE8T287giQxzVpEvCwuJ9Qjg6bEjcRJcgfLqoA==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/android-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-0Z7KpHSr3VBIO9A/1wcT3NTy7EB4oNC4upJ5ye3R7taCc2GUdeynSLArnon5G8scPwaU866d3H4BCrE5xLW25A==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/darwin-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-FFCssz3XBavjxcFxKsGy2DYK5VSvJqa6y5HXljKzhRZ87LvEi13brPrf/wdyl/BbpbMKJNOr1Sd0jtW4Ge1pAA==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/darwin-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-GfXs5kry/TkGM2vKqK2oyiLFygJRqKVhawu3+DOCk7OxLy/6jYkWXhlHwOoTb0WqGnWGAS7sooxbZowy+pK9Yg==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/freebsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-aoLF2c3OvDn2XDTRvn8hN6DRzVVpDlj2B/F66clWd/FHLiHaG3aVZjxQX2DYphA5y/evbdGvC6Us13tvyt4pWg==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/freebsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-2SkqTjTSo2dYi/jzFbU9Plt1vk0+nNg8YC8rOXXea+iA3hfNJWebKYPs3xnOUf9+ZWhKAaxnQNUf2X9LOpeiMQ==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-arm": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.6.tgz",
|
||||
"integrity": "sha512-SZHQlzvqv4Du5PrKE2faN0qlbsaW/3QQfUUc6yO2EjFcA83xnwm91UbEEVx4ApZ9Z5oG8Bxz4qPE+HFwtVcfyw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-b967hU0gqKd9Drsh/UuAm21Khpoh6mPBSgz8mKRq4P5mVK8bpA+hQzmm/ZwGVULSNBzKdZPQBRT3+WuVavcWsQ==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-ia32": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.6.tgz",
|
||||
"integrity": "sha512-aHWdQ2AAltRkLPOsKdi3xv0mZ8fUGPdlKEjIEhxCPm5yKEThcUjHpWB1idN74lfXGnZ5SULQSgtr5Qos5B0bPw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-loong64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.6.tgz",
|
||||
"integrity": "sha512-VgKCsHdXRSQ7E1+QXGdRPlQ/e08bN6WMQb27/TMfV+vPjjTImuT9PmLXupRlC90S1JeNNW5lzkAEO/McKeJ2yg==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-mips64el": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.6.tgz",
|
||||
"integrity": "sha512-WViNlpivRKT9/py3kCmkHnn44GkGXVdXfdc4drNmRl15zVQ2+D2uFwdlGh6IuK5AAnGTo2qPB1Djppj+t78rzw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-ppc64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.6.tgz",
|
||||
"integrity": "sha512-wyYKZ9NTdmAMb5730I38lBqVu6cKl4ZfYXIs31Baf8aoOtB4xSGi3THmDYt4BTFHk7/EcVixkOV2uZfwU3Q2Jw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-riscv64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.6.tgz",
|
||||
"integrity": "sha512-KZh7bAGGcrinEj4qzilJ4hqTY3Dg2U82c8bv+e1xqNqZCrCyc+TL9AUEn5WGKDzm3CfC5RODE/qc96OcbIe33w==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-s390x": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.6.tgz",
|
||||
"integrity": "sha512-9N1LsTwAuE9oj6lHMyyAM+ucxGiVnEqUdp4v7IaMmrwb06ZTEVCIs3oPPplVsnjPfyjmxwHxHMF8b6vzUVAUGw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/linux-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-A6bJB41b4lKFWRKNrWoP2LHsjVzNiaurf7wyj/XtFNTsnPuxwEBWHLty+ZE0dWBKuSK1fvKgrKaNjBS7qbFKig==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/netbsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-IjA+DcwoVpjEvyxZddDqBY+uJ2Snc6duLpjmkXm/v4xuS3H+3FkLZlDm9ZsAbF9rsfP3zeA0/ArNDORZgrxR/Q==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/netbsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-dUXuZr5WenIDlMHdMkvDc1FAu4xdWixTCRgP7RQLBOkkGgwuuzaGSYcOpW4jFxzpzL1ejb8yF620UxAqnBrR9g==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/openbsd-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-l8ZCvXP0tbTJ3iaqdNf3pjaOSd5ex/e6/omLIQCVBLmHTlfXW3zAxQ4fnDmPLOB1x9xrcSi/xtCWFwCZRIaEwg==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/openbsd-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-hKrmDa0aOFOr71KQ/19JC7az1P0GWtCN1t2ahYAf4O007DHZt/dW8ym5+CUdJhQ/qkZmI1HAF8KkJbEFtCL7gw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/openharmony-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-+SqBcAWoB1fYKmpWoQP4pGtx+pUUC//RNYhFdbcSA16617cchuryuhOCRpPsjCblKukAckWsV+aQ3UKT/RMPcA==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/sunos-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-dyCGxv1/Br7MiSC42qinGL8KkG4kX0pEsdb0+TKhmJZgCUDBGmyo1/ArCjNGiOLiIAgdbWgmWgib4HoCi5t7kA==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/win32-arm64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.6.tgz",
|
||||
"integrity": "sha512-42QOgcZeZOvXfsCBJF5Afw73t4veOId//XD3i+/9gSkhSV6Gk3VPlWncctI+JcOyERv85FUo7RxuxGy+z8A43Q==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/win32-ia32": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.6.tgz",
|
||||
"integrity": "sha512-4AWhgXmDuYN7rJI6ORB+uU9DHLq/erBbuMoAuB4VWJTu5KtCgcKYPynF0YI1VkBNuEfjNlLrFr9KZPJzrtLkrQ==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"@esbuild/win32-x64": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.6.tgz",
|
||||
"integrity": "sha512-NgJPHHbEpLQgDH2MjQu90pzW/5vvXIZ7KOnPyNBm92A6WgZ/7b6fJyUBjoumLqeOQQGqY2QjQxRo97ah4Sj0cA==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"esbuild": {
|
||||
"version": "0.25.6",
|
||||
"resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.6.tgz",
|
||||
"integrity": "sha512-GVuzuUwtdsghE3ocJ9Bs8PNoF13HNQ5TXbEi2AhvVb8xU1Iwt9Fos9FEamfoee+u/TOsn7GUWc04lz46n2bbTg==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"@esbuild/aix-ppc64": "0.25.6",
|
||||
"@esbuild/android-arm": "0.25.6",
|
||||
"@esbuild/android-arm64": "0.25.6",
|
||||
"@esbuild/android-x64": "0.25.6",
|
||||
"@esbuild/darwin-arm64": "0.25.6",
|
||||
"@esbuild/darwin-x64": "0.25.6",
|
||||
"@esbuild/freebsd-arm64": "0.25.6",
|
||||
"@esbuild/freebsd-x64": "0.25.6",
|
||||
"@esbuild/linux-arm": "0.25.6",
|
||||
"@esbuild/linux-arm64": "0.25.6",
|
||||
"@esbuild/linux-ia32": "0.25.6",
|
||||
"@esbuild/linux-loong64": "0.25.6",
|
||||
"@esbuild/linux-mips64el": "0.25.6",
|
||||
"@esbuild/linux-ppc64": "0.25.6",
|
||||
"@esbuild/linux-riscv64": "0.25.6",
|
||||
"@esbuild/linux-s390x": "0.25.6",
|
||||
"@esbuild/linux-x64": "0.25.6",
|
||||
"@esbuild/netbsd-arm64": "0.25.6",
|
||||
"@esbuild/netbsd-x64": "0.25.6",
|
||||
"@esbuild/openbsd-arm64": "0.25.6",
|
||||
"@esbuild/openbsd-x64": "0.25.6",
|
||||
"@esbuild/openharmony-arm64": "0.25.6",
|
||||
"@esbuild/sunos-x64": "0.25.6",
|
||||
"@esbuild/win32-arm64": "0.25.6",
|
||||
"@esbuild/win32-ia32": "0.25.6",
|
||||
"@esbuild/win32-x64": "0.25.6"
|
||||
}
|
||||
},
|
||||
"fsevents": {
|
||||
"version": "2.3.3",
|
||||
"resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz",
|
||||
"integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==",
|
||||
"dev": true,
|
||||
"optional": true
|
||||
},
|
||||
"get-tsconfig": {
|
||||
"version": "4.10.1",
|
||||
"resolved": "https://registry.npmjs.org/get-tsconfig/-/get-tsconfig-4.10.1.tgz",
|
||||
"integrity": "sha512-auHyJ4AgMz7vgS8Hp3N6HXSmlMdUyhSUrfBF16w153rxtLIEOE+HGqaBppczZvnHLqQJfiHotCYpNhl0lUROFQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"resolve-pkg-maps": "^1.0.0"
|
||||
}
|
||||
},
|
||||
"resolve-pkg-maps": {
|
||||
"version": "1.0.0",
|
||||
"resolved": "https://registry.npmjs.org/resolve-pkg-maps/-/resolve-pkg-maps-1.0.0.tgz",
|
||||
"integrity": "sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==",
|
||||
"dev": true
|
||||
},
|
||||
"tsx": {
|
||||
"version": "4.20.3",
|
||||
"resolved": "https://registry.npmjs.org/tsx/-/tsx-4.20.3.tgz",
|
||||
"integrity": "sha512-qjbnuR9Tr+FJOMBqJCW5ehvIo/buZq7vH7qD7JziU98h6l3qGy0a/yPFjwO+y0/T7GFpNgNAvEcPPVfyT8rrPQ==",
|
||||
"dev": true,
|
||||
"requires": {
|
||||
"esbuild": "~0.25.0",
|
||||
"fsevents": "~2.3.3",
|
||||
"get-tsconfig": "^4.7.5"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
5
package.json
Normal file
5
package.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"devDependencies": {
|
||||
"tsx": "^4.20.3"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user