/** * Copyright © 2022 650 Industries. * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * Fork of the metro helper, but with bundle splitting support. * https://github.com/facebook/metro/blob/bbdd7d7c5e6e0feb50a9967ffae1f723c1d7c4e8/packages/metro/src/DeltaBundler/Serializers/helpers/js.js#L1 */ import type { JsOutput } from '@expo/metro/metro-transform-worker'; import type { MixedOutput, Module } from '@expo/metro/metro/DeltaBundler'; import type { SerializerOptions } from '@expo/metro/metro/DeltaBundler/types'; import type { AsyncModulePaths } from '../serializerAssets'; export type Options = Pick & { createModuleId: (module: string) => number | string; dev: boolean; includeAsyncPaths: boolean; projectRoot: string; serverRoot: string; sourceUrl?: string | null; splitChunks: boolean; skipWrapping: boolean; computedAsyncModulePaths: Record | null; }; export declare function wrapModule(module: Module, options: Options): { src: string; paths: AsyncModulePaths; }; export declare function getModuleParams(module: Module, options: Pick): { params: any[]; paths: AsyncModulePaths; }; export declare function getJsOutput(module: { output: readonly MixedOutput[]; path?: string; }): JsOutput; export declare function isJsModule(module: Module): boolean; export declare function isJsOutput(output: MixedOutput): output is MixedOutput;