TS8030
On this page

TS8030

Front-end code SYNTAX

A TypeScript parse error in a "use typeshade" file, such as an unclosed parenthesis, a missing brace or an unexpected token. The file is not lowered or emitted. The language service shows TypeScript's own syntactic diagnostic in its place.

The registry has no documentation comment for this constant, so the line above is written by this site from the messages the compiler raises it with.

The registry text and every compiler message on these pages are the compiler's own English.

Example

example.shade.ts
"use typeshade"
@fragment
export function main(uv: location<0, vec2>): vec4 {
return vec4(uv, 0., 1.
}

Compiled at build time against the pinned compiler, this program gets:

TS8030 error, line 6: ',' expected.

How to fix it

The same program, corrected. It compiles with no diagnostic.

example.shade.ts
"use typeshade"
@fragment
export function main(uv: location<0, vec2>): vec4 {
return vec4(uv, 0., 1.)
}

The rule this enforces

Rule 10.1 Test
A "use typeshade" file must not spell a WGSL enable or requires statement.

See also

Source

Where the compiler raises this code at commit af54ddad5, one line per file:

Edit this page Report a problem