mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
25 lines
1.2 KiB
Diff
25 lines
1.2 KiB
Diff
--- old.globalThisPropertyAssignment.errors.txt
|
|
+++ new.globalThisPropertyAssignment.errors.txt
|
|
@@= skipped -0, +0 lines =@@
|
|
+globalThisPropertyAssignment.js(1,6): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
|
|
globalThisPropertyAssignment.js(4,8): error TS2339: Property 'z' does not exist on type 'Window & typeof globalThis'.
|
|
-
|
|
-
|
|
-==== globalThisPropertyAssignment.js (1 errors) ====
|
|
+globalThisPropertyAssignment.js(6,12): error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
|
|
+
|
|
+
|
|
+==== globalThisPropertyAssignment.js (3 errors) ====
|
|
this.x = 1
|
|
+ ~
|
|
+!!! error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
|
|
var y = 2
|
|
// should work in JS
|
|
window.z = 3
|
|
@@= skipped -9, +13 lines =@@
|
|
!!! error TS2339: Property 'z' does not exist on type 'Window & typeof globalThis'.
|
|
// should work in JS (even though it's a secondary declaration)
|
|
globalThis.alpha = 4
|
|
+ ~~~~~
|
|
+!!! error TS7017: Element implicitly has an 'any' type because type 'typeof globalThis' has no index signature.
|
|
|