
import * as _$react from "react";
import { ReactNode } from "react";

//#region src/utils/intersperse.d.ts
/**
 * Given an array of items, place an item between each of the original values with either a constant
 * value or the result of a function which knows the index it is being inserted before.
 *
 * @example
 * const ANIMALS = ["Lions", "Tigers", "Bears"];
 * const animalesInterspersedWithAmpersands = intersperse(ANIMALS, "&");
 * // ["Lions", "&", "Tigers", "&", "Bears"]
 * console.log(animalesInterspersedWithAmpersands.join(" ") + '. OH MY!');
 */
declare const intersperse: <T>(list: Array<T>, inter: T | ((index: number) => T)) => T[];
/**
 * Given ReactNode, if it is a list of children nodes, place a new React node between each of the
 * original nodes with either a constant ReactElement or the result of a function which knows the
 * index it is being inserted before.
 *
 * @example
 * const SplitParagraphsWithHorizontalRule = ({ paragraphs }: { paragraphs: string[] }) => {
 *   const paragraphNodes =  paragraphs.map((str) => <p>{str}</p>);
 *
 *   return (<div>
 *     {intersperseReactChildren(paragraphNodes, <hr />)}
 *   </div>);
 * }
 */
declare const intersperseReactChildren: (children: ReactNode, inter: ReactNode | ((index: number) => ReactNode)) => (string | number | bigint | _$react.ReactElement<unknown, string | _$react.JSXElementConstructor<any>> | Iterable<ReactNode> | _$react.ReactPortal | Promise<string | number | bigint | boolean | _$react.ReactPortal | _$react.ReactElement<unknown, string | _$react.JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | null)[];
//#endregion
export { intersperse, intersperseReactChildren };