typesense-js icon indicating copy to clipboard operation
typesense-js copied to clipboard

Axios errors after react-native 0.79.1 upgrade

Open ertucaglar opened this issue 9 months ago • 0 comments

After updating to react-native version 0.79.1, there is a problem with the axios package.

I tried to nodeify the react-native project regarding this issue, but it continues to give other errors.

Steps to reproduce Steps to reproduce the behavior:

upgrade react-native 0.79.1 build and run project See error

Error: Unable to resolve module url from .../node_modules/typesense/node_modules/axios/dist/node/axios.cjs: url could not be found within the project or in these directories:
  node_modules/typesense/node_modules
  node_modules
  3 |
  4 | const FormData$1 = require('form-data');
> 5 | const url = require('url');
    |                      ^
  6 | const proxyFromEnv = require('proxy-from-env');
  7 | const http = require('http');
  8 | const https = require('https');
"typesense": "2.0.3"
"react-native": "0.79.1",
"react": "19.0.0",
"axios": "1.9.0"

react-native info output:

System:
  OS: macOS 15.4.1
  CPU: (14) arm64 Apple M3 Max
  Memory: 597.59 MB / 36.00 GB
  Shell:
    version: "5.9"
    path: /bin/zsh
Binaries:
  Node:
    version: 23.11.0
    path: /opt/homebrew/bin/node
  Yarn:
    version: 4.5.3
    path: /opt/homebrew/bin/yarn
  npm:
    version: 10.9.2
    path: /opt/homebrew/bin/npm
  Watchman:
    version: 2025.02.17.00
    path: /opt/homebrew/bin/watchman
Managers:
  CocoaPods:
    version: 1.16.2
    path: /Users/ertucaglar/.rbenv/shims/pod
SDKs:
  iOS SDK:
    Platforms:
      - DriverKit 24.4
      - iOS 18.4
      - macOS 15.4
      - tvOS 18.4
      - visionOS 2.4
      - watchOS 11.4
  Android SDK: Not Found
IDEs:
  Android Studio: 2024.3 AI-243.24978.46.2431.13208083
  Xcode:
    version: 16.3/16E140
    path: /usr/bin/xcodebuild
Languages:
  Java:
    version: 22.0.2
    path: /usr/bin/javac
  Ruby:
    version: 3.2.3
    path: /Users/ertucaglar/.rbenv/shims/ruby
npmPackages:
  "@react-native-community/cli":
    installed: 16.0.2
    wanted: 16.0.2
  react:
    installed: 19.1.0
    wanted: 19.1.0
  react-native:
    installed: 0.79.1
    wanted: 0.79.1
  react-native-macos: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: true
  newArchEnabled: true

ertucaglar avatar Apr 28 '25 12:04 ertucaglar