如何在 Quokka 執行 RxJS ? (VS Code)

栏目: 编程语言 · 发布时间: 7年前

内容简介:RxJS 是 JavaScript 以 FP 解決VS Code 1.31.0Quokka 1.0.182

RxJS 是 JavaScript 以 FP 解決 非同步 的神兵利器,透過 Quokka,我們可以更快速測試與學習 RxJS。

Version

VS Code 1.31.0

Quokka 1.0.182

Quokka

import { of } from 'rxjs';
import { startWith } from 'rxjs/operators';

of("from source")
  .pipe(startWith("first", "second"))
  .subscribe(x => console.log(x));

從 RxJS 官網 startWith() 的範例程式。

如何在 Quokka 執行 RxJS ? (VS Code)

  1. Quokka 抱怨找不到 rxjs 這個 module
  2. + 滑鼠點擊 Install "rxjs" package for the current quokka file 安裝 RxJS

如何在 Quokka 執行 RxJS ? (VS Code)

  1. 安裝完 RxJS,結果就出來了

Conclusion

  • 有了 Quokka,我們就能在熟悉的 VS Code 測試與學習 RxJS,非常方便

以上就是本文的全部内容,希望本文的内容对大家的学习或者工作能带来一定的帮助,也希望大家多多支持 码农网

查看所有标签

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Programming in Haskell

Programming in Haskell

Graham Hutton / Cambridge University Press / 2007-1-18 / GBP 34.99

Haskell is one of the leading languages for teaching functional programming, enabling students to write simpler and cleaner code, and to learn how to structure and reason about programs. This introduc......一起来看看 《Programming in Haskell》 这本书的介绍吧!

Base64 编码/解码
Base64 编码/解码

Base64 编码/解码

MD5 加密
MD5 加密

MD5 加密工具

RGB HSV 转换
RGB HSV 转换

RGB HSV 互转工具