Skip to content

Commit 2819540

Browse files
committed
env
1 parent 1c80580 commit 2819540

File tree

5 files changed

+17
-4
lines changed

5 files changed

+17
-4
lines changed

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ npm-debug.*
88
*.mobileprovision
99
*.orig.*
1010
web-build/
11-
11+
.env
1212
# macOS
1313
.DS_Store

App.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,8 @@ import WeatherInfo from './components/WeatherInfo'
66
import UnitsPicker from './components/UnitsPicker'
77
import ReloadIcon from './components/ReloadIcon'
88
import WeatherDetails from './components/WeatherDetails'
9-
// import { WEATHER_API_KEY } from 'react-native-dotenv'
9+
import { WEATHER_API_KEY } from 'react-native-dotenv'
1010

11-
const WEATHER_API_KEY = "a68f42df5bf8a407c62860303949d442";
1211
const BASE_WEATHER_URL = "https://api.openweathermap.org/data/2.5/weather?";
1312

1413
export default function App() {

babel.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module.exports = function(api) {
22
api.cache(true);
33
return {
4-
presets: ['babel-preset-expo'],
4+
presets: ['babel-preset-expo','module:react-native.env'],
55
};
66
};

package-lock.json

Lines changed: 13 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"react": "16.13.1",
1717
"react-dom": "16.13.1",
1818
"react-native": "https://github.com/expo/react-native/archive/sdk-41.0.0.tar.gz",
19+
"react-native-dotenv": "^2.5.5",
1920
"react-native-web": "~0.13.12"
2021
},
2122
"devDependencies": {

0 commit comments

Comments
 (0)