chore: add mobile app

This commit is contained in:
2026-02-07 22:33:02 +01:00
parent db34640acc
commit e89384ad4e
29327 changed files with 3886944 additions and 12 deletions
@@ -0,0 +1,267 @@
import commander from 'commander';
import fs from 'fs';
import path from 'path';
import { SupportedPlatform } from '../types';
export interface AutolinkingOptions {
/** Only scan direct "dependencies" of a project for React Native modules, rather than including transitive dependencies.
* @remarks
* Before SDK 54, React Native modules would only be linked if they were listed as dependencies
* of a project. However, in SDK 54+ transitive React Native modules dependencies are also
* auto-linked, unless this flag is enabled.
* @defaultValue `false`
*/
legacy_shallowReactNativeLinking: boolean;
/** Extra modules directories to search for native modules.
* @defaultValue `[]`
*/
searchPaths: string[];
/** Local native modules directory to add to autolinking.
* @defaultValue `"./modules"`
*/
nativeModulesDir: string | null;
/** Native modules to exclude from autolinking by name.
* @defaultValue `[]`
*/
exclude: string[];
/** A list of package names to opt out of prebuilt Expo modules (Android-only)
* @defaultValue `[]`
*/
buildFromSource?: string[];
/** CocoaPods flags to pass to each autolinked pod (Apple/iOS-only)
* @defaultValue `[]`
*/
flags?: Record<string, any>;
}
const isJSONObject = (x: unknown): x is Record<string, unknown> =>
x != null && typeof x === 'object';
const resolvePathMaybe = (target: unknown, basePath: string): string | null => {
if (typeof target !== 'string') {
return null;
}
let resolved = path.resolve(basePath, target);
if (fs.existsSync(resolved)) {
return resolved;
} else if ((resolved = path.resolve(target)) && fs.existsSync(target)) {
// TODO(@kitten): This is here for legacy support. However, this *will* be inconsistent
// This relies on the current working directory, and hence, can behave differently depending
// on where the command was invoked.
return target;
} else {
return null;
}
};
export const filterMapSearchPaths = (
searchPaths: unknown,
basePath: string
): string[] | undefined => {
if (Array.isArray(searchPaths)) {
return searchPaths
.map((searchPath) => resolvePathMaybe(searchPath, basePath))
.filter((searchPath) => searchPath != null);
} else {
return undefined;
}
};
const parsePackageJsonOptions = (
packageJson: Record<string, unknown>,
appRoot: string,
platform: SupportedPlatform | null | undefined
): Partial<AutolinkingOptions> => {
const expo = isJSONObject(packageJson.expo) ? packageJson.expo : null;
const autolinkingOptions = expo && isJSONObject(expo.autolinking) ? expo.autolinking : null;
let platformOptions: Record<string, unknown> | null = null;
if (platform) {
platformOptions =
autolinkingOptions && isJSONObject(autolinkingOptions[platform])
? autolinkingOptions[platform]
: null;
if (!platformOptions && platform === 'apple') {
// NOTE: `platform: 'apple'` has a fallback on `ios`. This doesn't make much sense, since apple should
// be the base option for other apple platforms, but changing this now is a breaking change
platformOptions =
autolinkingOptions && isJSONObject(autolinkingOptions.ios) ? autolinkingOptions.ios : null;
}
}
const mergedOptions = { ...autolinkingOptions, ...platformOptions };
const outputOptions: Partial<AutolinkingOptions> = {};
// legacy_shallowReactNativeLinking
if (mergedOptions.legacy_shallowReactNativeLinking != null) {
outputOptions.legacy_shallowReactNativeLinking =
!!mergedOptions.legacy_shallowReactNativeLinking;
}
// searchPaths
if (typeof mergedOptions.searchPaths === 'string' || Array.isArray(mergedOptions.searchPaths)) {
const rawSearchPaths =
typeof mergedOptions.searchPaths === 'string'
? [mergedOptions.searchPaths]
: mergedOptions.searchPaths;
outputOptions.searchPaths = filterMapSearchPaths(rawSearchPaths, appRoot);
}
// nativeModulesDir
if (typeof mergedOptions.nativeModulesDir === 'string') {
outputOptions.nativeModulesDir = resolvePathMaybe(mergedOptions.nativeModulesDir, appRoot);
}
// exclude
if (Array.isArray(mergedOptions.exclude)) {
outputOptions.exclude = mergedOptions.exclude.filter((x) => typeof x === 'string');
}
// buildFromSource
if (Array.isArray(mergedOptions.buildFromSource)) {
outputOptions.buildFromSource = mergedOptions.buildFromSource.filter(
(x) => typeof x === 'string'
);
}
// flags
if (isJSONObject(mergedOptions.flags)) {
outputOptions.flags = { ...mergedOptions.flags };
}
return outputOptions;
};
/** Common commandline arguments for autolinking commands (Not to be confused with `AutolinkingOptions` */
export interface AutolinkingCommonArguments {
projectRoot?: string | null;
// NOTE(@kitten): These are added to other `searchPaths` entries
searchPaths?: string[] | null;
// NOTE(@kitten): These are added to other `exclude` entries
exclude?: string[] | null;
platform?: SupportedPlatform | null;
}
export function registerAutolinkingArguments(command: commander.Command): commander.Command {
return command
.option<string[] | null>(
'-e, --exclude <exclude...>',
'Package names to exclude when looking up for modules.',
(value, previous) => (previous ?? []).concat(value)
)
.option(
'-p, --platform [platform]',
'The platform that the resulting modules must support. Available options: "apple", "android"',
'apple'
)
.option(
// NOTE(@kitten): For backwards-compatibility, this is still called `project-root`, but it
// really is a replacement path for the current working directory. Henceforth called `commandRoot`
'--project-root <projectRoot>',
'The path to the root of the project. Defaults to current working directory',
process.cwd()
);
}
interface ArgumentsAutolinkingOptions {
/** The root directory that will be considered the base path for all other target paths */
commandRoot: string;
/** The platform to autolink against. If not passed or unknown, no specific autolinking search logic will be applied */
platform?: SupportedPlatform;
/** Added search paths to search for native modules (Usually passed as CLI rest argument. */
extraSearchPaths?: string[];
/** Added native module names to exclude from autolined native modules (Usually passed as CLI argument) */
extraExclude?: string[];
}
const parseExtraArgumentsOptions = (
args: AutolinkingCommonArguments
): ArgumentsAutolinkingOptions => {
const cwd = process.cwd();
const platform = args.platform || undefined;
const commandRoot = resolvePathMaybe(args.projectRoot, cwd) || cwd;
const extraSearchPaths = filterMapSearchPaths(args.searchPaths, commandRoot);
const extraExclude = args.exclude?.filter((name) => typeof name === 'string');
return {
platform,
commandRoot,
extraSearchPaths,
extraExclude,
};
};
const findPackageJsonPathAsync = async (commandRoot: string | null): Promise<string> => {
const root = commandRoot || process.cwd();
for (let dir = root; path.dirname(dir) !== dir; dir = path.dirname(dir)) {
const file = path.resolve(dir, 'package.json');
if (fs.existsSync(file)) {
return file;
}
}
throw new Error(`Couldn't find "package.json" up from path "${root}"`);
};
const loadPackageJSONAsync = async (packageJsonPath: string): Promise<Record<string, unknown>> => {
const packageJsonText = await fs.promises.readFile(packageJsonPath, 'utf8');
return JSON.parse(packageJsonText);
};
export interface LinkingOptionsLoader {
getCommandRoot(): string;
getAppRoot(): Promise<string>;
getPlatformOptions<T extends SupportedPlatform | undefined>(
platform: T
): Promise<AutolinkingOptions & { platform: T }>;
getPlatformOptions(): Promise<AutolinkingOptions>;
}
export function createAutolinkingOptionsLoader(
argumentsOptions?: AutolinkingCommonArguments
): LinkingOptionsLoader {
const extraArgumentsOptions = parseExtraArgumentsOptions(argumentsOptions ?? {});
const { commandRoot } = extraArgumentsOptions;
let _packageJsonPath$: Promise<string> | undefined;
const getPackageJsonPath = () => {
return _packageJsonPath$ || (_packageJsonPath$ = findPackageJsonPathAsync(commandRoot));
};
let _packageJson$: Promise<Record<string, unknown>> | undefined;
const getPackageJson = async () =>
_packageJson$ || (_packageJson$ = loadPackageJSONAsync(await getPackageJsonPath()));
const getAppRoot = async () => path.dirname(await getPackageJsonPath());
return {
getCommandRoot: () => commandRoot,
getAppRoot,
async getPlatformOptions(platform = extraArgumentsOptions.platform) {
const packageJson = await getPackageJson();
const appRoot = await getAppRoot();
const options = parsePackageJsonOptions(packageJson, appRoot, platform);
if (extraArgumentsOptions.extraSearchPaths) {
options.searchPaths = [
...extraArgumentsOptions.extraSearchPaths,
...(options.searchPaths ?? []),
];
}
if (extraArgumentsOptions.extraExclude) {
options.exclude = [...(options.exclude ?? []), ...extraArgumentsOptions.extraExclude];
}
return {
...normalizeAutolinkingOptions(options, appRoot),
platform,
};
},
};
}
const normalizeAutolinkingOptions = (
options: Partial<AutolinkingOptions>,
appRoot: string
): AutolinkingOptions => {
return {
legacy_shallowReactNativeLinking: options.legacy_shallowReactNativeLinking ?? false,
searchPaths: options.searchPaths ?? [],
nativeModulesDir: options.nativeModulesDir
? (resolvePathMaybe(options.nativeModulesDir, appRoot) ?? null)
: (resolvePathMaybe('./modules', appRoot) ?? null),
exclude: options.exclude ?? [],
buildFromSource: options.buildFromSource,
flags: options.flags,
};
};
@@ -0,0 +1,62 @@
import commander from 'commander';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import { findModulesAsync } from '../autolinking/findModules';
import { generateModulesProviderAsync } from '../autolinking/generatePackageList';
import { resolveModulesAsync } from '../autolinking/resolveModules';
interface GenerateModulesProviderArguments extends AutolinkingCommonArguments {
target: string;
entitlement?: string;
packages?: string[] | null;
appRoot?: string;
}
/** Generates a source file listing all packages to link in the runtime */
export function generateModulesProviderCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('generate-modules-provider [searchPaths...]'))
.option(
'-t, --target <path>',
'Path to the target file, where the package list should be written to.'
)
.option('--entitlement <path>', 'Path to the Apple code signing entitlements file.')
.option(
'-p, --packages <packages...>',
'Names of the packages to include in the generated modules provider.'
)
.option('--app-root <path>', 'Path to the app root directory.')
.action(
async (searchPaths: string[] | null, commandArguments: GenerateModulesProviderArguments) => {
const platform = commandArguments.platform ?? 'apple';
const autolinkingOptionsLoader = createAutolinkingOptionsLoader({
...commandArguments,
searchPaths,
});
const autolinkingOptions = await autolinkingOptionsLoader.getPlatformOptions(platform);
const expoModulesSearchResults = await findModulesAsync({
autolinkingOptions: await autolinkingOptionsLoader.getPlatformOptions(platform),
appRoot: commandArguments.appRoot ?? (await autolinkingOptionsLoader.getAppRoot()),
});
const expoModulesResolveResults = await resolveModulesAsync(
expoModulesSearchResults,
autolinkingOptions
);
const includeModules = new Set(commandArguments.packages ?? []);
const filteredModules = expoModulesResolveResults.filter((module) =>
includeModules.has(module.packageName)
);
await generateModulesProviderAsync(filteredModules, {
platform,
targetPath: commandArguments.target,
entitlementPath: commandArguments.entitlement ?? null,
});
}
);
}
@@ -0,0 +1,67 @@
import commander from 'commander';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import { findModulesAsync } from '../autolinking/findModules';
import { generatePackageListAsync } from '../autolinking/generatePackageList';
import { resolveModulesAsync } from '../autolinking/resolveModules';
import type { ModuleDescriptor } from '../types';
interface GeneratePackageListArguments extends AutolinkingCommonArguments {
target: string;
namespace: string;
empty: boolean;
}
/** Generates a source file listing all packages to link.
* @privateRemarks
* This command is deprecated for apple platforms, use `generate-modules-provider` instead.
*/
export function generatePackageListCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('generate-package-list [searchPaths...]'))
.option(
'-t, --target <path>',
'Path to the target file, where the package list should be written to.'
)
.option(
'-n, --namespace <namespace>',
'Java package name under which the package list should be placed.'
)
.option(
'--empty',
'Whether to only generate an empty list. Might be used when the user opts-out of autolinking.',
false
)
.action(
async (searchPaths: string[] | null, commandArguments: GeneratePackageListArguments) => {
const platform = commandArguments.platform ?? 'android';
const autolinkingOptionsLoader = createAutolinkingOptionsLoader({
...commandArguments,
searchPaths,
});
let expoModulesResolveResults: ModuleDescriptor[] = [];
if (!commandArguments.empty) {
const autolinkingOptions = await autolinkingOptionsLoader.getPlatformOptions(platform);
const expoModulesSearchResults = await findModulesAsync({
autolinkingOptions: await autolinkingOptionsLoader.getPlatformOptions(platform),
appRoot: await autolinkingOptionsLoader.getAppRoot(),
});
expoModulesResolveResults = await resolveModulesAsync(
expoModulesSearchResults,
autolinkingOptions
);
}
await generatePackageListAsync(expoModulesResolveResults, {
platform,
targetPath: commandArguments.target,
namespace: commandArguments.namespace,
});
}
);
}
@@ -0,0 +1,50 @@
import commander from 'commander';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import { createReactNativeConfigAsync } from '../reactNativeConfig';
interface ReactNativeConfigArguments extends AutolinkingCommonArguments {
sourceDir?: string | null;
json?: boolean | null;
}
/** The react-native-config command (like RN CLI linking) */
export function reactNativeConfigCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('react-native-config [searchPaths...]'))
.option(
'-p, --platform [platform]',
'The platform that the resulting modules must support. Available options: "android", "ios"',
'ios'
)
.option('--source-dir <sourceDir>', 'The path to the native source directory')
.option('-j, --json', 'Output results in the plain JSON format.', () => true, false)
.action(async (searchPaths: string[] | null, commandArguments: ReactNativeConfigArguments) => {
// TODO(@kitten): Do we need to restrict this?
const platform = commandArguments.platform ?? 'ios';
if (platform !== 'android' && platform !== 'ios') {
throw new Error(`Unsupported platform: ${platform}`);
}
const autolinkingOptionsLoader = createAutolinkingOptionsLoader({
...commandArguments,
searchPaths,
});
const reactNativeConfig = await createReactNativeConfigAsync({
autolinkingOptions: await autolinkingOptionsLoader.getPlatformOptions(platform),
appRoot: await autolinkingOptionsLoader.getAppRoot(),
// NOTE(@kitten): This is currently not validated, and assumed to be validated later
sourceDir: commandArguments.sourceDir ?? undefined,
});
if (commandArguments.json) {
console.log(JSON.stringify(reactNativeConfig));
} else {
console.log(require('util').inspect(reactNativeConfig, false, null, true));
}
});
}
@@ -0,0 +1,101 @@
import commander from 'commander';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import { findModulesAsync } from '../autolinking/findModules';
import { getConfiguration } from '../autolinking/getConfiguration';
import {
resolveModulesAsync,
resolveExtraBuildDependenciesAsync,
} from '../autolinking/resolveModules';
import type {
ModuleDescriptor,
CommonNativeModuleDescriptor,
ModuleDescriptorAndroid,
ModuleDescriptorIos,
} from '../types';
function hasCoreFeatures(
module: ModuleDescriptor
): module is ModuleDescriptorAndroid | ModuleDescriptorIos {
return (module as CommonNativeModuleDescriptor).coreFeatures !== undefined;
}
interface ResolveArguments extends AutolinkingCommonArguments {
json?: boolean | null;
}
/** Searches for available expo modules and resolves the results for given platform. */
export function resolveCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('resolve [searchPaths...]'))
.option('-j, --json', 'Output results in the plain JSON format.', () => true, false)
.action(async (searchPaths: string[] | null, commandArguments: ResolveArguments) => {
const platform = commandArguments.platform ?? 'apple';
const autolinkingOptionsLoader = createAutolinkingOptionsLoader({
...commandArguments,
searchPaths,
});
const autolinkingOptions = await autolinkingOptionsLoader.getPlatformOptions(platform);
const appRoot = await autolinkingOptionsLoader.getAppRoot();
const expoModulesSearchResults = await findModulesAsync({
autolinkingOptions,
appRoot,
});
const expoModulesResolveResults = await resolveModulesAsync(
expoModulesSearchResults,
autolinkingOptions
);
const extraDependencies = await resolveExtraBuildDependenciesAsync({
commandRoot: autolinkingOptionsLoader.getCommandRoot(),
platform,
});
const configuration = getConfiguration({ autolinkingOptions });
const coreFeatures = [
...expoModulesResolveResults.reduce<Set<string>>((acc, module) => {
if (hasCoreFeatures(module)) {
const features = module.coreFeatures ?? [];
for (const feature of features) {
acc.add(feature);
}
return acc;
}
return acc;
}, new Set()),
];
if (commandArguments.json) {
console.log(
JSON.stringify({
extraDependencies,
coreFeatures,
modules: expoModulesResolveResults,
...(configuration ? { configuration } : {}),
})
);
} else {
console.log(
require('util').inspect(
{
extraDependencies,
coreFeatures,
modules: expoModulesResolveResults,
...(configuration ? { configuration } : {}),
},
false,
null,
true
)
);
}
});
}
@@ -0,0 +1,35 @@
import commander from 'commander';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import { findModulesAsync } from '../autolinking/findModules';
interface SearchArguments extends AutolinkingCommonArguments {
json?: boolean | null;
}
export function searchCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('search [searchPaths...]'))
.option('-j, --json', 'Output results in the plain JSON format.', () => true, false)
.action(async (searchPaths: string[] | null, commandArguments: SearchArguments) => {
const platform = commandArguments.platform ?? 'apple';
const autolinkingOptionsLoader = createAutolinkingOptionsLoader({
...commandArguments,
searchPaths,
});
const expoModulesSearchResults = await findModulesAsync({
autolinkingOptions: await autolinkingOptionsLoader.getPlatformOptions(platform),
appRoot: await autolinkingOptionsLoader.getAppRoot(),
});
if (commandArguments.json) {
console.log(JSON.stringify(expoModulesSearchResults));
} else {
console.log(require('util').inspect(expoModulesSearchResults, false, null, true));
}
});
}
@@ -0,0 +1,180 @@
import chalk from 'chalk';
import commander from 'commander';
import fs from 'fs';
import path from 'path';
import {
AutolinkingCommonArguments,
createAutolinkingOptionsLoader,
registerAutolinkingArguments,
} from './autolinkingOptions';
import {
type BaseDependencyResolution,
type DependencyResolution,
type ResolutionResult,
DependencyResolutionSource,
makeCachedDependenciesLinker,
mergeResolutionResults,
scanDependencyResolutionsForPlatform,
} from '../dependencies';
// NOTE(@kitten): These are excluded explicitly, but we want to include them for the verify command explicitly
const INCLUDE_PACKAGES = ['react-native', 'react-native-tvos'];
interface VerifyArguments extends AutolinkingCommonArguments {
verbose?: boolean | null;
json?: boolean | null;
}
export function verifyCommand(cli: commander.CommanderStatic) {
return registerAutolinkingArguments(cli.command('verify'))
.option('-v, --verbose', 'Output all results instead of just warnings.', () => true, false)
.option('-j, --json', 'Output results in the plain JSON format.', () => true, false)
.option(
'-p, --platform [platform]',
'The platform to validate native modules for. Available options: "android", "ios", "both"',
'both'
)
.action(async (commandArguments: VerifyArguments) => {
const platforms =
commandArguments.platform === 'both' ? ['android', 'ios'] : [commandArguments.platform!];
const autolinkingOptionsLoader = createAutolinkingOptionsLoader(commandArguments);
const appRoot = await autolinkingOptionsLoader.getAppRoot();
const linker = makeCachedDependenciesLinker({ projectRoot: appRoot });
const results = mergeResolutionResults(
await Promise.all(
platforms.map((platform) =>
scanDependencyResolutionsForPlatform(linker, platform, INCLUDE_PACKAGES)
)
)
);
await verifySearchResults(results, {
appRoot,
verbose: !!commandArguments.verbose,
json: !!commandArguments.json,
});
});
}
interface VerifyOptions {
appRoot: string;
verbose?: boolean;
json?: boolean;
}
interface VerifyGroups {
reactNativeProjectConfig: DependencyResolution[];
searchPaths: DependencyResolution[];
dependencies: DependencyResolution[];
duplicates: DependencyResolution[];
}
/**
* Verifies the search results by checking whether there are no duplicates.
*/
export async function verifySearchResults(
results: ResolutionResult,
options: VerifyOptions
): Promise<void> {
const { appRoot } = options;
async function getHumanReadableDependency(dependency: BaseDependencyResolution): Promise<string> {
let version = dependency.version || null;
if (!version) {
try {
const pkgContents = await fs.promises.readFile(
path.join(dependency.path, 'package.json'),
'utf8'
);
const pkg: unknown = JSON.parse(pkgContents);
if (pkg && typeof pkg === 'object' && 'version' in pkg && typeof pkg.version === 'string') {
version = pkg.version;
}
} catch (error) {
version = null;
}
}
const relative = path.relative(appRoot, dependency.originPath);
return version
? `${dependency.name}@${version} (at: ${relative})`
: `${dependency.name} at: ${relative}`;
}
const groups: VerifyGroups = {
reactNativeProjectConfig: [],
searchPaths: [],
dependencies: [],
duplicates: [],
};
for (const moduleName in results) {
const revision = results[moduleName];
if (!revision) {
continue;
} else if (revision.duplicates?.length) {
groups.duplicates.push(revision);
} else {
switch (revision.source) {
case DependencyResolutionSource.RN_CLI_LOCAL:
groups.reactNativeProjectConfig.push(revision);
break;
case DependencyResolutionSource.SEARCH_PATH:
groups.searchPaths.push(revision);
break;
case DependencyResolutionSource.RECURSIVE_RESOLUTION:
groups.dependencies.push(revision);
break;
}
}
}
if (options.json) {
console.log(JSON.stringify(groups));
return;
}
if (options.verbose) {
const sortResolutions = (resolutions: DependencyResolution[]) =>
[...resolutions].sort((a, b) => a.name.localeCompare(b.name));
if (groups.reactNativeProjectConfig.length) {
console.log(
`🔎 Found ${groups.reactNativeProjectConfig.length} modules from React Native project config`
);
for (const revision of sortResolutions(groups.reactNativeProjectConfig)) {
console.log(` - ${await getHumanReadableDependency(revision)}`);
}
}
if (groups.searchPaths.length) {
console.log(`🔎 Found ${groups.searchPaths.length} modules in search paths`);
for (const revision of sortResolutions(groups.searchPaths)) {
console.log(` - ${await getHumanReadableDependency(revision)}`);
}
}
console.log(`🔎 Found ${groups.dependencies.length} modules in dependencies`);
for (const revision of sortResolutions(groups.dependencies)) {
console.log(` - ${await getHumanReadableDependency(revision)}`);
}
}
if (groups.duplicates.length) {
for (const revision of groups.duplicates) {
console.warn(`⚠️ Found duplicate installations for ${chalk.green(revision.name)}`);
const revisions = [revision, ...(revision.duplicates ?? [])];
for (let idx = 0; idx < revisions.length; idx++) {
const prefix = idx !== revisions.length - 1 ? '├─' : '└─';
const duplicate = revisions[idx];
console.log(` ${prefix} ${await getHumanReadableDependency(duplicate)}`);
}
}
console.warn(
'⚠️ Multiple versions of the same module may introduce some side effects or compatibility issues.\n' +
`Resolve your dependency issues and deduplicate your dependencies. Learn more: https://expo.fyi/resolving-dependency-issues`
);
} else {
console.log('✅ Everything is fine!');
}
}