Files
DeepTutor/apps/mobile/metro.config.js
Qiuner a0d1a7403e feat(mobile): integrate Expo development builds and native CI
Keep the checked-in React Native projects and shared turn transport. Add Expo SDK 57 and Dev Client, mobile tests and native build jobs, and instructions for self-hosted development.
2026-11-24 12:34:49 -03:00

20 lines
724 B
JavaScript

const { getDefaultConfig } = require('expo/metro-config');
const path = require('node:path');
const webRoot = path.resolve(__dirname, '../../web');
const config = getDefaultConfig(__dirname);
config.watchFolders = [...new Set([...config.watchFolders, webRoot])];
config.resolver.nodeModulesPaths = [
path.join(__dirname, 'node_modules'),
...(config.resolver.nodeModulesPaths ?? []),
];
const expoResolve = config.resolver.resolveRequest;
config.resolver.resolveRequest = (context, moduleName, platform) => {
const name = moduleName.startsWith('@/')
? path.join(webRoot, moduleName.slice(2))
: moduleName;
return (expoResolve ?? context.resolveRequest)(context, name, platform);
};
module.exports = config;