-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.coffee
31 lines (25 loc) · 1.06 KB
/
main.coffee
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Chateau = require "./chateau"
if PACKAGE.name is "ROOT"
require("analytics").init("UA-3464282-15")
{Style} = require "ui"
style = document.createElement "style"
style.innerHTML = Style.all + "\n" + require("./style")
document.head.appendChild style
# Initialize Firebase
firebase.initializeApp
apiKey: "AIzaSyCnhTPOri3XGQ0q5pw0u8dRPZQwr74fpuw"
authDomain: "chateau-f2799.firebaseapp.com"
databaseURL: "https://chateau-f2799.firebaseio.com"
storageBucket: "chateau-f2799.appspot.com"
messagingSenderId: "2073045470"
global.logger = require("./lib/logger")(console.log)
global.stats = require("./lib/stats")()
global.firebase = firebase
global.db = firebase.database()
db.TIMESTAMP = firebase.database.ServerValue.TIMESTAMP
global.defaults = require("./util").defaults
global.chateau = Chateau()
document.body.appendChild chateau.element
document.body.appendChild require("./lib/feedback-tab")("https://docs.google.com/forms/d/e/1FAIpQLScMur8T8VcgWGk0k-sFkNRmCiDGWAzTRTLICUC0v-W2J7rJKQ/viewform")
else
module.exports = Chateau