尝试使用 tsc index.ts 编译 TypeScript 代码时,如何解决以下错误?
node_modules/axios/index.d.ts:75:3 - error TS1165: A computed property name in an ambient context must refer to an expression whose type is a literal type or a 'unique symbol' type.
75 [Symbol.iterator](): IterableIterator<[string, AxiosHeaderValue]>;
~~~~~~~~~~~~~~~~~
node_modules/axios/index.d.ts:75:4 - error TS2585: 'Symbol' only refers to a type, but is being used as a value here. Do you need to change your target library? Try changing the 'lib' compiler option to es2015 or later.
75 [Symbol.iterator](): IterableIterator<[string, AxiosHeaderValue]>;
~~~~~~ …
Run Code Online (Sandbox Code Playgroud)