Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface HomeAPI

Interface that contains functions for integrating with Home.

Hierarchy

  • HomeAPI

Index

Methods

deregister

  • deregister(providerId: string): Promise<void>
  • Deregister a provider.

    import { Home , CLIProvider } from "@openfin/workspace";

    import { fetchMySearchResults } from "./my-fetch-implementation";

    const myCLIProvider: CLIProvider = {
    name: "my-cli-provider",
    title: "My CLI Provider",
    icon: "https://google.com/favicon.ico",
    onUserInput: (req) => fetchMySearchResults(req.query)
    };

    // Register and do some work with the provider

    const deregister = async () => {
    await Home.deregister("my-cli-provider");
    }

    Parameters

    • providerId: string

      the name of the provider.

    Returns Promise<void>

hide

  • hide(): Promise<void>
  • Hide the Home UI.

    import { Home } from './home'

    const hide = async () => {
    await Home.hide();
    // Do thing after hide
    }

    Returns Promise<void>

register

  • Register a provider that can return search results to Home.

    import { Home, CLIProvider } from "@openfin/workspace";

    import { fetchMySearchResults } from "./my-fetch-implementation";

    const myCLIProvider: CLIProvider = {
    name: "my-cli-provider",
    title: "My CLI Provider",
    icon: "https://google.com/favicon.ico",
    onUserInput: (req) => fetchMySearchResults(req.query)
    };

    const register = async () => {
    await Home.register(myCLIProvider);
    }

    Parameters

    Returns Promise<void>

show

  • show(): Promise<void>
  • Show the Home UI.

    import { Home } from './home'

    const show = async () => {
    await Home.show();
    // Do thing after show
    }

    Returns Promise<void>

Generated using TypeDoc