UNPKG

liferay-npm-bundler-preset-reactjs

Version:

liferay npm bundler preset react

36 lines (35 loc) 1.05 kB
/** * SPDX-FileCopyrightText: © 2020 Liferay, Inc. <https://liferay.com> * SPDX-License-Identifier: LGPL-3.0-or-later */ /** Babel state object view */ interface BabelState { file: { opts: { filename: string; }; }; } /** A function that returns the default value for a key */ interface DefaultValueFactory { (): any; } /** * Get an IPC value for a given Babel plugin * @param state babel plugin state argument * @param defaultValue the default value or a factory to get it if value is not set * @return the IPC value */ export declare function get(state: BabelState, defaultValue: any | DefaultValueFactory): any; /** * Set an IPC value for a given file path. * @param filePath the path of the file being processed * @param value the IPC value to set */ export declare function set(filePath: string, value: any): void; /** * Clear an IPC value for a given file path. * @param filePath the path of the file being processed */ export declare function clear(filePath: string): void; export {};