PROJECT_NAME
Story board: https://air-en-japan.storiesonboard.com/m/__PROJECT__
Backlog https://waffle.io/en-japan-air/__PROJECT__
Story board: https://air-en-japan.storiesonboard.com/m/__PROJECT__
Backlog https://waffle.io/en-japan-air/__PROJECT__
Fixes #
Review requested by @
const cors = require('cors')({origin: true}); | |
exports.sample = functions.https.onRequest((req, res) => { | |
cors(req, res, () => { | |
res.send('Passed.'); | |
}); | |
}); |
// VueJS with Router, I18n and simple http client | |
import Vue from "vue" | |
import VueI18n from "vue-i18n" | |
import VueRouter from "vue-router" | |
import VueResource from 'vue-resource' | |
// 2 pages for the app states | |
import Splash from "./pages/Splash.vue" | |
import Main from "./pages/Main.vue" | |
import App from "./App.vue" | |
// i18n strings |
# add the tracking code normally to your layout; then include this in every page | |
$(document).on 'page:change', -> | |
if window.ga? | |
ga('send', 'pageview'); | |
else if window._gaq? | |
_gaq.push(['_trackPageview']) | |
else if window.pageTracker? | |
pageTracker._trackPageview() |
function getElementByXpath(path) { | |
return document.evaluate(path, document, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null).singleNodeValue; | |
} | |
console.log( getElementByXpath("//html[1]/body[1]/div[1]") ); |
val jodaDateTimeConverter = new FormConverter[DateTime] { | |
override def serialize(v: Any): String = | |
new DateTime(v).toString(ISODateTimeFormat.dateHourMinuteSecond) | |
override def deserialize(s: String): DateTime = | |
new DateTime(s.toLong) | |
} | |
FormConverter.register(classOf[DateTime], jodaDateTimeConverter) | |
ClassInfo.factories.register(classOf[DateTime], {() => DateTime.now.asInstanceOf[AnyRef]}) |
import com.github.aselab.activerecord.{PlayConfig, ActiveRecordTables} | |
import org.scalatest.{BeforeAndAfterAll, BeforeAndAfterEach} | |
import play.api.Play | |
import play.api.test.FakeApplication | |
trait ActiveRecordAutoRollback extends BeforeAndAfterEach with BeforeAndAfterAll { | |
self: ApiBaseSpec => | |
def schema: Seq[ActiveRecordTables] = Seq(ActiveRecordTables.find("models.Tables")) |
/* | |
* Assuming we have some object with properties and methods | |
*/ | |
var me = { | |
first_name: 'Ahikar', | |
last_name: 'Grilka', | |
race: 'Klingon', | |
email: 'AhikarGrilka@jourrapide.com', | |
occupation: 'Commander of Defence', | |
greet: function(other_person){ |