@stacksjs/dtsx 0.9.12 → 0.9.14
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/README.md +5 -3
- package/dist/bin/cli.js +6 -6
- package/dist/branded-types.d.ts +10 -18
- package/dist/chunk-1bge31tv.js +2 -0
- package/dist/chunk-27nzyfdd.js +2 -0
- package/dist/chunk-285mqzvx.js +16 -0
- package/dist/chunk-2n1bbm2c.js +448 -0
- package/dist/chunk-3w5aqasc.js +33 -0
- package/dist/chunk-3xqchdwd.js +2 -0
- package/dist/chunk-7tyhhk7c.js +2 -0
- package/dist/chunk-8kz02py2.js +2 -0
- package/dist/{chunk-xe1z54pq.js → chunk-abhx1v3w.js} +1 -1
- package/dist/chunk-ayvw3402.js +2 -0
- package/dist/chunk-cbz06k9p.js +2 -0
- package/dist/chunk-d1xj2pjv.js +24 -0
- package/dist/chunk-dk914hsr.js +2 -0
- package/dist/chunk-dzgms5s6.js +80 -0
- package/dist/{chunk-91gpfz27.js → chunk-enqtx6te.js} +1 -1
- package/dist/{chunk-57agx6g8.js → chunk-gssantc8.js} +1 -1
- package/dist/chunk-j1zrbs2z.js +2 -0
- package/dist/{chunk-20kdv9bh.js → chunk-j8zksbkn.js} +1 -1
- package/dist/chunk-mcdb3q06.js +3 -0
- package/dist/{chunk-7vj8vtzh.js → chunk-mwfja9e3.js} +1 -1
- package/dist/{chunk-jm5ywn4e.js → chunk-mxam9312.js} +8 -8
- package/dist/chunk-nf54b52t.js +6 -0
- package/dist/{chunk-kge8a5vc.js → chunk-p50ms07x.js} +1 -1
- package/dist/{chunk-p09jmjq8.js → chunk-pj8142by.js} +1 -1
- package/dist/chunk-pt2txw6z.js +2 -0
- package/dist/chunk-r6v1qdqb.js +6 -0
- package/dist/chunk-rsv17jh8.js +3 -0
- package/dist/{chunk-7cpp6v8f.js → chunk-sw3m29sw.js} +1 -1
- package/dist/chunk-thhd43x5.js +19 -0
- package/dist/{chunk-3j7r0fxz.js → chunk-tne5n3h1.js} +1 -1
- package/dist/{chunk-v96rjx7x.js → chunk-trm0gptj.js} +1 -1
- package/dist/{chunk-jddkdjap.js → chunk-vgm83r4p.js} +1 -1
- package/dist/chunk-vpjw38x7.js +34 -0
- package/dist/chunk-wzq881r8.js +4 -0
- package/dist/chunk-x4v9kajr.js +3 -0
- package/dist/{chunk-8j312sjx.js → chunk-xmje6xfw.js} +1 -1
- package/dist/{chunk-3g2v2ns2.js → chunk-xtee8g1a.js} +1 -1
- package/dist/{chunk-fjjs2r77.js → chunk-y6m8mmyg.js} +1 -1
- package/dist/{chunk-6qv7p9sg.js → chunk-zf17s33e.js} +18 -11
- package/dist/compat.d.ts +5 -2
- package/dist/extractor/cache.d.ts +6 -2
- package/dist/extractor/directives.d.ts +0 -4
- package/dist/generator.d.ts +1 -1
- package/dist/logger.d.ts +4 -0
- package/dist/optimizer.d.ts +4 -0
- package/dist/process-source.d.ts +1 -0
- package/dist/processor/cache.d.ts +4 -2
- package/dist/processor/imports.d.ts +1 -0
- package/dist/src/index.js +52 -51
- package/dist/src/plugins/bun.js +1 -1
- package/dist/src/plugins/esbuild.js +1 -1
- package/dist/src/plugins/index.js +1 -1
- package/dist/src/plugins/tsup.js +1 -1
- package/dist/src/plugins/vite.js +1 -1
- package/dist/src/plugins/webpack.js +1 -1
- package/dist/transformers.d.ts +16 -1
- package/dist/type-mappings.d.ts +32 -16
- package/dist/types.d.ts +2 -0
- package/package.json +3 -3
- package/dist/chunk-0fhq2wva.js +0 -17
- package/dist/chunk-1e5c83wa.js +0 -2
- package/dist/chunk-1vc477cq.js +0 -2
- package/dist/chunk-2w3g3g00.js +0 -19
- package/dist/chunk-5fveksya.js +0 -6
- package/dist/chunk-6s7n1gt0.js +0 -2
- package/dist/chunk-7p1sfeeg.js +0 -2
- package/dist/chunk-8dx98fd5.js +0 -75
- package/dist/chunk-97pgeywh.js +0 -33
- package/dist/chunk-bzsvvb81.js +0 -2
- package/dist/chunk-d9my0n30.js +0 -2
- package/dist/chunk-efkpkyz9.js +0 -4
- package/dist/chunk-f18nyrrb.js +0 -32
- package/dist/chunk-gpxdn99a.js +0 -3
- package/dist/chunk-j40mkvfg.js +0 -2
- package/dist/chunk-kpp6ajgg.js +0 -2
- package/dist/chunk-me2ae6f0.js +0 -23
- package/dist/chunk-p1d09y82.js +0 -449
- package/dist/chunk-qn0xktfx.js +0 -3
- package/dist/chunk-r1m3q3dj.js +0 -2
- package/dist/chunk-r1ywapeb.js +0 -6
- package/dist/chunk-rw6j20e2.js +0 -3
- package/dist/chunk-zsznaama.js +0 -2
- package/dist/extractor/extract.d.ts +0 -10
- package/dist/extractor/scanner.d.ts +0 -6
package/dist/compat.d.ts
CHANGED
|
@@ -15,11 +15,14 @@ export declare function write(path: string, content: string | Uint8Array | Array
|
|
|
15
15
|
*/
|
|
16
16
|
export declare function spawnProcess(command: string | string[], options?: CompatSpawnOptions): SpawnResult;
|
|
17
17
|
/**
|
|
18
|
-
* Read a file as text with cross-runtime compatibility
|
|
18
|
+
* Read a file as text with cross-runtime compatibility.
|
|
19
|
+
* On Node.js we skip the FileHandle wrapper allocation and call readFile directly.
|
|
19
20
|
*/
|
|
20
21
|
export declare function readTextFile(path: string): Promise<string>;
|
|
21
22
|
/**
|
|
22
|
-
* Check if a file exists with cross-runtime compatibility
|
|
23
|
+
* Check if a file exists with cross-runtime compatibility.
|
|
24
|
+
* On Node.js we go straight to stat() — the FileHandle indirection only
|
|
25
|
+
* mattered for Bun's optimized exists() check.
|
|
23
26
|
*/
|
|
24
27
|
export declare function fileExists(path: string): Promise<boolean>;
|
|
25
28
|
/**
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import { hashContent } from './hash';
|
|
2
2
|
import type { SourceFile } from 'typescript';
|
|
3
3
|
/**
|
|
4
|
-
* Evict oldest entry if cache exceeds max size
|
|
5
|
-
*
|
|
4
|
+
* Evict the oldest entry if the cache exceeds max size.
|
|
5
|
+
*
|
|
6
|
+
* Map preserves insertion order, and the get* helpers below now promote on
|
|
7
|
+
* hit (delete + re-set), so the first key Map yields is always the LRU
|
|
8
|
+
* entry. That gives O(1) eviction — the previous implementation walked the
|
|
9
|
+
* full cache to find the oldest `lastAccess`.
|
|
6
10
|
*/
|
|
7
11
|
export declare function evictOldestEntries(): void;
|
|
8
12
|
/**
|
package/dist/generator.d.ts
CHANGED
|
@@ -15,4 +15,4 @@ export declare function watch(options?: Partial<DtsGenerationConfig>): Promise<v
|
|
|
15
15
|
* Process TypeScript source code from a string (for stdin support)
|
|
16
16
|
* Re-exported from process-source.ts for backward compatibility
|
|
17
17
|
*/
|
|
18
|
-
export { processSource } from './process-source';
|
|
18
|
+
export { clearResultCache, processSource } from './process-source';
|
package/dist/logger.d.ts
CHANGED
package/dist/optimizer.d.ts
CHANGED
package/dist/process-source.d.ts
CHANGED
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* like bun Glob, fs/promises, bundler, cache, config, etc.
|
|
5
5
|
*/
|
|
6
6
|
export declare function processSource(sourceCode: string, filename?: string, keepComments?: boolean, importOrder?: string[], isolatedDeclarations?: boolean): string;
|
|
7
|
+
export declare function clearResultCache(): void;
|
|
7
8
|
/**
|
|
8
9
|
* Fast path for project mode — skips cache lookup/store.
|
|
9
10
|
* Use when processing many files once (no cache benefit).
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Get or create a cached RegExp for word boundary matching
|
|
2
|
+
* Get or create a cached RegExp for word boundary matching.
|
|
3
|
+
* Promotes the entry on a hit so the FIFO eviction approximates LRU.
|
|
3
4
|
*/
|
|
4
5
|
export declare function getCachedRegex(pattern: string): RegExp;
|
|
5
6
|
/**
|
|
6
|
-
* Get cached import items or null if not cached
|
|
7
|
+
* Get cached import items or null if not cached.
|
|
8
|
+
* Promotes on hit for LRU-like semantics.
|
|
7
9
|
*/
|
|
8
10
|
export declare function getImportItemsFromCache(importText: string): string[] | null;
|
|
9
11
|
/**
|