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
schema: { | |
pmcid: Joi.number().required(), | |
siteid: Joi.number().required(), | |
prospects: Joi.array().min(1).required().includes(Joi.object().keys({ | |
Prospect: Joi.object().required().keys({ | |
email: Joi.string().required(), | |
firstname: Joi.string().required(), | |
lastname: Joi.string().required(), | |
numbers: Joi.object().optional().keys({ | |
phonenumbers: Joi.array().required().includes(Joi.object().keys({ |
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
/* jshint node: true */ | |
module.exports = function (environment) { | |
var ENV = { | |
modulePrefix: 'nitrous', | |
environment: environment, | |
baseURL: '/', | |
locationType: 'hash', | |
EmberENV: { | |
FEATURES: { |
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
(def db (pouch/create-db "todos")) | |
(go | |
(<! (pouch/put-doc db {:_id (now) :text "Todo 1"})) | |
(<! (pouch/put-doc db {:_id (now) :text "Todo 2"})) | |
(let [res (<! (pouch/all-docs db))] | |
(println res))) |
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
(ns todos-example.core | |
(:require [om.core :as om :include-macros true] | |
[om-tools.dom :as dom :include-macros true] | |
[om-tools.core :refer-macros [defcomponent]])) | |
(def app-state (atom {})) | |
(def firebase-root "https://cljs-todos.firebaseio.com/todos") | |
(def r (js/Firebase. firebase-root)) |
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
'use strict'; | |
var path = require('path'); | |
var commands = require('./lib/commands'); | |
var postBuild = require('./lib/tasks/post-build'); | |
module.exports = { | |
name: 'ember-cli-cordova', | |
blueprintsPath: function() { |
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
# Returns as you'd expect | |
echo "require('https').get('https://github.com/jakecraige.json', function(res) { console.log(res); });" | node | |
# Won't return, eventually throws ECONNRESET | |
echo "require('https').get('https://gateway.rpx.realpage.com/rpxgateway/PricingAndAvailability.svc', function(res) { console.log(res); });" | node |
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
import Ember from 'ember'; | |
export default Ember.Route.extend({ | |
afterModel: function() { | |
this._super.apply(this, arguments); | |
var pushChannelName = this.pushChannelName || this.routeName; | |
var pushChannel = this.pushChannelFor(pushChannelName); | |
this.setupPushChannel(pushChannel, model); | |
}, |
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
additionalInformations: hasMany('additional-information',{ async: true }), | |
promos: Ember.computed.filterBy('additionalInformations', 'type', 'Promo'), |
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
sortedContent: function() { | |
var content = this.get('content'); | |
if (this.get('softDelete')) { | |
content = content.filterBy('softDeleted', false) | |
if (this.get('vendorSelected')) { | |
content = content.filterBy('vendor', this.get('vendorSelected')); | |
} | |
} |