Posts

Showing posts from September, 2021

How to get the [ IP, location ...etc ] of anyone visit your site in React/JavaScript

### My First Simple article at DEV Community :) i wrote a simple [Covid-19 Tracker], when you open it will give you the information of your country accord to your location. You can check my so simple project [Covid-19 Tracker]  Github: https://github.com/moamlrh/covid-tracker/tree/master ####* NOTE : this article for absolute beginner:) It's easy, i don't wanna waste your time. ## First Of All :    we'll create a file called App.js : ![App.js](https://dev-to-uploads.s3.amazonaws.com/i/tl0b7ejj4y2cej3vuin4.png) ## Request and API    Then make get request to https://ip.nf/me.json we'll use fetch to make request but you can use whatever you want [try with Axios] The response will Looks like : ![response](https://dev-to-uploads.s3.amazonaws.com/i/jmjmbz0pa21zwak863vk.png) Your information => IP, Country, Country Code, City,ASN etc... ## Finally,  we can use it with React Hooks [useState, useEffect]: ![code](https://dev-to-uploads.s3.amazonaws.com/i/nbde27smr...

Secure your Discord account with 2FA

 How to secure your Discord account ?     first of, to make sure your discord is secure you have to enable  two factor authentication ( 2FA) ,  and make sure to use your phone number, and email     to secure your discord account with these simple steps ( Two Factor authentication ): open discord Go to settings Click Enable Two Factor Auth Enter your password will give you the QR code and 2FA key open Authenticator application on your mobile you can scan it if you were using discord desktop or  copy the  2FA key  something like that 6eaj rxvj v5p4 3yyo and past the key in the Authenticator application will give you a key from  6 digit copy it by clicking on it for a while then past the code inside the discord  and you're done with it now anyone can't open your account. Good luck and see you in another blog  Bye!