diff --git a/frontend/.env.backup b/frontend/.env.backup new file mode 100644 index 00000000..7a807d45 --- /dev/null +++ b/frontend/.env.backup @@ -0,0 +1,5 @@ +EXPO_TUNNEL_SUBDOMAIN=mobile-wallet-app-3 +EXPO_PACKAGER_HOSTNAME=https://mobile-wallet-app-3.preview.emergentagent.com +EXPO_PUBLIC_BACKEND_URL=https://mobile-wallet-app-3.preview.emergentagent.com +EXPO_USE_FAST_RESOLVER="1" +METRO_CACHE_ROOT=/app/frontend/.metro-cache \ No newline at end of file diff --git a/frontend/metro.config.backup.js b/frontend/metro.config.backup.js new file mode 100644 index 00000000..06b63364 --- /dev/null +++ b/frontend/metro.config.backup.js @@ -0,0 +1,25 @@ +// metro.config.js +const { getDefaultConfig } = require("expo/metro-config"); +const path = require('path'); +const { FileStore } = require('metro-cache'); + +const config = getDefaultConfig(__dirname); + +// Use a stable on-disk store (shared across web/android) +const root = process.env.METRO_CACHE_ROOT || path.join(__dirname, '.metro-cache'); +config.cacheStores = [ + new FileStore({ root: path.join(root, 'cache') }), +]; + + +// // Exclude unnecessary directories from file watching +// config.watchFolders = [__dirname]; +// config.resolver.blacklistRE = /(.*)\/(__tests__|android|ios|build|dist|.git|node_modules\/.*\/android|node_modules\/.*\/ios|node_modules\/.*\/windows|node_modules\/.*\/macos)(\/.*)?$/; + +// // Alternative: use a more aggressive exclusion pattern +// config.resolver.blacklistRE = /node_modules\/.*\/(android|ios|windows|macos|__tests__|\.git|.*\.android\.js|.*\.ios\.js)$/; + +// Reduce the number of workers to decrease resource usage +config.maxWorkers = 2; + +module.exports = config;