Errors
TypeScript errors
TSxxxx compiler errors.
1,407 entries0 written pages
Showing 901 to 950 of 1,407Source: TypeScript diagnosticMessages.json
| Code | Error | Category | Page |
|---|---|---|---|
| TS2836 | Import assertions are not allowed on statements that compile to CommonJS 'require' calls. | Error | Reference |
| TS2837 | Import assertion values must be string literal expressions. | Error | Reference |
| TS2838 | All declarations of '{0}' must have identical constraints. | Error | Reference |
| TS2839 | This condition will always return '{0}' since JavaScript compares objects by reference, not value. | Error | Reference |
| TS2840 | An interface cannot extend a primitive type like '{0}'. It can only extend other named object types. | Error | Reference |
| TS2842 | '{0}' is an unused renaming of '{1}'. Did you intend to use it as a type annotation? | Error | Reference |
| TS2843 | We can only write a type for '{0}' by adding a type for the entire parameter here. | Error | Reference |
| TS2844 | Type of instance member variable '{0}' cannot reference identifier '{1}' declared in the constructor. | Error | Reference |
| TS2845 | This condition will always return '{0}'. | Error | Reference |
| TS2846 | A declaration file cannot be imported without 'import type'. Did you mean to import an implementation file '{0}' instead? | Error | Reference |
| TS2848 | The right-hand side of an 'instanceof' expression must not be an instantiation expression. | Error | Reference |
| TS2849 | Target signature provides too few arguments. Expected {0} or more, but got {1}. | Error | Reference |
| TS2850 | The initializer of a 'using' declaration must be either an object with a '[Symbol.dispose]()' method, or be 'null' or 'undefined'. | Error | Reference |
| TS2851 | The initializer of an 'await using' declaration must be either an object with a '[Symbol.asyncDispose]()' or '[Symbol.dispose]()' method,... | Error | Reference |
| TS2852 | 'await using' statements are only allowed within async functions and at the top levels of modules. | Error | Reference |
| TS2853 | 'await using' statements are only allowed at the top level of a file when that file is a module, but this file has no imports or exports.... | Error | Reference |
| TS2854 | Top-level 'await using' statements are only allowed when the 'module' option is set to 'es2022', 'esnext', 'system', 'node16', 'node18',... | Error | Reference |
| TS2855 | Class field '{0}' defined by the parent class is not accessible in the child class via super. | Error | Reference |
| TS2856 | Import attributes are not allowed on statements that compile to CommonJS 'require' calls. | Error | Reference |
| TS2857 | Import attributes cannot be used with type-only imports or exports. | Error | Reference |
| TS2858 | Import attribute values must be string literal expressions. | Error | Reference |
| TS2859 | Excessive complexity comparing types '{0}' and '{1}'. | Error | Reference |
| TS2860 | The left-hand side of an 'instanceof' expression must be assignable to the first argument of the right-hand side's '[Symbol.hasInstance]'... | Error | Reference |
| TS2861 | An object's '[Symbol.hasInstance]' method must return a boolean value for it to be used on the right-hand side of an 'instanceof'... | Error | Reference |
| TS2862 | Type '{0}' is generic and can only be indexed for reading. | Error | Reference |
| TS2863 | A class cannot extend a primitive type like '{0}'. Classes can only extend constructable values. | Error | Reference |
| TS2864 | A class cannot implement a primitive type like '{0}'. It can only implement other named object types. | Error | Reference |
| TS2865 | Import '{0}' conflicts with local value, so must be declared with a type-only import when 'isolatedModules' is enabled. | Error | Reference |
| TS2866 | Import '{0}' conflicts with global value used in this file, so must be declared with a type-only import when 'isolatedModules' is enabled. | Error | Reference |
| TS2867 | Cannot find name '{0}'. Do you need to install type definitions for Bun? Try `npm i --save-dev @types/bun`. | Error | Reference |
| TS2868 | Cannot find name '{0}'. Do you need to install type definitions for Bun? Try `npm i --save-dev @types/bun` and then add 'bun' to the types... | Error | Reference |
| TS2869 | Right operand of ?? is unreachable because the left operand is never nullish. | Error | Reference |
| TS2870 | This binary expression is never nullish. Are you missing parentheses? | Error | Reference |
| TS2871 | This expression is always nullish. | Error | Reference |
| TS2872 | This kind of expression is always truthy. | Error | Reference |
| TS2873 | This kind of expression is always falsy. | Error | Reference |
| TS2874 | This JSX tag requires '{0}' to be in scope, but it could not be found. | Error | Reference |
| TS2875 | This JSX tag requires the module path '{0}' to exist, but none could be found. Make sure you have types for the appropriate package... | Error | Reference |
| TS2876 | This relative import path is unsafe to rewrite because it looks like a file name, but actually resolves to "{0}". | Error | Reference |
| TS2877 | This import uses a '{0}' extension to resolve to an input TypeScript file, but will not be rewritten during emit because it is not a... | Error | Reference |
| TS2878 | This import path is unsafe to rewrite because it resolves to another project, and the relative path between the projects' output files is... | Error | Reference |
| TS2879 | Using JSX fragments requires fragment factory '{0}' to be in scope, but it could not be found. | Error | Reference |
| TS2880 | Import assertions have been replaced by import attributes. Use 'with' instead of 'assert'. | Error | Reference |
| TS2881 | This expression is never nullish. | Error | Reference |
| TS2882 | Cannot find module or type declarations for side-effect import of '{0}'. | Error | Reference |
| TS2883 | The inferred type of '{0}' cannot be named without a reference to '{2}' from '{1}'. This is likely not portable. A type annotation is... | Error | Reference |
| TS4000 | Import declaration '{0}' is using private name '{1}'. | Error | Reference |
| TS4002 | Type parameter '{0}' of exported class has or is using private name '{1}'. | Error | Reference |
| TS4004 | Type parameter '{0}' of exported interface has or is using private name '{1}'. | Error | Reference |
| TS4006 | Type parameter '{0}' of constructor signature from exported interface has or is using private name '{1}'. | Error | Reference |
Other families: JavaScript, Node.js, npm, React, Next.js, Vite, webpack, Jest