interface IAction { type: string } interface IActionA extends IAction { a: string } interface IActionB extends IAction { b: string } const reducer = (action: IAction) { switch (action.type) { case 'a': return console.info('action a: ', action.a) // property 'a' does not exists on type IAction case 'b': return console.info('action b: ', action.b . Axios 概念 在开发中广泛使用的 Axios 调用接口, Axios 是一个基于 Promise 的 HTTP 库,可以在浏览器和 node.js 中使用。 Property 'quantity' does not exist on type 'ListModelServer[]' npm i -g rxjs-tslint rxjs-5-to-6-migrate -p tsconfig.json Imports etc have been amended as expected but now the code that worked fine with v5 of Angular/5.5 of RxJS is erroring with the error: I'm trying to create my own interface and extend the Document from Mongoose, so I did: users.types.ts import { Document, Model } from 'mongoose' export interface IUser { chatId: Number, us. Property does not exist on type 'AxiosResponse - CSDN Property 'access_token' does not exist on type 'AxiosResponse<any ... Property 'data' does not exist on type 'void'.ts(2339) --- any The getUser(), is a service that I use and the code for it is here: . 用类型断言强制通过编译 用类型断言来强制通过TS的编译 (e as any).xxx 3. Since TFactor can be a TExpression, but TExpression can also be TFactor, this problem arises. Downgrading vue-resource version should help, but then you will get vue-class-component bug #181. Property'map' does not exist on type'Observable' is reported in Angular responsive development. Typescript types do not make sense · Issue #4176 - GitHub 方法1: 指定 this 类型为 any, 但是使用 any 就失去了类型安全保障, 又得不到工具的支持, 写起来也不太雅观. I have updated code that worked fine with Angular 5.5/rxJS5.5 using the new pipe method to Angular 6/rxJS6 using the rxjs-lint package and the following commands. Property does not exist on type 'AxiosResponse '._wflynn的博客-程序员秘密 Property 'data' does not exist on type 'void | AxiosResponse<IUser>'. React Query and TypeScript | TkDodo's blog