Ingest data with Node.js on Elastic Search service

I have a simple app and I want to ingest data from my app to Elastic Search sevice. I followed the steps from this tutorial which seem pretty straightforward - get a free trial, create a deployment, then install with npm install @elastic/elasticsearch and then test your connection.

After running npm install @elastic/elasticsearch I can not start my app. I am running it from the terminal with Expo. I keep getting errors from the type: The package at "node_modules/@elastic/transport/lib/connection/HttpConnection.js" attempted to import the Node standard library module "http". It failed because the native React runtime does not include the Node standard library. I keep installing these packages with npm install os, but the errors keep persisting with ifferent packages. So I installed packages os, events, paths and so on. The latest such error is with the package http. I ran npm install http but the error keep persisting.

I can not start my react native project, and my free trial expires soon. Can someone please advise because I lost several days on this error?

Can Node.js be used with the React Native runtime? I've not got much experience with React Native, but I did find several threads saying they can't be used together, including the below:

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.