All Projects → ArunasNorvaisa → react-weather-app

ArunasNorvaisa / react-weather-app

Licence: other
An attempt to make an ultimate weather app. In ReactJS, with React hooks and context.

Programming Languages

javascript
184084 projects - #8 most used programming language
SCSS
7915 projects
PHP
23972 projects - #3 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to react-weather-app

react-weather-app
Weather App built with React & TypeScript
Stars: ✭ 61 (+56.41%)
Mutual labels:  weather, openweathermap, weather-app
weather-station
Everything you need to run and monitor your own open source weather station. ⛅
Stars: ✭ 38 (-2.56%)
Mutual labels:  weather, weather-app
d9l weather
A flutter weather app
Stars: ✭ 22 (-43.59%)
Mutual labels:  weather, weather-app
react-weather-app
⛅️ PWA Weather App made with ReactJS
Stars: ✭ 147 (+276.92%)
Mutual labels:  weather, weather-app
weather-app-2020-android
Android Weather App 2020
Stars: ✭ 15 (-61.54%)
Mutual labels:  weather, weather-app
WeatherRadar
An Android application featuring customizable, real-time doppler radar images
Stars: ✭ 35 (-10.26%)
Mutual labels:  weather, weather-app
cuba-weather-flutter
Application for mobile devices of the Cuba Weather project implemented with Flutter
Stars: ✭ 28 (-28.21%)
Mutual labels:  weather, weather-app
AndroidWeatherApp
Android WeatherApp, using the http://openweathermap.org/ API. Made for Network + JSON Parsing and Material Design Experiments.
Stars: ✭ 17 (-56.41%)
Mutual labels:  weather, weather-app
android-weather
View a beautiful, material design-based 10 day weather forecast
Stars: ✭ 32 (-17.95%)
Mutual labels:  weather, openweathermap
angular-weather-app
Angular 7 web app displays the weather report through openweathermap.org APIs
Stars: ✭ 13 (-66.67%)
Mutual labels:  weather, openweathermap
Wttr.in
⛅ The right way to check the weather
Stars: ✭ 16,345 (+41810.26%)
Mutual labels:  weather, weather-app
pluvia weather flutter
A weather app with beautiful animations, built with Flutter. Uses the OpenWeatherMap API and MapBox API.
Stars: ✭ 114 (+192.31%)
Mutual labels:  weather, openweathermap
scala-weather
High-performance Scala library for looking up the weather
Stars: ✭ 45 (+15.38%)
Mutual labels:  weather, openweathermap
Weather
Weather Android App using apixu API https://www.apixu.com
Stars: ✭ 48 (+23.08%)
Mutual labels:  weather, weather-app
climate-app
Climate App é uma aplicação responsável por mostrar dados climáticos (temperatura atual, umidade, velocidade do vento etc) de uma determinada cidade em tempo real. A obtenção desses dados foi feita através da open-weather-api.
Stars: ✭ 40 (+2.56%)
Mutual labels:  weather, weather-app
epaper-clock-and-more
e-paper clock + weather + AQI + traffic delays - using Waveshare 2.7inch & 4.2inch eink displays running on Raspberry Pi
Stars: ✭ 34 (-12.82%)
Mutual labels:  weather, openweathermap
TheWeatherDashboardApp
A small and stylish weather dashboard.
Stars: ✭ 29 (-25.64%)
Mutual labels:  openweathermap, weather-app
weather-bar-app
Weather Bar lives in your Menu Bar giving you access to beautiful real-time weather conditions and a generous 15-day forecast.
Stars: ✭ 38 (-2.56%)
Mutual labels:  openweathermap, weather-app
owmr
An R Interface to OpenWeatherMap
Stars: ✭ 24 (-38.46%)
Mutual labels:  weather, openweathermap
Real-World-Weather
Unity project that displays the current weather in your location in real-time using the Dark Sky API
Stars: ✭ 39 (+0%)
Mutual labels:  weather, weather-app

Weather application

React weather app

Weather app made with ReactJS. Automatically recognizes user's location, based on browser's settings or IP. Weather can be searched both by location on the map or entering city in the search bar.

Made using React hooks (useState, useEffect, useContext) and React context (absolutely unnecessary for a small application like this, but it was fun to learn).

Version

  • 3.1.0

Demo

Usage:

$ git clone [email protected]:ArunasNorvaisa/react-weather-app.git
$ cd react-weather-app
$ npm i -d (OR $ yarn)
$ touch .env
$ touch ./proxy/env.json
  • Get 2 (two) API keys from Google and 1 (one) from Open Weather Map.
  • Update .env file in the project root (that was created at the previous step) directory with the following content:

API_KEY_GOOGLE_GEOCODING = YOUR_GOOGLE_GEOCODING_API_KEY
API_KEY_GOOGLE_MAPS = YOUR_GOOGLE_MAPS_API_KEY
API_KEY_OW = YOUR_OPENWEATHERMAP_API_KEY

This will prevent keys to be uploaded to the git repository, however anyone with at least half of the brain still be able to see them in plain text.

If (and ONLY if) you care about security of your API keys:

We'll be using 2 PHP proxies to access the Openweathermap and Google geocoding services from the backend, so the keys wouldn't be exposed to anyone who knows how to use browser's dev tools.

  • Update ./proxy/env.json file with the following content (please note the quotes - they are required here, unlike in .env):
{
  "API_KEY_GOOGLE_GEOCODING" = "YOUR_GOOGLE_GEOCODING_API_KEY"
  "API_KEY_OW": "YOUR_OPENWEATHERMAP_API_KEY"
}
  • Update ./proxy/.htaccess file to reflect your referring domain.
  • Read comments in /components/Weather.jsx and /components/App.jsx to either enable or disable proxy.

Run your App:

$ npm run start (OR $yarn run start)

App will be accessible at http://localhost:8080

Build your App:

$ npm run build:prod (OR $yarn run build:prod)
  • Open /build/index.html in your browser and, if everything works as intended,
  • Upload contents of BUILD folder to your hosting provider.

Support:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].