This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Setup Firestore. Note that all of these will be asyncronous tasks and can have a .then attached. Write in a config process for Firebase. Include the necessary process.env files and instructions how to make a .env file. | |
*************************************************************** | |
// Add data - C | |
firestore.collection("CollectionName").add({ | |
key: value, | |
key: value, | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Step 1: Setup Folders | |
// Create an actions and a reducers folder. Then add an index.js file in both folders. | |
// Required dependency installs: axios, redux, react-redux, redux-thunk | |
************************************************ | |
// Step 2: Create Redux Config File | |
// @ Root of application create a <config>.js file. | |
import { createStore } from 'redux'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Carousel { | |
constructor(carousel){ | |
this.carousel = carousel; | |
this.leftButton = document.querySelector(".left-button"); | |
this.rightButton = document.querySelector(".right-button"); | |
this.images = document.querySelectorAll(".carousel img"); | |
this.images = Array.from(this.images); | |
this.index = 0; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TabLink { | |
constructor(tabElement){ | |
// assign this.tabElement to the tabElement DOM reference | |
this.tabElement = tabElement; | |
// Get the `data-tab` value from this.tabElement and store it here | |
this.tabData = tabElement.dataset.tab; | |
// We need to find out if a user clicked 'all' cards or a specific category. Follow the instructions below to accomplish this task: | |
// <- Delete this comment block when you work on the if statement | |
// Check to see if this.tabData is equal to 'all' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Tab { | |
constructor(element) { | |
// Assign this.element to the passed in DOM element | |
this.element = element; | |
// Get the custom data attribute on the Link | |
this.tabNumber = element.dataset.tab; | |
// Using the custom data attribute get the associated Item element | |
this.itemElement = document.querySelector(`div.tabs-item[data-tab="${this.tabNumber}"]`); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* | |
=== GameObject === | |
* createdAt | |
* name | |
* dimensions (These represent the character's size in the video game) | |
* destroy() // prototype method that returns: `${this.name} was removed from the game.` | |
*/ | |
function GameObject(createdAt, name, dimensions){ | |
this.createdAt = createdAt; |