mirror of
https://github.com/hanzoai/tsgo.git
synced 2026-10-30 19:37:15 +00:00
19 lines
578 B
Plaintext
19 lines
578 B
Plaintext
type.ts(7,28): error TS2464: A computed property name must be of type 'string', 'number', 'symbol', or 'any'.
|
|
|
|
|
|
==== type.ts (1 errors) ====
|
|
export namespace Foo {
|
|
export enum Enum {
|
|
A = "a",
|
|
B = "b",
|
|
}
|
|
}
|
|
export type Type = { x?: { [Foo.Enum]: 0 } };
|
|
~~~~~~~~~~
|
|
!!! error TS2464: A computed property name must be of type 'string', 'number', 'symbol', or 'any'.
|
|
|
|
==== index.ts (0 errors) ====
|
|
import { type Type } from "./type";
|
|
|
|
export const foo = { ...({} as Type) };
|
|
|