Files
flipper/flipper-js-client-sdk
dependabot[bot] ae88f5d200 Bump eslint-plugin-flowtype from 5.4.0 to 5.7.1 in /flipper-js-client-sdk (#2203)
Summary:
Bumps [eslint-plugin-flowtype](https://github.com/gajus/eslint-plugin-flowtype) from 5.4.0 to 5.7.1.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/gajus/eslint-plugin-flowtype/releases">eslint-plugin-flowtype's releases</a>.</em></p>
<blockquote>
<h2>v5.7.1</h2>
<h2><a href="https://github.com/gajus/eslint-plugin-flowtype/compare/v5.7.0...v5.7.1">5.7.1</a> (2021-04-16)</h2>
<h3>Bug Fixes</h3>
<ul>
<li>fix read-only React props error position (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/478">https://github.com/facebook/flipper/issues/478</a>) (<a href="0488fcbaad">0488fcb</a>)</li>
<li>support union type in React react-only props rule (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/477">https://github.com/facebook/flipper/issues/477</a>) (<a href="7cabcda48a">7cabcda</a>)</li>
</ul>
<h2>v5.7.0</h2>
<h1><a href="https://github.com/gajus/eslint-plugin-flowtype/compare/v5.6.0...v5.7.0">5.7.0</a> (2021-04-12)</h1>
<h3>Features</h3>
<ul>
<li>Added rule to enforce quotes type (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/475">https://github.com/facebook/flipper/issues/475</a>) (<a href="8008f78cf9">8008f78</a>)</li>
</ul>
<h2>v5.6.0</h2>
<h1><a href="https://github.com/gajus/eslint-plugin-flowtype/compare/v5.5.0...v5.6.0">5.6.0</a> (2021-04-06)</h1>
<h3>Features</h3>
<ul>
<li>migrate a new rule 'use-read-only-spread' (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/472">https://github.com/facebook/flipper/issues/472</a>) (<a href="998eb5a315">998eb5a</a>)</li>
</ul>
<h2>v5.5.0</h2>
<h1><a href="https://github.com/gajus/eslint-plugin-flowtype/compare/v5.4.0...v5.5.0">5.5.0</a> (2021-04-05)</h1>
<h3>Features</h3>
<ul>
<li>add support for implicit exact Flow types (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/471">https://github.com/facebook/flipper/issues/471</a>) (<a href="6d5362bf2e">6d5362b</a>)</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="7cabcda48a"><code>7cabcda</code></a> fix: support union type in React react-only props rule (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/477">https://github.com/facebook/flipper/issues/477</a>)</li>
<li><a href="0488fcbaad"><code>0488fcb</code></a> fix: fix read-only React props error position (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/478">https://github.com/facebook/flipper/issues/478</a>)</li>
<li><a href="8008f78cf9"><code>8008f78</code></a> feat: Added rule to enforce quotes type (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/475">https://github.com/facebook/flipper/issues/475</a>)</li>
<li><a href="998eb5a315"><code>998eb5a</code></a> feat: migrate a new rule 'use-read-only-spread' (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/472">https://github.com/facebook/flipper/issues/472</a>)</li>
<li><a href="6d5362bf2e"><code>6d5362b</code></a> feat: add support for implicit exact Flow types (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/471">https://github.com/facebook/flipper/issues/471</a>)</li>
<li><a href="8fd60d6729"><code>8fd60d6</code></a> docs: regenerate README.md (<a href="https://github-redirect.dependabot.com/gajus/eslint-plugin-flowtype/issues/470">https://github.com/facebook/flipper/issues/470</a>)</li>
<li>See full diff in <a href="https://github.com/gajus/eslint-plugin-flowtype/compare/v5.4.0...v5.7.1">compare view</a></li>
</ul>
</details>
<br />

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=eslint-plugin-flowtype&package-manager=npm_and_yarn&previous-version=5.4.0&new-version=5.7.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

 ---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `dependabot rebase` will rebase this PR
- `dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `dependabot merge` will merge this PR after your CI passes on it
- `dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `dependabot cancel merge` will cancel a previously requested merge and block automerging
- `dependabot reopen` will reopen this PR if it is closed
- `dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

</details>

Pull Request resolved: https://github.com/facebook/flipper/pull/2203

Reviewed By: mweststrate

Differential Revision: D27945869

Pulled By: passy

fbshipit-source-id: 3c996bb7128e9b1d9a178d133d78c52bd86a649b
2021-04-23 07:10:57 -07:00
..
2020-11-09 08:24:28 -08:00
2020-06-11 08:45:35 -07:00
2020-06-11 08:45:35 -07:00

flipper-sdk-api

SDK to build Flipper clients for JS based apps

Installation

yarn add flipper-client-sdk

Usage

Example

class SeaMammalPlugin extends AbsctractFlipperPlugin {
  getId(): string {
    return 'sea-mammals';
  }

  runInBackground(): boolean {
    return true;
  }

  newRow(row: {id: string, url: string, title: string}) {
    this.connection?.send("newRow", row)
  }
}

const flipperClient = newWebviewClient();
cosnt plugin = new SeaMammalPlugin();
flipperClient.addPlugin();
flipperClient.start('Example JS App');
plugin.newRow({id: '1', title: 'Dolphin', url: 'example.com'})