Antes eu rodava o comando npm start e me retornava este erro Failed to construct transformer: Error: error:0308010C:digital envelope routines::unsupported at new Hash (node:internal/crypto/hash:68:19) at Object.createHash (node:crypto:138:10) at stableHash (/Users/kauelima/Downloads/react-native-navegacao-entre-telas-main/node_modules/metro-cache/src/stableHash.js:19:8) at Object.getCacheKey (/Users/kauelima/Downloads/react-native-navegacao-entre-telas-main/node_modules/metro-transform-worker/src/index.js:593:7) at getTransformCacheKey (/Users/kauelima/Downloads/react-native-navegacao-entre-telas-main/node_modules/metro/src/DeltaBundler/getTransformCacheKey.js:24:19) at new Transformer (/Users/kauelima/Downloads/react-native-navegacao-entre-telas-main/node_modules/metro/src/DeltaBundler/Transformer.js:48:9) at /Users/kauelima/Downloads/react-native-navegacao-entre-telas-main/node_modules/metro/src/Bundler.js:22:29 at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ], library: 'digital envelope routines', reason: 'unsupported', code: 'ERR_OSSL_EVP_UNSUPPORTED' }
pesquisei muito e não achei a solução, porém criei um novo projeto com (npx react-native init "projeto") e copiei a pasta src para dentro deste novo projeto e funcionou.