Assert that a type resolves to a symbol.
symbol
Type that must be a symbol
Produces a compiler error if the provided type is not a symbol. Useful for validating symbol-based APIs at compile time.
type A = AssertSymbol< symbol >; // ✓type B = AssertSymbol< string >; // ✗ TS error Copy
type A = AssertSymbol< symbol >; // ✓type B = AssertSymbol< string >; // ✗ TS error
Assert that a type resolves to a
symbol.