# 関連ページ

$lsx()

## TL;DR

- こういう使い方はしない
    ```TypeScript
    someProperty: EventEmitter＜any＞ = someEmitter;
    someProperty.subscribe();
    ```
- EventEmitterはあくまで `@Output` を使った data binding で(emittionを実現するための実装がRxJSかどうかを知らずに)暗黙的に使用するべき、というはなし

## 参考文献

- [AngularのサービスクラスでEventEmitterを使ってはいけない](https://qiita.com/musou1500/items/941464943b547ca7674f)
- [What is the proper use of an EventEmitter?](https://stackoverflow.com/a/36076701)
- [Angular Docs/基礎ガイド/コンポーネント＆テンプレート/コンポーネントの相互作用#親が子のイベントをリッスンする](https://angular.jp/guide/component-interaction#%E8%A6%AA%E3%81%8C%E5%AD%90%E3%81%AE%E3%82%A4%E3%83%99%E3%83%B3%E3%83%88%E3%82%92%E3%83%AA%E3%83%83%E3%82%B9%E3%83%B3%E3%81%99%E3%82%8B)

---

## Page Navigation

- Canonical URL: https://tips.weseek.co.jp/Tips/Angular/EventEmitterはSubscribeしちゃだめです
- Permalink: https://tips.weseek.co.jp/5fb745b1a1ba4200489a4a4e
- Parent: [Angular](/65069da24603e7ff39a6b3d6.md)
- Children: 0 total
- Total descendants: 0
- Siblings: 4 total
  - [AOTコンパイル](/5fb74a31a1ba4200489a4b04.md)
  - [RouterModule を import しているモジュールの注意点](/5fb74655a1ba4200489a4a61.md)
  - [splitting chunk に関するメモ](/5fb74a94a1ba4200489a4b0f.md)
  - [コンポーネントのメソッドをブラウザの開発者コンソールから呼び出す](/5fb746c1a1ba4200489a4a76.md)
- Last updated: 2020-11-20T04:52:30.587Z by takuya
- Full page listing (all children regardless of count): https://tips.weseek.co.jp/_api/v3/page-listing/children?id=5fb745b1a1ba4200489a4a4e
