Simply download this project go inside project directory and open cmd/gitbash. Write npm install and hit enter. It will install all required dependencies.
Now we have to create the database and change configuration of firebase in AmazonClone>src>.firebase>Firebase.js . For that
1.Go on https://firebase.google.com/
2.Create FirStore DataBase.
4.Specify the collection-type/fields and click on save.
5. Now, Click on *ProjectDatabase* setting.
6. Now, Click on higlighted icon *</>*.
7. Click on config and copy that code.
8. At the end, paste that code in in replacement of the old code in AmazonClone>src>.firebase>Firebase.js . Carefully!
apiKey: "AIzaSyCf3H8NCnV4FfEguVVvaKuM2uti7okaPrY",
authDomain: "clone-ffc29.firebaseapp.com",
projectId: "clone-ffc29",
storageBucket: "clone-ffc29.appspot.com",
messagingSenderId: "530829000076",
appId: "1:530829000076:web:0fd77c3bbe3e1f7bb2aaa9",
9. Then your file will look like this.
import firebase from "firebase";
const firebaseConfig = firebase.initializeApp({
apiKey: "AIzaSyCf3H8NCnV4FfEguVVvaKuM2uti7okaPrY",
authDomain: "clone-ffc29.firebaseapp.com",
projectId: "clone-ffc29",
storageBucket: "clone-ffc29.appspot.com",
messagingSenderId: "530829000076",
appId: "1:530829000076:web:0fd77c3bbe3e1f7bb2aaa9",
});
const DataBase = firebase.firestore();
export { DataBase };
10. Now write npm run in cmd/terminal.