import { JSX, ReactNode } from 'react';
import { ConfigApi, ExtensionFactoryMiddleware, FrontendFeature, FrontendFeatureLoader } from '@backstage/frontend-plugin-api';
import { CreateAppRouteBinder, FrontendPluginInfoResolver } from '@backstage/frontend-app-api';
/**
 * A source of dynamically loaded frontend features.
 *
 * @public
 * @deprecated Use the {@link @backstage/frontend-plugin-api#createFrontendFeatureLoader} function instead.
 */
export interface CreateAppFeatureLoader {
    /**
     * Returns name of this loader. suitable for showing to users.
     */
    getLoaderName(): string;
    /**
     * Loads a number of features dynamically.
     */
    load(options: {
        config: ConfigApi;
    }): Promise<{
        features: FrontendFeature[];
    }>;
}
/**
 * Options for {@link createApp}.
 *
 * @public
 */
export interface CreateAppOptions {
    features?: (FrontendFeature | FrontendFeatureLoader | CreateAppFeatureLoader)[];
    configLoader?: () => Promise<{
        config: ConfigApi;
    }>;
    bindRoutes?(context: {
        bind: CreateAppRouteBinder;
    }): void;
    /**
     * The component to render while loading the app (waiting for config, features, etc)
     *
     * Is the text "Loading..." by default.
     * If set to "null" then no loading fallback component is rendered.   *
     */
    loadingComponent?: ReactNode;
    extensionFactoryMiddleware?: ExtensionFactoryMiddleware | ExtensionFactoryMiddleware[];
    pluginInfoResolver?: FrontendPluginInfoResolver;
}
/**
 * Creates a new Backstage frontend app instance. See https://backstage.io/docs/frontend-system/building-apps/index
 *
 * @public
 */
export declare function createApp(options?: CreateAppOptions): {
    createRoot(): JSX.Element;
};
