How to Setup Environment Variables in React Native Expo

preview_player
Показать описание
In this tutorial, you will learn how to set up environment variables in your React Native Expo project. Environment variables are an essential part of any software development project as they allow developers to store sensitive data such as API keys, database credentials, and other configuration variables outside of the codebase. This makes it easier to manage and secure the application's data.

In this video, we will cover how to create and manage environment variables in your React Native Expo project, including how to set them up in different development environments like local, staging, and production. We will also explore how to access these variables in your code and best practices for managing them.

Whether you are new to React Native Expo or a seasoned developer looking to improve your project's security and scalability, this tutorial will provide you with the tools you need to set up environment variables in your project with ease. Follow along with the step-by-step instructions and start improving your React Native Expo project today!
Рекомендации по теме
Комментарии
Автор

Thanks man u helped me a lot, was trying the get access to my env variables for hours ^^

ohmygoodness
Автор

Nice tutorial. How does one get production and development env files that works deployed builds

michaeladetona
Автор

its not working for me, I'm using Expo SDK 49, I wonder if this video's solution is no longer supported

maxaquilino
Автор

How do you use different .env files with the same variable name though?

pyvogzt
Автор

I know this way but how would u then set these environment variables values when u r bulding your app using EAS? Because i check the eas docs and it shows a totally different way for adding environektn varibales to the app

mustaneerhaider
Автор

Hi great video! I am running into this huge problem where it says "Error: undefined Unable to resolve module @env from ProjectName/config/config.ts: @env could not be found within the project or in these directories:"

wiaanduvenhage
Автор

But when we build in expo dev and get apk it throws error firebase auth/invalid-api-key

v.i.n.i.t
Автор

thanks, I was getting a screw out of something very easy

alexandervega
Автор

How do i set it usually for production environment?

richardsonlyon
Автор

what if I have more than just one environment? I can't find a proper solution.

dudecia
Автор

goddamn man, 1 minute 30 seconds of teaching us how to copy some shit. Speed it up!

Fralleee