import type { RawSourceMap } from '@rspack/core'; export interface ExtractedSourceMap { code: string; /** The decoded sourcemap as a JSON string, when inline and usable. */ map: string | undefined; /** * Whether a trailing sourceMappingURL comment was stripped from the code, * even when it yielded no usable map (an external file reference or a * payload rspack would reject). */ strippedComment: boolean; } /** * Splits a trailing sourcemap comment off the given code so the map can be * passed to the loader callback and chained into the final sourcemaps, * mirroring how the esbuild pipeline consumes the inline sourcemaps of the * Angular compilation and the JavaScript transformer. Comments that carry no * usable inline map are still stripped: esbuild never emits input * sourceMappingURL comments into the bundle. */ export declare function extractInlineSourceMap(code: string): ExtractedSourceMap; /** * Whether rspack's sourcemap deserializer accepts this value as a * loader-provided map. Rspack fails the module build on any map it cannot * deserialize, even when sourcemaps are disabled, so externally authored maps * (a package's own sourcemap) must pass this check before being handed to * the loader callback. Mirrors rspack's deserialization rules: `mappings` * must be a string; every other field is optional and may be null, but a * present value must have the expected type, including array elements * (`sources`, `names` and `sourcesContent` entries may be null; `ignoreList` * entries are deserialized as unsigned 32-bit integers). */ export declare function isForwardableSourceMap(value: unknown): value is RawSourceMap; //# sourceMappingURL=inline-source-map.d.ts.map