And it should not work, right? Plain React in 200+ pages of learning material. I think you guys do something special and run the app in a different network connection. Afterward, we will use the local storage as cache every time we do another search request. Your email address will not be published. Let's take the local storage usage in React one step further by deploying it as cache for search results. noch eine CSS habe? We can take this step further by making the web app available over our local network. We use cookies to ensure that we give you the best experience on our website. In case you face any issues, feel free to add them in the comments below. However, one step is missing: we only store the value and never retrieve it. But before that, you need to make sure that both your desktop (from where you are serving the index.html) and your phone, are connected to same network. To get a bundled version of your app, you can use build tools like Webpack or Parcel. Once the frontend React application starts, it would make a request to the backend application to retrieve the data from the database. Visual Studio Code. Let's approach the local storage in React by example. Also, why you want to use NodeJS in the first place for ReactJS web applications? If you know any other great solutions for local storage and JavaScript, let me know in the comments below. Above, we see the basic required files for our app. In your JavaScript code, running in the browser, you should have access to the localStorage instance which has setter and getter to store and retrieve data from the local storage. ), Weil ich auf Deutsch schon Verständnisprobleme habe, versuche ich es gar nicht erst auf Englisch, ich hoffe, das ist okay. Furthermore, you will store the result in the local storage as well. The web server runs on the http-server npm package, a simple zero-configuration http server for serving static files to the browser, it's started from the command line and doesn't require a server.js file. Once you close the browser and open the JavaScript application again, you will find the data still in the local storage. If you don’t experience the problems described above or don’t feel comfortable using JavaScript tools yet, consider adding React as a plain