(string: string, options: MagicStringOptions = {})
| 82 | declare hasMovedChunks: boolean |
| 83 | |
| 84 | constructor(string: string, options: MagicStringOptions = {}) { |
| 85 | const chunk = new Chunk(0, string.length, string) |
| 86 | |
| 87 | Object.defineProperties(this, { |
| 88 | original: { writable: true, value: string }, |
| 89 | outro: { writable: true, value: '' }, |
| 90 | intro: { writable: true, value: '' }, |
| 91 | firstChunk: { writable: true, value: chunk }, |
| 92 | lastChunk: { writable: true, value: chunk }, |
| 93 | lastSearchedChunk: { writable: true, value: chunk }, |
| 94 | byStart: { writable: true, value: new Map<number, Chunk>([[0, chunk]]) }, |
| 95 | byEnd: { writable: true, value: new Map<number, Chunk>([[string.length, chunk]]) }, |
| 96 | filename: { writable: true, value: options.filename }, |
| 97 | indentExclusionRanges: { writable: true, value: options.indentExclusionRanges }, |
| 98 | sourcemapLocations: { writable: true, value: new BitSet() }, |
| 99 | storedNames: { writable: true, value: {} }, |
| 100 | indentStr: { writable: true, value: undefined }, |
| 101 | ignoreList: { writable: true, value: options.ignoreList }, |
| 102 | offset: { writable: true, value: options.offset || 0 }, |
| 103 | hasMovedChunks: { writable: true, value: false }, |
| 104 | }) |
| 105 | |
| 106 | if (DEBUG) { |
| 107 | Object.defineProperty(this, 'stats', { value: new Stats() }) |
| 108 | } |
| 109 | } |
| 110 | |
| 111 | /** |
| 112 | * Adds the specified character index (with respect to the original string) to sourcemap mappings, if `hires` is false. |
nothing calls this directly
no outgoing calls
no test coverage detected