ember-repl 6.0.0 → 7.0.0
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/LICENSE.md +1 -1
- package/README.md +2 -404
- package/config/.try.mjs +87 -0
- package/config/addon-main.cjs +7 -0
- package/config/attw.json +7 -0
- package/config/babel.publish.config.cjs +29 -0
- package/config/ember-cli-update.json +21 -0
- package/config/rollup.config.mjs +44 -0
- package/config/testem.cjs +35 -0
- package/config/tsconfig.publish.json +18 -0
- package/config/vite.config.mjs +36 -0
- package/declarations/compile/Compiled.d.ts +7 -0
- package/declarations/compile/Compiled.d.ts.map +1 -0
- package/declarations/compile/compile.d.ts +17 -0
- package/declarations/compile/compile.d.ts.map +1 -0
- package/declarations/compile/state.d.ts +43 -0
- package/declarations/compile/state.d.ts.map +1 -0
- package/declarations/compile/types.d.ts +5 -12
- package/declarations/compile/types.d.ts.map +1 -1
- package/declarations/index.d.ts +6 -2
- package/declarations/index.d.ts.map +1 -1
- package/declarations/services/compiler.d.ts +94 -0
- package/declarations/services/compiler.d.ts.map +1 -0
- package/declarations/services/known-modules.d.ts +7 -0
- package/declarations/services/known-modules.d.ts.map +1 -0
- package/declarations/setup.d.ts +7 -0
- package/declarations/setup.d.ts.map +1 -0
- package/declarations/test-support.d.ts +20 -0
- package/declarations/test-support.d.ts.map +1 -0
- package/dist/_commonjsHelpers-BAGoDD49.js +37 -0
- package/dist/_commonjsHelpers-BAGoDD49.js.map +1 -0
- package/dist/babel-8wMrbxkT.js +110427 -0
- package/dist/babel-8wMrbxkT.js.map +1 -0
- package/dist/blank-line-Bzg2Qt4K.js +482 -0
- package/dist/blank-line-Bzg2Qt4K.js.map +1 -0
- package/dist/compile/Compiled.js +26 -0
- package/dist/compile/Compiled.js.map +1 -0
- package/dist/compile/compile.js +62 -0
- package/dist/compile/compile.js.map +1 -0
- package/dist/compile/state.js +75 -0
- package/dist/compile/state.js.map +1 -0
- package/dist/compile/utils.js +213 -2
- package/dist/compile/utils.js.map +1 -1
- package/dist/default-CoqAuVeH.js +4 -0
- package/dist/default-CoqAuVeH.js.map +1 -0
- package/dist/index-BTx1k6gT.js +323 -0
- package/dist/index-BTx1k6gT.js.map +1 -0
- package/dist/index-Bxzjtr16.js +87 -0
- package/dist/index-Bxzjtr16.js.map +1 -0
- package/dist/index-C371bO_b.js +1553 -0
- package/dist/index-C371bO_b.js.map +1 -0
- package/dist/index-C4AyeeIa.js +5721 -0
- package/dist/index-C4AyeeIa.js.map +1 -0
- package/dist/index-C8S2G0FH.js +1953 -0
- package/dist/index-C8S2G0FH.js.map +1 -0
- package/dist/index-CCcIVEUK.js +409 -0
- package/dist/index-CCcIVEUK.js.map +1 -0
- package/dist/index-CDSIcg03.js +9070 -0
- package/dist/index-CDSIcg03.js.map +1 -0
- package/dist/index-D8szzCn3.js +2 -0
- package/dist/index-D8szzCn3.js.map +1 -0
- package/dist/index-DBBNT106.js +2644 -0
- package/dist/index-DBBNT106.js.map +1 -0
- package/dist/index-DP_Su7Zc.js +362 -0
- package/dist/index-DP_Su7Zc.js.map +1 -0
- package/dist/index-DejgrVqh.js +11299 -0
- package/dist/index-DejgrVqh.js.map +1 -0
- package/dist/index-Dr5iYoKt.js +1551 -0
- package/dist/index-Dr5iYoKt.js.map +1 -0
- package/dist/index-DxolpiGq.js +3336 -0
- package/dist/index-DxolpiGq.js.map +1 -0
- package/dist/index-ZyJlPFQY.js +249 -0
- package/dist/index-ZyJlPFQY.js.map +1 -0
- package/dist/index-k6CfLgeq.js +26 -0
- package/dist/index-k6CfLgeq.js.map +1 -0
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/services/compiler.js +329 -0
- package/dist/services/compiler.js.map +1 -0
- package/dist/services/known-modules.js +123 -0
- package/dist/services/known-modules.js.map +1 -0
- package/dist/setup.js +15 -0
- package/dist/setup.js.map +1 -0
- package/dist/test-support.js +33 -0
- package/dist/test-support.js.map +1 -0
- package/package.json +117 -138
- package/src/compile/Compiled.ts +45 -0
- package/src/compile/compile.ts +89 -0
- package/src/compile/state.ts +88 -0
- package/src/compile/types.ts +14 -13
- package/src/index.ts +6 -2
- package/src/services/compiler.ts +401 -0
- package/src/services/known-modules.ts +130 -0
- package/src/setup.ts +26 -0
- package/src/test-support.ts +64 -0
- package/addon-main.cjs +0 -5
- package/declarations/__PRIVATE__.d.ts +0 -2
- package/declarations/__PRIVATE__.d.ts.map +0 -1
- package/declarations/compile/formats/gjs/babel.d.ts +0 -7
- package/declarations/compile/formats/gjs/babel.d.ts.map +0 -1
- package/declarations/compile/formats/gjs/eval.d.ts +0 -8
- package/declarations/compile/formats/gjs/eval.d.ts.map +0 -1
- package/declarations/compile/formats/gjs/index.d.ts +0 -24
- package/declarations/compile/formats/gjs/index.d.ts.map +0 -1
- package/declarations/compile/formats/gjs/known-modules.d.ts +0 -48
- package/declarations/compile/formats/gjs/known-modules.d.ts.map +0 -1
- package/declarations/compile/formats/hbs.d.ts +0 -17
- package/declarations/compile/formats/hbs.d.ts.map +0 -1
- package/declarations/compile/formats/markdown.d.ts +0 -22
- package/declarations/compile/formats/markdown.d.ts.map +0 -1
- package/declarations/compile/formats.d.ts +0 -17
- package/declarations/compile/formats.d.ts.map +0 -1
- package/declarations/compile/index.d.ts +0 -80
- package/declarations/compile/index.d.ts.map +0 -1
- package/declarations/test-support/index.d.ts +0 -2
- package/declarations/test-support/index.d.ts.map +0 -1
- package/dist/__PRIVATE__.js +0 -2
- package/dist/__PRIVATE__.js.map +0 -1
- package/dist/compile/formats/gjs/babel.js +0 -2
- package/dist/compile/formats/gjs/babel.js.map +0 -1
- package/dist/compile/formats/gjs/eval.js +0 -19
- package/dist/compile/formats/gjs/eval.js.map +0 -1
- package/dist/compile/formats/gjs/index.js +0 -122
- package/dist/compile/formats/gjs/index.js.map +0 -1
- package/dist/compile/formats/gjs/known-modules.js +0 -52
- package/dist/compile/formats/gjs/known-modules.js.map +0 -1
- package/dist/compile/formats/hbs.js +0 -93
- package/dist/compile/formats/hbs.js.map +0 -1
- package/dist/compile/formats/markdown.js +0 -266
- package/dist/compile/formats/markdown.js.map +0 -1
- package/dist/compile/formats.js +0 -173
- package/dist/compile/formats.js.map +0 -1
- package/dist/compile/index.js +0 -113
- package/dist/compile/index.js.map +0 -1
- package/dist/test-support/index.js +0 -8
- package/dist/test-support/index.js.map +0 -1
- package/src/__PRIVATE__.ts +0 -1
- package/src/compile/formats/gjs/babel.ts +0 -7
- package/src/compile/formats/gjs/eval.ts +0 -29
- package/src/compile/formats/gjs/index.ts +0 -153
- package/src/compile/formats/gjs/known-modules.ts +0 -49
- package/src/compile/formats/hbs.ts +0 -100
- package/src/compile/formats/markdown.ts +0 -345
- package/src/compile/formats.ts +0 -178
- package/src/compile/index.ts +0 -219
- package/src/test-support/index.ts +0 -5
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
const VOID = -1;
|
|
2
|
+
const PRIMITIVE = 0;
|
|
3
|
+
const ARRAY = 1;
|
|
4
|
+
const OBJECT = 2;
|
|
5
|
+
const DATE = 3;
|
|
6
|
+
const REGEXP = 4;
|
|
7
|
+
const MAP = 5;
|
|
8
|
+
const SET = 6;
|
|
9
|
+
const ERROR = 7;
|
|
10
|
+
const BIGINT = 8;
|
|
11
|
+
// export const SYMBOL = 9;
|
|
12
|
+
|
|
13
|
+
const env = typeof self === 'object' ? self : globalThis;
|
|
14
|
+
const deserializer = ($, _) => {
|
|
15
|
+
const as = (out, index) => {
|
|
16
|
+
$.set(index, out);
|
|
17
|
+
return out;
|
|
18
|
+
};
|
|
19
|
+
const unpair = index => {
|
|
20
|
+
if ($.has(index)) return $.get(index);
|
|
21
|
+
const [type, value] = _[index];
|
|
22
|
+
switch (type) {
|
|
23
|
+
case PRIMITIVE:
|
|
24
|
+
case VOID:
|
|
25
|
+
return as(value, index);
|
|
26
|
+
case ARRAY:
|
|
27
|
+
{
|
|
28
|
+
const arr = as([], index);
|
|
29
|
+
for (const index of value) arr.push(unpair(index));
|
|
30
|
+
return arr;
|
|
31
|
+
}
|
|
32
|
+
case OBJECT:
|
|
33
|
+
{
|
|
34
|
+
const object = as({}, index);
|
|
35
|
+
for (const [key, index] of value) object[unpair(key)] = unpair(index);
|
|
36
|
+
return object;
|
|
37
|
+
}
|
|
38
|
+
case DATE:
|
|
39
|
+
return as(new Date(value), index);
|
|
40
|
+
case REGEXP:
|
|
41
|
+
{
|
|
42
|
+
const {
|
|
43
|
+
source,
|
|
44
|
+
flags
|
|
45
|
+
} = value;
|
|
46
|
+
return as(new RegExp(source, flags), index);
|
|
47
|
+
}
|
|
48
|
+
case MAP:
|
|
49
|
+
{
|
|
50
|
+
const map = as(new Map(), index);
|
|
51
|
+
for (const [key, index] of value) map.set(unpair(key), unpair(index));
|
|
52
|
+
return map;
|
|
53
|
+
}
|
|
54
|
+
case SET:
|
|
55
|
+
{
|
|
56
|
+
const set = as(new Set(), index);
|
|
57
|
+
for (const index of value) set.add(unpair(index));
|
|
58
|
+
return set;
|
|
59
|
+
}
|
|
60
|
+
case ERROR:
|
|
61
|
+
{
|
|
62
|
+
const {
|
|
63
|
+
name,
|
|
64
|
+
message
|
|
65
|
+
} = value;
|
|
66
|
+
return as(new env[name](message), index);
|
|
67
|
+
}
|
|
68
|
+
case BIGINT:
|
|
69
|
+
return as(BigInt(value), index);
|
|
70
|
+
case 'BigInt':
|
|
71
|
+
return as(Object(BigInt(value)), index);
|
|
72
|
+
case 'ArrayBuffer':
|
|
73
|
+
return as(new Uint8Array(value).buffer, value);
|
|
74
|
+
case 'DataView':
|
|
75
|
+
{
|
|
76
|
+
const {
|
|
77
|
+
buffer
|
|
78
|
+
} = new Uint8Array(value);
|
|
79
|
+
return as(new DataView(buffer), value);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
return as(new env[type](value), index);
|
|
83
|
+
};
|
|
84
|
+
return unpair;
|
|
85
|
+
};
|
|
86
|
+
|
|
87
|
+
/**
|
|
88
|
+
* @typedef {Array<string,any>} Record a type representation
|
|
89
|
+
*/
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Returns a deserialized value from a serialized array of Records.
|
|
93
|
+
* @param {Record[]} serialized a previously serialized value.
|
|
94
|
+
* @returns {any}
|
|
95
|
+
*/
|
|
96
|
+
const deserialize = serialized => deserializer(new Map(), serialized)(0);
|
|
97
|
+
|
|
98
|
+
const EMPTY = '';
|
|
99
|
+
const {
|
|
100
|
+
toString
|
|
101
|
+
} = {};
|
|
102
|
+
const {
|
|
103
|
+
keys
|
|
104
|
+
} = Object;
|
|
105
|
+
const typeOf = value => {
|
|
106
|
+
const type = typeof value;
|
|
107
|
+
if (type !== 'object' || !value) return [PRIMITIVE, type];
|
|
108
|
+
const asString = toString.call(value).slice(8, -1);
|
|
109
|
+
switch (asString) {
|
|
110
|
+
case 'Array':
|
|
111
|
+
return [ARRAY, EMPTY];
|
|
112
|
+
case 'Object':
|
|
113
|
+
return [OBJECT, EMPTY];
|
|
114
|
+
case 'Date':
|
|
115
|
+
return [DATE, EMPTY];
|
|
116
|
+
case 'RegExp':
|
|
117
|
+
return [REGEXP, EMPTY];
|
|
118
|
+
case 'Map':
|
|
119
|
+
return [MAP, EMPTY];
|
|
120
|
+
case 'Set':
|
|
121
|
+
return [SET, EMPTY];
|
|
122
|
+
case 'DataView':
|
|
123
|
+
return [ARRAY, asString];
|
|
124
|
+
}
|
|
125
|
+
if (asString.includes('Array')) return [ARRAY, asString];
|
|
126
|
+
if (asString.includes('Error')) return [ERROR, asString];
|
|
127
|
+
return [OBJECT, asString];
|
|
128
|
+
};
|
|
129
|
+
const shouldSkip = ([TYPE, type]) => TYPE === PRIMITIVE && (type === 'function' || type === 'symbol');
|
|
130
|
+
const serializer = (strict, json, $, _) => {
|
|
131
|
+
const as = (out, value) => {
|
|
132
|
+
const index = _.push(out) - 1;
|
|
133
|
+
$.set(value, index);
|
|
134
|
+
return index;
|
|
135
|
+
};
|
|
136
|
+
const pair = value => {
|
|
137
|
+
if ($.has(value)) return $.get(value);
|
|
138
|
+
let [TYPE, type] = typeOf(value);
|
|
139
|
+
switch (TYPE) {
|
|
140
|
+
case PRIMITIVE:
|
|
141
|
+
{
|
|
142
|
+
let entry = value;
|
|
143
|
+
switch (type) {
|
|
144
|
+
case 'bigint':
|
|
145
|
+
TYPE = BIGINT;
|
|
146
|
+
entry = value.toString();
|
|
147
|
+
break;
|
|
148
|
+
case 'function':
|
|
149
|
+
case 'symbol':
|
|
150
|
+
if (strict) throw new TypeError('unable to serialize ' + type);
|
|
151
|
+
entry = null;
|
|
152
|
+
break;
|
|
153
|
+
case 'undefined':
|
|
154
|
+
return as([VOID], value);
|
|
155
|
+
}
|
|
156
|
+
return as([TYPE, entry], value);
|
|
157
|
+
}
|
|
158
|
+
case ARRAY:
|
|
159
|
+
{
|
|
160
|
+
if (type) {
|
|
161
|
+
let spread = value;
|
|
162
|
+
if (type === 'DataView') {
|
|
163
|
+
spread = new Uint8Array(value.buffer);
|
|
164
|
+
} else if (type === 'ArrayBuffer') {
|
|
165
|
+
spread = new Uint8Array(value);
|
|
166
|
+
}
|
|
167
|
+
return as([type, [...spread]], value);
|
|
168
|
+
}
|
|
169
|
+
const arr = [];
|
|
170
|
+
const index = as([TYPE, arr], value);
|
|
171
|
+
for (const entry of value) arr.push(pair(entry));
|
|
172
|
+
return index;
|
|
173
|
+
}
|
|
174
|
+
case OBJECT:
|
|
175
|
+
{
|
|
176
|
+
if (type) {
|
|
177
|
+
switch (type) {
|
|
178
|
+
case 'BigInt':
|
|
179
|
+
return as([type, value.toString()], value);
|
|
180
|
+
case 'Boolean':
|
|
181
|
+
case 'Number':
|
|
182
|
+
case 'String':
|
|
183
|
+
return as([type, value.valueOf()], value);
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
if (json && 'toJSON' in value) return pair(value.toJSON());
|
|
187
|
+
const entries = [];
|
|
188
|
+
const index = as([TYPE, entries], value);
|
|
189
|
+
for (const key of keys(value)) {
|
|
190
|
+
if (strict || !shouldSkip(typeOf(value[key]))) entries.push([pair(key), pair(value[key])]);
|
|
191
|
+
}
|
|
192
|
+
return index;
|
|
193
|
+
}
|
|
194
|
+
case DATE:
|
|
195
|
+
return as([TYPE, value.toISOString()], value);
|
|
196
|
+
case REGEXP:
|
|
197
|
+
{
|
|
198
|
+
const {
|
|
199
|
+
source,
|
|
200
|
+
flags
|
|
201
|
+
} = value;
|
|
202
|
+
return as([TYPE, {
|
|
203
|
+
source,
|
|
204
|
+
flags
|
|
205
|
+
}], value);
|
|
206
|
+
}
|
|
207
|
+
case MAP:
|
|
208
|
+
{
|
|
209
|
+
const entries = [];
|
|
210
|
+
const index = as([TYPE, entries], value);
|
|
211
|
+
for (const [key, entry] of value) {
|
|
212
|
+
if (strict || !(shouldSkip(typeOf(key)) || shouldSkip(typeOf(entry)))) entries.push([pair(key), pair(entry)]);
|
|
213
|
+
}
|
|
214
|
+
return index;
|
|
215
|
+
}
|
|
216
|
+
case SET:
|
|
217
|
+
{
|
|
218
|
+
const entries = [];
|
|
219
|
+
const index = as([TYPE, entries], value);
|
|
220
|
+
for (const entry of value) {
|
|
221
|
+
if (strict || !shouldSkip(typeOf(entry))) entries.push(pair(entry));
|
|
222
|
+
}
|
|
223
|
+
return index;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
const {
|
|
227
|
+
message
|
|
228
|
+
} = value;
|
|
229
|
+
return as([TYPE, {
|
|
230
|
+
name: type,
|
|
231
|
+
message
|
|
232
|
+
}], value);
|
|
233
|
+
};
|
|
234
|
+
return pair;
|
|
235
|
+
};
|
|
236
|
+
|
|
237
|
+
/**
|
|
238
|
+
* @typedef {Array<string,any>} Record a type representation
|
|
239
|
+
*/
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* Returns an array of serialized Records.
|
|
243
|
+
* @param {any} value a serializable value.
|
|
244
|
+
* @param {{json?: boolean, lossy?: boolean}?} options an object with a `lossy` or `json` property that,
|
|
245
|
+
* if `true`, will not throw errors on incompatible types, and behave more
|
|
246
|
+
* like JSON stringify would behave. Symbol and Function will be discarded.
|
|
247
|
+
* @returns {Record[]}
|
|
248
|
+
*/
|
|
249
|
+
const serialize = (value, {
|
|
250
|
+
json,
|
|
251
|
+
lossy
|
|
252
|
+
} = {}) => {
|
|
253
|
+
const _ = [];
|
|
254
|
+
return serializer(!(json || lossy), !!json, new Map(), _)(value), _;
|
|
255
|
+
};
|
|
256
|
+
|
|
257
|
+
/**
|
|
258
|
+
* @typedef {Array<string,any>} Record a type representation
|
|
259
|
+
*/
|
|
260
|
+
|
|
261
|
+
/**
|
|
262
|
+
* Returns an array of serialized Records.
|
|
263
|
+
* @param {any} any a serializable value.
|
|
264
|
+
* @param {{transfer?: any[], json?: boolean, lossy?: boolean}?} options an object with
|
|
265
|
+
* a transfer option (ignored when polyfilled) and/or non standard fields that
|
|
266
|
+
* fallback to the polyfill if present.
|
|
267
|
+
* @returns {Record[]}
|
|
268
|
+
*/
|
|
269
|
+
var structuredClone$1 = typeof structuredClone === "function" ? /* c8 ignore start */
|
|
270
|
+
(any, options) => options && ('json' in options || 'lossy' in options) ? deserialize(serialize(any, options)) : structuredClone(any) : (any, options) => deserialize(serialize(any, options));
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* @typedef {import('unist').Node} Node
|
|
274
|
+
* @typedef {import('unist').Point} Point
|
|
275
|
+
* @typedef {import('unist').Position} Position
|
|
276
|
+
*/
|
|
277
|
+
|
|
278
|
+
/**
|
|
279
|
+
* @typedef NodeLike
|
|
280
|
+
* @property {string} type
|
|
281
|
+
* @property {PositionLike | null | undefined} [position]
|
|
282
|
+
*
|
|
283
|
+
* @typedef PositionLike
|
|
284
|
+
* @property {PointLike | null | undefined} [start]
|
|
285
|
+
* @property {PointLike | null | undefined} [end]
|
|
286
|
+
*
|
|
287
|
+
* @typedef PointLike
|
|
288
|
+
* @property {number | null | undefined} [line]
|
|
289
|
+
* @property {number | null | undefined} [column]
|
|
290
|
+
* @property {number | null | undefined} [offset]
|
|
291
|
+
*/
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* Get the ending point of `node`.
|
|
295
|
+
*
|
|
296
|
+
* @param node
|
|
297
|
+
* Node.
|
|
298
|
+
* @returns
|
|
299
|
+
* Point.
|
|
300
|
+
*/
|
|
301
|
+
const pointEnd = point('end');
|
|
302
|
+
|
|
303
|
+
/**
|
|
304
|
+
* Get the starting point of `node`.
|
|
305
|
+
*
|
|
306
|
+
* @param node
|
|
307
|
+
* Node.
|
|
308
|
+
* @returns
|
|
309
|
+
* Point.
|
|
310
|
+
*/
|
|
311
|
+
const pointStart = point('start');
|
|
312
|
+
|
|
313
|
+
/**
|
|
314
|
+
* Get the positional info of `node`.
|
|
315
|
+
*
|
|
316
|
+
* @param {'end' | 'start'} type
|
|
317
|
+
* Side.
|
|
318
|
+
* @returns
|
|
319
|
+
* Getter.
|
|
320
|
+
*/
|
|
321
|
+
function point(type) {
|
|
322
|
+
return point;
|
|
323
|
+
|
|
324
|
+
/**
|
|
325
|
+
* Get the point info of `node` at a bound side.
|
|
326
|
+
*
|
|
327
|
+
* @param {Node | NodeLike | null | undefined} [node]
|
|
328
|
+
* @returns {Point | undefined}
|
|
329
|
+
*/
|
|
330
|
+
function point(node) {
|
|
331
|
+
const point = node && node.position && node.position[type] || {};
|
|
332
|
+
if (typeof point.line === 'number' && point.line > 0 && typeof point.column === 'number' && point.column > 0) {
|
|
333
|
+
return {
|
|
334
|
+
line: point.line,
|
|
335
|
+
column: point.column,
|
|
336
|
+
offset: typeof point.offset === 'number' && point.offset > -1 ? point.offset : undefined
|
|
337
|
+
};
|
|
338
|
+
}
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
/**
|
|
343
|
+
* Get the positional info of `node`.
|
|
344
|
+
*
|
|
345
|
+
* @param {Node | NodeLike | null | undefined} [node]
|
|
346
|
+
* Node.
|
|
347
|
+
* @returns {Position | undefined}
|
|
348
|
+
* Position.
|
|
349
|
+
*/
|
|
350
|
+
function position(node) {
|
|
351
|
+
const start = pointStart(node);
|
|
352
|
+
const end = pointEnd(node);
|
|
353
|
+
if (start && end) {
|
|
354
|
+
return {
|
|
355
|
+
start,
|
|
356
|
+
end
|
|
357
|
+
};
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
export { pointEnd as a, position as b, pointStart as p, structuredClone$1 as s };
|
|
362
|
+
//# sourceMappingURL=index-DP_Su7Zc.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-DP_Su7Zc.js","sources":["../../../node_modules/.pnpm/@ungap+structured-clone@1.3.0/node_modules/@ungap/structured-clone/esm/types.js","../../../node_modules/.pnpm/@ungap+structured-clone@1.3.0/node_modules/@ungap/structured-clone/esm/deserialize.js","../../../node_modules/.pnpm/@ungap+structured-clone@1.3.0/node_modules/@ungap/structured-clone/esm/serialize.js","../../../node_modules/.pnpm/@ungap+structured-clone@1.3.0/node_modules/@ungap/structured-clone/esm/index.js","../../../node_modules/.pnpm/unist-util-position@5.0.0/node_modules/unist-util-position/lib/index.js"],"sourcesContent":["export const VOID = -1;\nexport const PRIMITIVE = 0;\nexport const ARRAY = 1;\nexport const OBJECT = 2;\nexport const DATE = 3;\nexport const REGEXP = 4;\nexport const MAP = 5;\nexport const SET = 6;\nexport const ERROR = 7;\nexport const BIGINT = 8;\n// export const SYMBOL = 9;\n","import {\n VOID, PRIMITIVE,\n ARRAY, OBJECT,\n DATE, REGEXP, MAP, SET,\n ERROR, BIGINT\n} from './types.js';\n\nconst env = typeof self === 'object' ? self : globalThis;\n\nconst deserializer = ($, _) => {\n const as = (out, index) => {\n $.set(index, out);\n return out;\n };\n\n const unpair = index => {\n if ($.has(index))\n return $.get(index);\n\n const [type, value] = _[index];\n switch (type) {\n case PRIMITIVE:\n case VOID:\n return as(value, index);\n case ARRAY: {\n const arr = as([], index);\n for (const index of value)\n arr.push(unpair(index));\n return arr;\n }\n case OBJECT: {\n const object = as({}, index);\n for (const [key, index] of value)\n object[unpair(key)] = unpair(index);\n return object;\n }\n case DATE:\n return as(new Date(value), index);\n case REGEXP: {\n const {source, flags} = value;\n return as(new RegExp(source, flags), index);\n }\n case MAP: {\n const map = as(new Map, index);\n for (const [key, index] of value)\n map.set(unpair(key), unpair(index));\n return map;\n }\n case SET: {\n const set = as(new Set, index);\n for (const index of value)\n set.add(unpair(index));\n return set;\n }\n case ERROR: {\n const {name, message} = value;\n return as(new env[name](message), index);\n }\n case BIGINT:\n return as(BigInt(value), index);\n case 'BigInt':\n return as(Object(BigInt(value)), index);\n case 'ArrayBuffer':\n return as(new Uint8Array(value).buffer, value);\n case 'DataView': {\n const { buffer } = new Uint8Array(value);\n return as(new DataView(buffer), value);\n }\n }\n return as(new env[type](value), index);\n };\n\n return unpair;\n};\n\n/**\n * @typedef {Array<string,any>} Record a type representation\n */\n\n/**\n * Returns a deserialized value from a serialized array of Records.\n * @param {Record[]} serialized a previously serialized value.\n * @returns {any}\n */\nexport const deserialize = serialized => deserializer(new Map, serialized)(0);\n","import {\n VOID, PRIMITIVE,\n ARRAY, OBJECT,\n DATE, REGEXP, MAP, SET,\n ERROR, BIGINT\n} from './types.js';\n\nconst EMPTY = '';\n\nconst {toString} = {};\nconst {keys} = Object;\n\nconst typeOf = value => {\n const type = typeof value;\n if (type !== 'object' || !value)\n return [PRIMITIVE, type];\n\n const asString = toString.call(value).slice(8, -1);\n switch (asString) {\n case 'Array':\n return [ARRAY, EMPTY];\n case 'Object':\n return [OBJECT, EMPTY];\n case 'Date':\n return [DATE, EMPTY];\n case 'RegExp':\n return [REGEXP, EMPTY];\n case 'Map':\n return [MAP, EMPTY];\n case 'Set':\n return [SET, EMPTY];\n case 'DataView':\n return [ARRAY, asString];\n }\n\n if (asString.includes('Array'))\n return [ARRAY, asString];\n\n if (asString.includes('Error'))\n return [ERROR, asString];\n\n return [OBJECT, asString];\n};\n\nconst shouldSkip = ([TYPE, type]) => (\n TYPE === PRIMITIVE &&\n (type === 'function' || type === 'symbol')\n);\n\nconst serializer = (strict, json, $, _) => {\n\n const as = (out, value) => {\n const index = _.push(out) - 1;\n $.set(value, index);\n return index;\n };\n\n const pair = value => {\n if ($.has(value))\n return $.get(value);\n\n let [TYPE, type] = typeOf(value);\n switch (TYPE) {\n case PRIMITIVE: {\n let entry = value;\n switch (type) {\n case 'bigint':\n TYPE = BIGINT;\n entry = value.toString();\n break;\n case 'function':\n case 'symbol':\n if (strict)\n throw new TypeError('unable to serialize ' + type);\n entry = null;\n break;\n case 'undefined':\n return as([VOID], value);\n }\n return as([TYPE, entry], value);\n }\n case ARRAY: {\n if (type) {\n let spread = value;\n if (type === 'DataView') {\n spread = new Uint8Array(value.buffer);\n }\n else if (type === 'ArrayBuffer') {\n spread = new Uint8Array(value);\n }\n return as([type, [...spread]], value);\n }\n\n const arr = [];\n const index = as([TYPE, arr], value);\n for (const entry of value)\n arr.push(pair(entry));\n return index;\n }\n case OBJECT: {\n if (type) {\n switch (type) {\n case 'BigInt':\n return as([type, value.toString()], value);\n case 'Boolean':\n case 'Number':\n case 'String':\n return as([type, value.valueOf()], value);\n }\n }\n\n if (json && ('toJSON' in value))\n return pair(value.toJSON());\n\n const entries = [];\n const index = as([TYPE, entries], value);\n for (const key of keys(value)) {\n if (strict || !shouldSkip(typeOf(value[key])))\n entries.push([pair(key), pair(value[key])]);\n }\n return index;\n }\n case DATE:\n return as([TYPE, value.toISOString()], value);\n case REGEXP: {\n const {source, flags} = value;\n return as([TYPE, {source, flags}], value);\n }\n case MAP: {\n const entries = [];\n const index = as([TYPE, entries], value);\n for (const [key, entry] of value) {\n if (strict || !(shouldSkip(typeOf(key)) || shouldSkip(typeOf(entry))))\n entries.push([pair(key), pair(entry)]);\n }\n return index;\n }\n case SET: {\n const entries = [];\n const index = as([TYPE, entries], value);\n for (const entry of value) {\n if (strict || !shouldSkip(typeOf(entry)))\n entries.push(pair(entry));\n }\n return index;\n }\n }\n\n const {message} = value;\n return as([TYPE, {name: type, message}], value);\n };\n\n return pair;\n};\n\n/**\n * @typedef {Array<string,any>} Record a type representation\n */\n\n/**\n * Returns an array of serialized Records.\n * @param {any} value a serializable value.\n * @param {{json?: boolean, lossy?: boolean}?} options an object with a `lossy` or `json` property that,\n * if `true`, will not throw errors on incompatible types, and behave more\n * like JSON stringify would behave. Symbol and Function will be discarded.\n * @returns {Record[]}\n */\n export const serialize = (value, {json, lossy} = {}) => {\n const _ = [];\n return serializer(!(json || lossy), !!json, new Map, _)(value), _;\n};\n","import {deserialize} from './deserialize.js';\nimport {serialize} from './serialize.js';\n\n/**\n * @typedef {Array<string,any>} Record a type representation\n */\n\n/**\n * Returns an array of serialized Records.\n * @param {any} any a serializable value.\n * @param {{transfer?: any[], json?: boolean, lossy?: boolean}?} options an object with\n * a transfer option (ignored when polyfilled) and/or non standard fields that\n * fallback to the polyfill if present.\n * @returns {Record[]}\n */\nexport default typeof structuredClone === \"function\" ?\n /* c8 ignore start */\n (any, options) => (\n options && ('json' in options || 'lossy' in options) ?\n deserialize(serialize(any, options)) : structuredClone(any)\n ) :\n (any, options) => deserialize(serialize(any, options));\n /* c8 ignore stop */\n\nexport {deserialize, serialize};\n","/**\n * @typedef {import('unist').Node} Node\n * @typedef {import('unist').Point} Point\n * @typedef {import('unist').Position} Position\n */\n\n/**\n * @typedef NodeLike\n * @property {string} type\n * @property {PositionLike | null | undefined} [position]\n *\n * @typedef PositionLike\n * @property {PointLike | null | undefined} [start]\n * @property {PointLike | null | undefined} [end]\n *\n * @typedef PointLike\n * @property {number | null | undefined} [line]\n * @property {number | null | undefined} [column]\n * @property {number | null | undefined} [offset]\n */\n\n/**\n * Get the ending point of `node`.\n *\n * @param node\n * Node.\n * @returns\n * Point.\n */\nexport const pointEnd = point('end')\n\n/**\n * Get the starting point of `node`.\n *\n * @param node\n * Node.\n * @returns\n * Point.\n */\nexport const pointStart = point('start')\n\n/**\n * Get the positional info of `node`.\n *\n * @param {'end' | 'start'} type\n * Side.\n * @returns\n * Getter.\n */\nfunction point(type) {\n return point\n\n /**\n * Get the point info of `node` at a bound side.\n *\n * @param {Node | NodeLike | null | undefined} [node]\n * @returns {Point | undefined}\n */\n function point(node) {\n const point = (node && node.position && node.position[type]) || {}\n\n if (\n typeof point.line === 'number' &&\n point.line > 0 &&\n typeof point.column === 'number' &&\n point.column > 0\n ) {\n return {\n line: point.line,\n column: point.column,\n offset:\n typeof point.offset === 'number' && point.offset > -1\n ? point.offset\n : undefined\n }\n }\n }\n}\n\n/**\n * Get the positional info of `node`.\n *\n * @param {Node | NodeLike | null | undefined} [node]\n * Node.\n * @returns {Position | undefined}\n * Position.\n */\nexport function position(node) {\n const start = pointStart(node)\n const end = pointEnd(node)\n\n if (start && end) {\n return {start, end}\n }\n}\n"],"names":["VOID","PRIMITIVE","ARRAY","OBJECT","DATE","REGEXP","MAP","SET","ERROR","BIGINT","env","self","globalThis","deserializer","$","_","as","out","index","set","unpair","has","get","type","value","arr","push","object","key","Date","source","flags","RegExp","map","Map","Set","add","name","message","BigInt","Object","Uint8Array","buffer","DataView","deserialize","serialized","EMPTY","toString","keys","typeOf","asString","call","slice","includes","shouldSkip","TYPE","serializer","strict","json","pair","entry","TypeError","spread","valueOf","toJSON","entries","toISOString","serialize","lossy","structuredClone","any","options","pointEnd","point","pointStart","node","position","line","column","offset","undefined","start","end"],"mappings":"AAAO,MAAMA,IAAI,GAAS,EAAE;AACrB,MAAMC,SAAS,GAAI,CAAC;AACpB,MAAMC,KAAK,GAAQ,CAAC;AACpB,MAAMC,MAAM,GAAO,CAAC;AACpB,MAAMC,IAAI,GAAS,CAAC;AACpB,MAAMC,MAAM,GAAO,CAAC;AACpB,MAAMC,GAAG,GAAU,CAAC;AACpB,MAAMC,GAAG,GAAU,CAAC;AACpB,MAAMC,KAAK,GAAQ,CAAC;AACpB,MAAMC,MAAM,GAAO,CAAC;AAC3B;;ACHA,MAAMC,GAAG,GAAG,OAAOC,IAAI,KAAK,QAAQ,GAAGA,IAAI,GAAGC,UAAU;AAExD,MAAMC,YAAY,GAAGA,CAACC,CAAC,EAAEC,CAAC,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