@wix/create-headless-site 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/import.cjs ADDED
@@ -0,0 +1 @@
1
+ import('../build/index.js');
package/bin/index.cjs ADDED
@@ -0,0 +1,35 @@
1
+ #!/usr/bin/env node
2
+ /* eslint-disable no-var,node/prefer-global/process */
3
+
4
+ (function minimumNodeVersionCheck() {
5
+ const RED = '\x1B[0;31m';
6
+ const GREEN = '\x1B[0;32m';
7
+ const NO_COLOR = '\x1B[0m';
8
+
9
+ const colorize = (color, text) => `${color}${text}${NO_COLOR}`;
10
+
11
+ const versionParts = process.versions.node.split('.').map((v) => Number(v));
12
+ const major = versionParts[0];
13
+ const minor = versionParts[1];
14
+
15
+ if (major < 20 || (major === 20 && minor < 11)) {
16
+ const currentVersion = colorize(RED, process.versions.node);
17
+ const supportedVersion = colorize(GREEN, '20.11.0');
18
+
19
+ console.error(
20
+ `⛔️ Node version ${currentVersion} detected, minimum supported version is ${supportedVersion}`
21
+ );
22
+ console.error('');
23
+ console.error(
24
+ 'Your current node version is lower than the minimum required for the CLI to work correctly.'
25
+ );
26
+ console.error(
27
+ 'Make sure to update your node version to a compatible version.'
28
+ );
29
+ process.exit(1);
30
+ }
31
+ })();
32
+
33
+ process.setSourceMapsEnabled(true);
34
+
35
+ require('./import.cjs');
@@ -0,0 +1,182 @@
1
+ import { createRequire as _createRequire } from 'node:module';
2
+ const require = _createRequire(import.meta.url);
3
+ import {
4
+ esm_exports,
5
+ esm_exports2,
6
+ init_esm,
7
+ init_esm2
8
+ } from "./chunk-YU54OBFT.js";
9
+ import {
10
+ __commonJS,
11
+ __require,
12
+ __toCommonJS,
13
+ init_esm_shims
14
+ } from "./chunk-PYIAC2GK.js";
15
+
16
+ // ../../node_modules/opentelemetry-instrumentation-fetch-node/build/index.js
17
+ var require_build = __commonJS({
18
+ "../../node_modules/opentelemetry-instrumentation-fetch-node/build/index.js"(exports) {
19
+ init_esm_shims();
20
+ var __importDefault = exports && exports.__importDefault || function(mod) {
21
+ return mod && mod.__esModule ? mod : { "default": mod };
22
+ };
23
+ Object.defineProperty(exports, "__esModule", { value: true });
24
+ exports.FetchInstrumentation = void 0;
25
+ var node_diagnostics_channel_1 = __importDefault(__require("node:diagnostics_channel"));
26
+ var semantic_conventions_1 = (init_esm2(), __toCommonJS(esm_exports2));
27
+ var api_1 = (init_esm(), __toCommonJS(esm_exports));
28
+ function getMessage(error) {
29
+ if (error instanceof AggregateError) {
30
+ return error.errors.map((e) => e.message).join(", ");
31
+ }
32
+ return error.message;
33
+ }
34
+ function contentLengthFromResponseHeaders(headers) {
35
+ const name = "content-length";
36
+ for (let i = 0; i < headers.length; i += 2) {
37
+ const k = headers[i];
38
+ if (k.length === name.length && k.toString().toLowerCase() === name) {
39
+ const v = Number(headers[i + 1]);
40
+ if (!Number.isNaN(Number(v))) {
41
+ return v;
42
+ }
43
+ return void 0;
44
+ }
45
+ }
46
+ return void 0;
47
+ }
48
+ async function loadFetch() {
49
+ try {
50
+ await fetch("");
51
+ } catch (_) {
52
+ }
53
+ }
54
+ var FetchInstrumentation = class {
55
+ // Keep ref to avoid https://github.com/nodejs/node/issues/42170 bug and for
56
+ // unsubscribing.
57
+ channelSubs;
58
+ spanFromReq = /* @__PURE__ */ new WeakMap();
59
+ tracer;
60
+ config;
61
+ meter;
62
+ instrumentationName = "opentelemetry-instrumentation-node-18-fetch";
63
+ instrumentationVersion = "1.0.0";
64
+ instrumentationDescription = "Instrumentation for Node 18 fetch via diagnostics_channel";
65
+ subscribeToChannel(diagnosticChannel, onMessage) {
66
+ const channel = node_diagnostics_channel_1.default.channel(diagnosticChannel);
67
+ channel.subscribe(onMessage);
68
+ this.channelSubs.push({
69
+ name: diagnosticChannel,
70
+ channel,
71
+ onMessage
72
+ });
73
+ }
74
+ constructor(config) {
75
+ loadFetch();
76
+ this.channelSubs = [];
77
+ this.meter = api_1.metrics.getMeter(this.instrumentationName, this.instrumentationVersion);
78
+ this.tracer = api_1.trace.getTracer(this.instrumentationName, this.instrumentationVersion);
79
+ this.config = { ...config };
80
+ }
81
+ disable() {
82
+ this.channelSubs?.forEach((sub) => sub.channel.unsubscribe(sub.onMessage));
83
+ }
84
+ enable() {
85
+ this.subscribeToChannel("undici:request:create", (args) => this.onRequest(args));
86
+ this.subscribeToChannel("undici:request:headers", (args) => this.onHeaders(args));
87
+ this.subscribeToChannel("undici:request:trailers", (args) => this.onDone(args));
88
+ this.subscribeToChannel("undici:request:error", (args) => this.onError(args));
89
+ }
90
+ setTracerProvider(tracerProvider) {
91
+ this.tracer = tracerProvider.getTracer(this.instrumentationName, this.instrumentationVersion);
92
+ }
93
+ setMeterProvider(meterProvider) {
94
+ this.meter = meterProvider.getMeter(this.instrumentationName, this.instrumentationVersion);
95
+ }
96
+ setConfig(config) {
97
+ this.config = { ...config };
98
+ }
99
+ getConfig() {
100
+ return this.config;
101
+ }
102
+ onRequest({ request }) {
103
+ if (request.method === "CONNECT") {
104
+ return;
105
+ }
106
+ if (this.config.ignoreRequestHook && this.config.ignoreRequestHook(request) === true) {
107
+ return;
108
+ }
109
+ const span = this.tracer.startSpan(`HTTP ${request.method}`, {
110
+ kind: api_1.SpanKind.CLIENT,
111
+ attributes: {
112
+ [semantic_conventions_1.SemanticAttributes.HTTP_URL]: getAbsoluteUrl(request.origin, request.path),
113
+ [semantic_conventions_1.SemanticAttributes.HTTP_METHOD]: request.method,
114
+ [semantic_conventions_1.SemanticAttributes.HTTP_TARGET]: request.path,
115
+ "http.client": "fetch"
116
+ }
117
+ });
118
+ const requestContext = api_1.trace.setSpan(api_1.context.active(), span);
119
+ const addedHeaders = {};
120
+ api_1.propagation.inject(requestContext, addedHeaders);
121
+ if (this.config.onRequest) {
122
+ this.config.onRequest({ request, span, additionalHeaders: addedHeaders });
123
+ }
124
+ if (Array.isArray(request.headers)) {
125
+ request.headers.push(...Object.entries(addedHeaders).flat());
126
+ } else {
127
+ request.headers += Object.entries(addedHeaders).map(([k, v]) => `${k}: ${v}\r
128
+ `).join("");
129
+ }
130
+ this.spanFromReq.set(request, span);
131
+ }
132
+ onHeaders({ request, response }) {
133
+ const span = this.spanFromReq.get(request);
134
+ if (span !== void 0) {
135
+ const cLen = contentLengthFromResponseHeaders(response.headers);
136
+ const attrs = {
137
+ [semantic_conventions_1.SemanticAttributes.HTTP_STATUS_CODE]: response.statusCode
138
+ };
139
+ if (cLen) {
140
+ attrs[semantic_conventions_1.SemanticAttributes.HTTP_RESPONSE_CONTENT_LENGTH] = cLen;
141
+ }
142
+ span.setAttributes(attrs);
143
+ span.setStatus({
144
+ code: response.statusCode >= 400 ? api_1.SpanStatusCode.ERROR : api_1.SpanStatusCode.OK,
145
+ message: String(response.statusCode)
146
+ });
147
+ }
148
+ }
149
+ onDone({ request }) {
150
+ const span = this.spanFromReq.get(request);
151
+ if (span !== void 0) {
152
+ span.end();
153
+ this.spanFromReq.delete(request);
154
+ }
155
+ }
156
+ onError({ request, error }) {
157
+ const span = this.spanFromReq.get(request);
158
+ if (span !== void 0) {
159
+ span.recordException(error);
160
+ span.setStatus({
161
+ code: api_1.SpanStatusCode.ERROR,
162
+ message: getMessage(error)
163
+ });
164
+ span.end();
165
+ }
166
+ }
167
+ };
168
+ exports.FetchInstrumentation = FetchInstrumentation;
169
+ function getAbsoluteUrl(origin, path = "/") {
170
+ const url = `${origin}`;
171
+ if (origin.endsWith("/") && path.startsWith("/")) {
172
+ return `${url}${path.slice(1)}`;
173
+ }
174
+ if (!origin.endsWith("/") && !path.startsWith("/")) {
175
+ return `${url}/${path.slice(1)}`;
176
+ }
177
+ return `${url}${path}`;
178
+ }
179
+ }
180
+ });
181
+ export default require_build();
182
+ //# sourceMappingURL=build-LO6DVUZE.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../node_modules/opentelemetry-instrumentation-fetch-node/src/index.ts"],"sourcesContent":["/*\n * Portions from https://github.com/elastic/apm-agent-nodejs\n * Copyright Elasticsearch B.V. and other contributors where applicable.\n * Licensed under the BSD 2-Clause License; you may not use this file except in\n * compliance with the BSD 2-Clause License.\n *\n */\nimport diagch from 'node:diagnostics_channel';\n\nimport { SemanticAttributes } from '@opentelemetry/semantic-conventions';\nimport { Instrumentation, InstrumentationConfig } from '@opentelemetry/instrumentation';\nimport {\n Attributes,\n context,\n Meter,\n MeterProvider,\n metrics,\n propagation,\n Span,\n SpanKind,\n SpanStatusCode,\n trace,\n Tracer,\n TracerProvider,\n} from '@opentelemetry/api';\n\ninterface ListenerRecord {\n name: string;\n channel: diagch.Channel;\n onMessage: diagch.ChannelListener;\n}\n\ninterface FetchRequest {\n method: string;\n origin: string;\n path: string;\n headers: string | string[];\n}\n\ninterface FetchResponse {\n headers: Buffer[];\n statusCode: number;\n}\n\nexport interface FetchInstrumentationConfig extends InstrumentationConfig {\n ignoreRequestHook?: (request: FetchRequest) => boolean;\n onRequest?: (args: {\n request: FetchRequest;\n span: Span;\n additionalHeaders: Record<string, string | string[]>;\n }) => void;\n}\n\nfunction getMessage(error: Error) {\n if (error instanceof AggregateError) {\n return error.errors.map((e) => e.message).join(', ');\n }\n return error.message;\n}\n\n// Get the content-length from undici response headers.\n// `headers` is an Array of buffers: [k, v, k, v, ...].\n// If the header is not present, or has an invalid value, this returns null.\nfunction contentLengthFromResponseHeaders(headers: Buffer[]) {\n const name = 'content-length';\n for (let i = 0; i < headers.length; i += 2) {\n const k = headers[i];\n if (k.length === name.length && k.toString().toLowerCase() === name) {\n const v = Number(headers[i + 1]);\n if (!Number.isNaN(Number(v))) {\n return v;\n }\n return undefined;\n }\n }\n return undefined;\n}\n\nasync function loadFetch() {\n try {\n await fetch('');\n } catch (_) {\n //\n }\n}\n\n// A combination of https://github.com/elastic/apm-agent-nodejs and\n// https://github.com/gadget-inc/opentelemetry-instrumentations/blob/main/packages/opentelemetry-instrumentation-undici/src/index.ts\nexport class FetchInstrumentation implements Instrumentation {\n // Keep ref to avoid https://github.com/nodejs/node/issues/42170 bug and for\n // unsubscribing.\n private channelSubs: Array<ListenerRecord> | undefined;\n\n private spanFromReq = new WeakMap<FetchRequest, Span>();\n\n private tracer: Tracer;\n\n private config: FetchInstrumentationConfig;\n\n private meter: Meter;\n\n public readonly instrumentationName = 'opentelemetry-instrumentation-node-18-fetch';\n\n public readonly instrumentationVersion = '1.0.0';\n\n public readonly instrumentationDescription =\n 'Instrumentation for Node 18 fetch via diagnostics_channel';\n\n private subscribeToChannel(diagnosticChannel: string, onMessage: diagch.ChannelListener) {\n const channel = diagch.channel(diagnosticChannel);\n channel.subscribe(onMessage);\n this.channelSubs!.push({\n name: diagnosticChannel,\n channel,\n onMessage,\n });\n }\n\n constructor(config: FetchInstrumentationConfig) {\n // Force load fetch API (since it's lazy loaded in Node 18)\n loadFetch();\n this.channelSubs = [];\n this.meter = metrics.getMeter(this.instrumentationName, this.instrumentationVersion);\n this.tracer = trace.getTracer(this.instrumentationName, this.instrumentationVersion);\n this.config = { ...config };\n }\n\n disable(): void {\n this.channelSubs?.forEach((sub) => sub.channel.unsubscribe(sub.onMessage));\n }\n\n enable(): void {\n this.subscribeToChannel('undici:request:create', (args) =>\n this.onRequest(args as { request: FetchRequest }),\n );\n this.subscribeToChannel('undici:request:headers', (args) =>\n this.onHeaders(args as { request: FetchRequest; response: FetchResponse }),\n );\n this.subscribeToChannel('undici:request:trailers', (args) =>\n this.onDone(args as { request: FetchRequest }),\n );\n this.subscribeToChannel('undici:request:error', (args) =>\n this.onError(args as { request: FetchRequest; error: Error }),\n );\n }\n\n setTracerProvider(tracerProvider: TracerProvider): void {\n this.tracer = tracerProvider.getTracer(this.instrumentationName, this.instrumentationVersion);\n }\n\n public setMeterProvider(meterProvider: MeterProvider): void {\n this.meter = meterProvider.getMeter(this.instrumentationName, this.instrumentationVersion);\n }\n\n setConfig(config: InstrumentationConfig): void {\n this.config = { ...config };\n }\n\n getConfig(): InstrumentationConfig {\n return this.config;\n }\n\n onRequest({ request }: { request: FetchRequest }): void {\n // Don't instrument CONNECT - see comments at:\n // https://github.com/elastic/apm-agent-nodejs/blob/c55b1d8c32b2574362fc24d81b8e173ce2f75257/lib/instrumentation/modules/undici.js#L24\n if (request.method === 'CONNECT') {\n return;\n }\n if (this.config.ignoreRequestHook && this.config.ignoreRequestHook(request) === true) {\n return;\n }\n\n const span = this.tracer.startSpan(`HTTP ${request.method}`, {\n kind: SpanKind.CLIENT,\n attributes: {\n [SemanticAttributes.HTTP_URL]: getAbsoluteUrl(request.origin, request.path),\n [SemanticAttributes.HTTP_METHOD]: request.method,\n [SemanticAttributes.HTTP_TARGET]: request.path,\n 'http.client': 'fetch',\n },\n });\n const requestContext = trace.setSpan(context.active(), span);\n const addedHeaders: Record<string, string> = {};\n propagation.inject(requestContext, addedHeaders);\n\n if (this.config.onRequest) {\n this.config.onRequest({ request, span, additionalHeaders: addedHeaders });\n }\n\n if (Array.isArray(request.headers)) {\n request.headers.push(...Object.entries(addedHeaders).flat());\n } else {\n request.headers += Object.entries(addedHeaders)\n .map(([k, v]) => `${k}: ${v}\\r\\n`)\n .join('');\n }\n this.spanFromReq.set(request, span);\n }\n\n onHeaders({ request, response }: { request: FetchRequest; response: FetchResponse }): void {\n const span = this.spanFromReq.get(request);\n\n if (span !== undefined) {\n // We are currently *not* capturing response headers, even though the\n // intake API does allow it, because none of the other `setHttpContext`\n // uses currently do.\n\n const cLen = contentLengthFromResponseHeaders(response.headers);\n const attrs: Attributes = {\n [SemanticAttributes.HTTP_STATUS_CODE]: response.statusCode,\n };\n if (cLen) {\n attrs[SemanticAttributes.HTTP_RESPONSE_CONTENT_LENGTH] = cLen;\n }\n span.setAttributes(attrs);\n span.setStatus({\n code: response.statusCode >= 400 ? SpanStatusCode.ERROR : SpanStatusCode.OK,\n message: String(response.statusCode),\n });\n }\n }\n\n onDone({ request }: { request: FetchRequest }): void {\n const span = this.spanFromReq.get(request);\n if (span !== undefined) {\n span.end();\n this.spanFromReq.delete(request);\n }\n }\n\n onError({ request, error }: { request: FetchRequest; error: Error }): void {\n const span = this.spanFromReq.get(request);\n if (span !== undefined) {\n span.recordException(error);\n span.setStatus({\n code: SpanStatusCode.ERROR,\n message: getMessage(error),\n });\n span.end();\n }\n }\n}\n\nfunction getAbsoluteUrl(origin: string, path: string = '/'): string {\n const url = `${origin}`;\n\n if (origin.endsWith('/') && path.startsWith('/')) {\n return `${url}${path.slice(1)}`;\n }\n\n if (!origin.endsWith('/') && !path.startsWith('/')) {\n return `${url}/${path.slice(1)}`;\n }\n\n return `${url}${path}`;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAOA,QAAA,6BAAA,gBAAA,UAAA,0BAAA,CAAA;AAEA,QAAA,yBAAA;AAEA,QAAA,QAAA;AA0CA,aAAS,WAAW,OAAY;AAC9B,UAAI,iBAAiB,gBAAgB;AACnC,eAAO,MAAM,OAAO,IAAI,CAAC,MAAM,EAAE,OAAO,EAAE,KAAK,IAAI;MACrD;AACA,aAAO,MAAM;IACf;AAKA,aAAS,iCAAiC,SAAiB;AACzD,YAAM,OAAO;AACb,eAAS,IAAI,GAAG,IAAI,QAAQ,QAAQ,KAAK,GAAG;AAC1C,cAAM,IAAI,QAAQ,CAAC;AACnB,YAAI,EAAE,WAAW,KAAK,UAAU,EAAE,SAAQ,EAAG,YAAW,MAAO,MAAM;AACnE,gBAAM,IAAI,OAAO,QAAQ,IAAI,CAAC,CAAC;AAC/B,cAAI,CAAC,OAAO,MAAM,OAAO,CAAC,CAAC,GAAG;AAC5B,mBAAO;UACT;AACA,iBAAO;QACT;MACF;AACA,aAAO;IACT;AAEA,mBAAe,YAAS;AACtB,UAAI;AACF,cAAM,MAAM,EAAE;MAChB,SAAS,GAAG;MAEZ;IACF;AAIA,QAAa,uBAAb,MAAiC;;;MAGvB;MAEA,cAAc,oBAAI,QAAO;MAEzB;MAEA;MAEA;MAEQ,sBAAsB;MAEtB,yBAAyB;MAEzB,6BACd;MAEM,mBAAmB,mBAA2B,WAAiC;AACrF,cAAM,UAAU,2BAAA,QAAO,QAAQ,iBA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I,OAAO;AACzC,YAAI,SAAS,QAAW;AACtB,eAAK,IAAG;AACR,eAAK,YAAY,OAAO,OAAO;QACjC;MACF;MAEA,QAAQ,EAAE,SAAS,MAAK,GAA2C;AACjE,cAAM,OAAO,KAAK,YAAY,IAAI,OAAO;AACzC,YAAI,SAAS,QAAW;AACtB,eAAK,gBAAgB,KAAK;AAC1B,eAAK,UAAU;YACb,MAAM,MAAA,eAAe;YACrB,SAAS,WAAW,KAAK;WAC1B;AACD,eAAK,IAAG;QACV;MACF;;AAxJF,YAAA,uBAAA;AA2JA,aAAS,eAAe,QAAgB,OAAe,KAAG;AACxD,YAAM,MAAM,GAAG,MAAM;AAErB,UAAI,OAAO,SAAS,GAAG,KAAK,KAAK,WAAW,GAAG,GAAG;AAChD,eAAO,GAAG,GAAG,GAAG,KAAK,MAAM,CAAC,CAAC;MAC/B;AAEA,UAAI,CAAC,OAAO,SAAS,GAAG,KAAK,CAAC,KAAK,WAAW,GAAG,GAAG;AAClD,eAAO,GAAG,GAAG,IAAI,KAAK,MAAM,CAAC,CAAC;MAChC;AAEA,aAAO,GAAG,GAAG,GAAG,IAAI;IACtB;;;","names":[]}
@@ -0,0 +1,66 @@
1
+ import { createRequire as _createRequire } from 'node:module';
2
+ const require = _createRequire(import.meta.url);
3
+ var __create = Object.create;
4
+ var __defProp = Object.defineProperty;
5
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
+ var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
8
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
9
+ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
10
+ get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
11
+ }) : x)(function(x) {
12
+ if (typeof require !== "undefined") return require.apply(this, arguments);
13
+ throw Error('Dynamic require of "' + x + '" is not supported');
14
+ });
15
+ var __esm = (fn, res) => function __init() {
16
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
17
+ };
18
+ var __commonJS = (cb, mod) => function __require2() {
19
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
20
+ };
21
+ var __export = (target, all) => {
22
+ for (var name in all)
23
+ __defProp(target, name, { get: all[name], enumerable: true });
24
+ };
25
+ var __copyProps = (to, from, except, desc) => {
26
+ if (from && typeof from === "object" || typeof from === "function") {
27
+ for (let key of __getOwnPropNames(from))
28
+ if (!__hasOwnProp.call(to, key) && key !== except)
29
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
30
+ }
31
+ return to;
32
+ };
33
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
34
+ // If the importer is in node compatibility mode or this is not an ESM
35
+ // file that has been converted to a CommonJS file using a Babel-
36
+ // compatible transform (i.e. "__esModule" has not been set), then set
37
+ // "default" to the CommonJS "module.exports" for node compatibility.
38
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
39
+ mod
40
+ ));
41
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
42
+
43
+ // ../../node_modules/tsup/assets/esm_shims.js
44
+ import { fileURLToPath } from "url";
45
+ import path from "path";
46
+ var getFilename, getDirname, __dirname;
47
+ var init_esm_shims = __esm({
48
+ "../../node_modules/tsup/assets/esm_shims.js"() {
49
+ "use strict";
50
+ getFilename = () => fileURLToPath(import.meta.url);
51
+ getDirname = () => path.dirname(getFilename());
52
+ __dirname = /* @__PURE__ */ getDirname();
53
+ }
54
+ });
55
+
56
+ export {
57
+ __require,
58
+ __esm,
59
+ __commonJS,
60
+ __export,
61
+ __toESM,
62
+ __toCommonJS,
63
+ __dirname,
64
+ init_esm_shims
65
+ };
66
+ //# sourceMappingURL=chunk-PYIAC2GK.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../node_modules/tsup/assets/esm_shims.js"],"sourcesContent":["// Shim globals in esm bundle\nimport { fileURLToPath } from 'url'\nimport path from 'path'\n\nconst getFilename = () => fileURLToPath(import.meta.url)\nconst getDirname = () => path.dirname(getFilename())\n\nexport const __dirname = /* @__PURE__ */ getDirname()\nexport const __filename = /* @__PURE__ */ getFilename()\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,SAAS,qBAAqB;AAC9B,OAAO,UAAU;AAFjB,IAIM,aACA,YAEO;AAPb;AAAA;AAAA;AAIA,IAAM,cAAc,MAAM,cAAc,YAAY,GAAG;AACvD,IAAM,aAAa,MAAM,KAAK,QAAQ,YAAY,CAAC;AAE5C,IAAM,YAA4B,2BAAW;AAAA;AAAA;","names":[]}