AllenYuan

index.js firebase configuration

May 1st, 2020
171
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $(document).ready(function () {
  2.   let PIXELSIZE = 2;
  3.   let REPEATSX = 20;
  4.   let REPEATSY = 15;
  5.   let DIMENSION = 25;
  6.  
  7.   let canvas = id('mycanvas');
  8.   let ctx = canvas.getContext("2d");
  9.   let canvasWidth = DIMENSION * REPEATSX * PIXELSIZE;
  10.   let canvasHeight = DIMENSION * REPEATSY * PIXELSIZE;
  11.   let selectedBox = null;
  12.  
  13.   canvas.width = canvasWidth;
  14.   canvas.height = canvasHeight;
  15.  
  16.   // Your web app's Firebase configuration
  17.   var firebaseConfig = {
  18.     apiKey: "AIzaSyDjLFcsO92KpwLiFe7Hsp4gVd51w61WIsk",
  19.     authDomain: "canvasgamedemo.firebaseapp.com",
  20.     databaseURL: "https://canvasgamedemo.firebaseio.com",
  21.     projectId: "canvasgamedemo",
  22.     storageBucket: "canvasgamedemo.appspot.com",
  23.     messagingSenderId: "258751262925",
  24.     appId: "1:258751262925:web:50cdf23c2265aa7ae07984"
  25.   };
  26.   // Initialize Firebase
  27.   firebase.initializeApp(firebaseConfig);
  28.  
  29.   // draw grid
  30. // ...
Add Comment
Please, Sign In to add comment