mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
a7cb03e120
Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: jakebailey <[email protected]>
49 lines
1.2 KiB
Plaintext
49 lines
1.2 KiB
Plaintext
b.ts(22,5): error TS1005: '}' expected.
|
|
b.ts(23,1): error TS1128: Declaration or statement expected.
|
|
b.ts(23,2): error TS1128: Declaration or statement expected.
|
|
b.ts(27,18): error TS1478: Identifier or string literal expected.
|
|
|
|
|
|
==== a.json (0 errors) ====
|
|
{ "key": "value" }
|
|
|
|
==== b.ts (4 errors) ====
|
|
declare global {
|
|
interface ImportAttributes {
|
|
type: "json"
|
|
}
|
|
}
|
|
|
|
export type Test1 = typeof import("./a.json", {
|
|
with: {
|
|
type: "json"
|
|
},
|
|
});
|
|
|
|
export type Test2 = typeof import("./a.json", {
|
|
with: {
|
|
type: "json",
|
|
}
|
|
});
|
|
|
|
export type Test3 = typeof import("./a.json", {
|
|
with: {
|
|
type: "json"
|
|
},,
|
|
~
|
|
!!! error TS1005: '}' expected.
|
|
!!! related TS1007 b.ts:19:47: The parser expected to find a '}' to match the '{' token here.
|
|
});
|
|
~
|
|
!!! error TS1128: Declaration or statement expected.
|
|
~
|
|
!!! error TS1128: Declaration or statement expected.
|
|
|
|
export type Test4 = typeof import("./a.json", {
|
|
with: {
|
|
type: "json",,
|
|
~
|
|
!!! error TS1478: Identifier or string literal expected.
|
|
}
|
|
});
|
|
|