ionic集成websocket

這裏使用ng ws工具, 1.安裝依賴庫 npm install ws --save 2.安裝類型定義文件 npm install @types/ws --save 3.編寫服務 創建一個websocket.service.ts包,內容如下: import { Injectable } from '@angular/core'; import { Observable } from "rxjs/O
相關文章
相關標籤/搜索