code stringlengths 2 1.05M |
|---|
var methods = require('methods')
var flatten = require('array-flatten')
var compose = require('koa-compose')
var Layer = require('./layer')
var extend = require('./extend')
/**
* Return the function execution stack or create a new one.
*
* @return {Array}
*/
function stack (self) {
return self._stack || (self._s... |
const what3words = require('../../');
const validate = require('./validateGrid');
/* eslint import/no-extraneous-dependencies: ["error", {"devDependencies": true}] */
const expect = require('chai').expect;
const ERRORS = what3words.errors;
/* eslint no-console: "off" */
/* eslint no-unused-expressions: "off" */
de... |
'use strict';
//Beneficiaries service used to communicate Beneficiaries REST endpoints
angular.module('beneficiaries').factory('Beneficiaries', ['$resource',
function($resource) {
return $resource('beneficiaries/:beneficiaryId', { beneficiaryId: '@_id'
}, {
update: {
method: 'PUT'
}
});
}
]); |
const Benchmark = require('benchmark');
const suite = new Benchmark.Suite;
const benchmarks = require('beautify-benchmark');
const Chunk = require('../src/chunk');
const chunk = new Chunk();
const obj = {
undefinedValue: undefined,
nullValue: null,
falseValue: false,
emptyStringValue: '',
zeroValue: 0,
tr... |
$(function() {
'use strict';
// Submit vote.
$('.container form').submit(function(e) {
e.preventDefault();
var $this = $(this);
var $btn = $this.find('button');
$btn.prop('disabled', true);
var selection = $('input:checked', $this).val();
if (selection ==... |
app.factory("NotesService", function() {
var NotesService = {};
var audioPath = "../../audio/";
var kick = new Howl({ src: [audioPath + "kick.wav"] });
var snare = new Howl({ src: [audioPath + "snare.wav"] });
var hihat = new Howl({ src: [audioPath + "hihat.wav"] });
var staves = [
{
id: 1,
... |
var romSelector = (function ($) {
var selectedRom = null;
var romRegistry = [
{
"fileName": "BREAKOUT",
"name": "Breakout",
"author": "David Winters",
"year": "1997",
"description": [
"Controls:",
"Q - left, E -... |
// The main application script, ties everything together.
var express = require('express');
var mongoose = require('mongoose');
var creds = require('./credentials.json');
var app = express();
var auth = express.basicAuth(function(user, pass, callback) {
callback(null, (user === creds.username && pass === creds.passw... |
// Copyright (c) 2012 Ecma International. All rights reserved.
// Ecma International makes this code available under the terms and conditions set
// forth on http://hg.ecmascript.org/tests/test262/raw-file/tip/LICENSE (the
// "Use Terms"). Any redistribution of this code must retain the above
// copyright and this n... |
(function() {
var makeSingleton = function(options, instantiate) {
var _Clazz = this.prototype.constructor;
if(_Clazz.getInstance) {
return;
}
var _options = options || {};
// overwrite the initialize method
// so we can check if the enforcer exists
var _Enforcer = function() {};
var _i... |
module.exports = function (req, res) {
res.send('twitter/redirect');
}; |
'use strict';
/*
* Defining the Package
*/
var Module = require('meanio').Module;
var SmartTools = new Module('smartTools');
var schedule = require('node-schedule');
var mongoose = require('mongoose');
var Video = mongoose.model('Video');
var _ = require('lodash');
var nodemailer = require("nodemailer");
var... |
/*
Copyright (c) 2014, RKE
*/
(function() {
var __bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
codiad.ToDo = (function() {
/*
basic plugin environment initialization
*/
function ToDo(global, jQuery) {
this.disableToDo = __bind(this.disableToDo, this)... |
import React from 'react'
import { connect, createStore } from 'react-redux'
import net from 'net'
import { increment, decrement, async_increment } from '../actions/counter'
export default class Root extends React.Component {
render() {
return (
<div>
<h1>Counter</h1>
... |
(function (window, document, $) {
}(window, document, $)); |
module.exports = {
'+': require('./plus.js'),
'-': require('./minus.js'),
'*': require('./asterisk.js'),
'%': require('./modulo.js'),
'/': require('./solidus.js'),
'===': require('./equality.js'),
'plus': require('./plus.js'),
'minus': require('./minus.js'),
'asterisk': require('./asterisk.js'),
'modulo': req... |
var Piwik_Overlay_Client = (function () {
/** jQuery */
var $;
/** Url of the Piwik root */
var piwikRoot;
/** Piwik idsite */
var idSite;
/** The current period and date */
var period, date, segment;
/** Reference to the status bar DOM element */
var statusBar;
/** Loa... |
// โโโโโโโ โโโ โโโโโโโ โโโ โโโโโโโ โโโ โโโโโโโโโโโโโโโโโโ โโโ โโโ
// โโโโโโโโโโโ โโโโโโโโ โโโ โโโโโโโโโโโโ โโโโโโโโโโโโโโโโโโโโโโโ โโโโ
// โโโโโโโโโโโ โโโโโโโโโ โโโ โโโ โโโโโโ โโโโโโโโโ โโโโโโโโ โโโโโโโ
// โโโโโโโโโโโ โโโโโโโโโโโโโ โโโโโ โโโโโโ โโโโโโโโโ โโโโโโโโ โโโโโ
// โโโ... |
/* ============================================================================
>4SESz., _, ,gSEE2zx.,_ .azx ,w.
@Sh. "QEE3. JEE3. &ss `*4EEEEE2x.,_ "EEV ,aS5^;dEEEE2x., VEEF _
\E2`_,gF4EEEx.?jF EE5L `*4EEEEE2zpn..ZEEF ;sz. `*EEESzw.w* '|EE.
,dEEF `"?j] _,_ ,_... |
๏ปฟ#pragma strict
var walls:GameObject[];
var activatedWalls:int[];
//this runs in the editor, when things change
function OnValidate() {
UpdateVisibility();
}
function UpdateVisibility() {
for(var i=0; i<walls.Length; i++) {
SetVisibility(walls[i],activatedWalls[i]);
}
}
//this will set the visibility of an obj... |
var gulp = require('gulp');
var util = require('gulp-util');
var inject = require('gulp-inject');
var sass = require('gulp-sass');
var notify = require('gulp-notify');
var eslint = require('gulp-eslint');
var minifyCSS = require('gulp-minify-css');
var browserify = require('gulp-b... |
#!/usr/bin/env node
/* This file is part of the Readability2 project.
* https://github.com/mvasilkov/readability2
* Copyright (c) 2018 Mark Vasilkov (https://github.com/mvasilkov)
* License: MIT */
const chalk = require('chalk')
const { table } = require('table')
const { Score } = require('./utils')
const PAGES_D... |
// Portfolio
(function($) {
"use strict";
var $container = $('.portfolio'),
$items = $container.find('.item'),
portfolioLayout = 'fitRows';
if( $container.hasClass('portfolio-centered') ) {
portfolioLayout = 'masonry';
}
$container.isotope({
filter: '*',
animationEngine: 'best-available',
... |
/* parser generated by jison 0.4.17 */
/*
Returns a Parser object of the following structure:
Parser: {
yy: {}
}
Parser.prototype: {
yy: {},
trace: function(),
symbols_: {associative list: name ==> number},
terminals_: {associative list: number ==> name},
productions_: [...],
perfo... |
describe('setting: offset', function() {
context('global', () => {
before(() => {
cy.visit('/');
});
context('400px', () => {
before(() => {
cy.initAOS({
offset: 400
});
});
it('Should animate 3 items', function() {
cy.get('.aos-animate').should(... |
function send_vote(self, vote){
var uvote = parseInt(vote);
var row = $(self).closest("tr");
var dist = parseFloat(row.find("td#dist").text());
var text = row.find("td#text").text();
var img_url = row.find("td>img#img_url").attr("src");
var query_text = $("table>tbody>tr>td#query_text").text();... |
'use strict';
angular.module('hrApp', [
'ngRoute',
'hrApp.main',
'hrApp.settings'
])
.config(['$routeProvider', '$sceDelegateProvider', function ($routeProvider, $sceDelegateProvider) {
$routeProvider.otherwise({redirectTo: '/main'});
$sceDelegateProvider.resourceUrlWhitelist([
'self',
'http://habrahab... |
module.exports = 'file3';
|
const draw = (height = 4, pipeWidth = 2) => {
const width = height * 2 + pipeWidth,
leftBorder = height + 1,
rightBorder = height + pipeWidth;
for(let i = 1; i <= height; i++) {
let line = '';
for(let j = 1; j <= width; j++) {
let condition = j >= leftBorder - i && j < leftBorder || j > rightBorder && j ... |
'use strict';
// Use applicaion configuration module to register a new module
ApplicationConfiguration.registerModule('scriptcam')
.directive('scriptcamera', [
function() {
return {
restrict: 'AE',
link: function(scope, element, attrs) {
var initialized = false;
... |
/*
Script: Language.ru.js
MooTools FileManager - Language Strings in Russian
Translation:
[Ilya V. Goryachev](http://cok-studio.ru/)
*/
FileManager.Language.ru = {
more: 'ะะพะดัะพะฑะฝะตะต',
width: 'ะจะธัะธะฝะฐ:',
height: 'ะััะพัะฐ:',
ok: 'Ok',
open: 'ะัะฑัะฐัั ัะฐะนะป',
upload: 'ะะฐะณััะทะบะฐ',
create: 'ะกะพะทะดะฐัั ะฟะฐะฟ... |
const Middleware = require('.');
singleton('Ivy/MiddlewareContainer', () => {
return new Middleware;
}); |
import './share.scss';
|
"use strict";
var zipWith = regeneratorRuntime.mark(
// zipWith :: (a -> b -> c) -> [a] -> [b] -> [c]
function zipWith(f, a, b) {
var aIterator, bIterator, aObj, bObj;
return regeneratorRuntime.wrap(function zipWith$(context$1$0) {
while (1) switch (context$1$0.prev = context$1$0.next) {
case 0:
... |
'use strict';
var Backbone = require('backbone');
var localBus = require('../lib/local-bus');
var globalBus = require('ses-core').globalBus;
var SawView = module.exports = Backbone.View.extend({
events: {
'click': 'onclicked'
},
onclicked: function () {
localBus.trigger('saw');
globalBus.trigger('... |
#!/usr/bin/env node
/*
* Automate the process of farming hangout URLs using a selenium browser.
* Requires a configuration file, "farmingConf.json", which contains google
* credentials for the account which will do the farming, containing the
* following:
*
* {
* "serverUrl": "https://unhangout.media.mit.edu",... |
import React from 'react' // required for JSX
import Header from './Header'
import ContactList from './ContactList'
export default class App extends React.Component {
render () {
return (
<div>
<Header />
{ this.props.children }
</div>
)
}
}
|
/**
*
* Smyle Developer common
*
* @author Subburajan Mayilandan
* @date February 2013
*
***************************************************************************************8***/
$2("validator", ["lang", "date-format"], function(S) {
function Base_V() {
return this;
}
Base_V.prototype... |
app.service('softInfo',function($cookieStore,$rootScope,$http){
this.version='v1.0';
this.domain="";//"http://39.108.15.12:9966";
this.excel_url=this.domain+'/v1/exportact';//ๅฏผๅ
ฅexcelๅฐๅ
this.excel_url_transfer=this.domain+'/v1/txexport';//ๅฏผๅบ่ชๅจ่ฝฌ่ดฆexcelๅฐๅ
this.excel_url_transfer_single=this.domain+'/v1/txexportsingle'... |
// --------------------------------------------------
var Filter = (function() {
var mulTable = [1,57,41,21,203,34,97,73,227,91,149,62,105,45,39,137,241,107,3,173,39,71,65,238,219,101,187,87,81,151,141,133,249,117,221,209,197,187,177,169,5,153,73,139,133,127,243,233,223,107,103,99,191,23,177,171,165,159,77,149,9,13... |
var J, JustJS;
((function(){
var bindList = {
object: [ 'clone', 'equal', 'at', 'debug' ],
array: [ 'clone', 'equal', 'swap', 'intersect', 'unite' ],
number: [ 'clone', 'equal' ],
string: [ 'clone', 'equal', 'removeSpace', 'holeStr' ]
};
var functionContainer = {
ob... |
import { PrintablePrimitive } from './printable_primitive.js';
import { displayNativeString, writeNativeString } from './print_native_string.js';
import { isEqual } from './equality.js';
import { hashArray } from './raw_hashing.js';
import { hashForEqual } from './hashing.js';
import { racketCoreError } from './errors.... |
import React, { PropTypes } from 'react';
import Wrapper from './Wrapper';
function QAEntry({ entry }) {
return (
<Wrapper>
<div>Q: {entry.question}</div>
<div>A: {entry.answer}</div>
</Wrapper>
);
}
QAEntry.propTypes = {
entry: PropTypes.object.isRequired,
};
export default QAEntry;
|
/* eslint-env jest */
// Mock localStorage
const globalObject = require('../../src/util/get-global')()
const localStorage = require('../mocks/local-storage')
globalObject.localStorage = localStorage
const logdown = require('../../src/browser')
describe('localStorage.debug', () => {
beforeEach(() => {
console.l... |
/*
* This file is part of the Tempo-project package http://tempo-project.org/>.
*
* (c) Mlanawo Mbechezi <mlanawo.mbechezi@ikimea.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
'use strict';
var RouterManager = require('./router.... |
const knex = require('../../../knex').web
module.exports = function (isT2A = false) {
isT2A = (isT2A === true)
// WMT0160: add new tiers
// WMT0229 Change needed here when extract column names are known
return knex('workload_points')
.withSchema('app')
.first('id AS workloadPointsId',
'comm_tier... |
log = loglevel.createPackageLogger('practicalmeteor:test-in-velocity', 'debug');
|
'use strict';
var
// Acetone
AcetoneLayout = require('../lib/Layout/Layout');
/**
* Layout
*/
function Layout(acetone, options)
{
// Constructor
AcetoneLayout.call(this, acetone, options);
// Acetone default options
acetone.options
.setDefault('destDir', 'public');
}
Layout.prototy... |
import controller from './user-detail.controller.js'
export const UserDetailComponent = {
bindings: {
user: '<'
},
controller,
template: `
<article class="card">
<section class="card-content">
<div class="row">
<form class="col s12 mt-20" ng-submit="$ctrl.submitForm($ctrl.user... |
const Mode = Object.freeze( { "interval":1, "timeout":2, "scheduled":3 } );
// TODO: Properly handle promise based functions
class Periodic
{
constructor( interval_ms, mode, func )
{
// Private members
this._interval = interval_ms;
this._mode = Mode[ mode ];
this._isRunni... |
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { Link } from 'react-router';
class Header extends Component {
renderSignLinks() {
if (this.props.authenticated === true) {
// show links to report, practice, and signout
return (
<div className="col-lg-7... |
import Ember from 'ember';
const cloudinary = Ember.$.cloudinary;
const { computed, get, merge } = Ember;
const { notEmpty } = computed;
export default Ember.Component.extend({
classNames:['CloudinaryImgView'],
classNameBindings:['hasImage'],
cloudinaryId: null,
alt: null,
height: null,
width: null,
fo... |
/**
* Developer: Stepan Burguchev
* Date: 5/22/2015
* Copyright: 2009-2016 Comindware
* All Rights Reserved
* Published under the MIT license
*/
import comparators_ from './comparators';
import helpers_ from './helpers';
import htmlHelpers_ from './htmlHelpers';
import dateHelpers_ from './dateH... |
var connectDomain = require('connect-domain');
var ejs = require('ejs');
var express = require('express');
var _handlers = require('./handlers');
var partials = require('express-partials');
var fs = require('fs');
var log4js = require('log4js');
var nconf = require('nc... |
const lucifyDeployConfig = require('lucify-deploy-config').default; // eslint-disable-line
const opts = {
publicPath: (env) => {
if (env === 'production' || env === 'staging') {
return '/embed/lucify-asylum-countries/';
}
return null;
},
};
module.exports = lucifyDeployConfig(null, opts);
|
var d3 = require("d3");
var Model = require("model-js");
var ChiasmDataset = require("chiasm-dataset");
var getColumnMetadata = ChiasmDataset.getColumnMetadata;
module.exports = function scale(my, name){
var scaleName = name + "Scale";
var scaleDomain = name + "ScaleDomain";
var scaleRange = name + "Scale... |
'use strict';
define([
'underscore',
'backbone',
'handlebars',
'presenter',
'collections/overallRanking',
'collections/pillarScoreRanking',
'collections/ranking-scores',
'views/federal-disclaimer',
'views/chartView',
'text!../../layouts/ranking-content.handlebars'
], function(_, Backbone, Handlebar... |
/**
* A GEDCOM X document.
*
* @constructor
* @param {Object} [json]
*/
var GedcomX = function(json){
return new GedcomX.Root(json);
};
// Export early so that circular dependencies work properly
module.exports = GedcomX;
// Expose utils so that extension libraries can use them
GedcomX.utils = require('./util... |
//
const cp = require('child_process')
const crypto = require('crypto')
const fs = require('fs')
const glob = require('glob')
const rimraf = require('rimraf')
const {join, relative} = require('path')
const {SESSION_DIR, MAX_CLONE_DURATION_MS} = require('../config')
const {store, actions} = require('./ac... |
'use strict';
var Resource = require('./Resource');
var Request = require('../Request');
var utils = require('../Utils');
var extend = require('extend');
var ResourceTypes = require('../constants/resourceTypes');
/**
* Inputs Resource
*
* @param {object} options - SDK Options.
* @class
* @extends Resource
*/
fu... |
import React, { Component, PropTypes } from 'react';
import { connect } from 'react-redux';
import Helmet from 'react-helmet';
import { fetchUserStarredList, loadUserStarredList, loadUserStarredListMore }
from '../../actions/entry.js';
import Translated from '../../components/ui/Translated.js';
import InfiniteScroll ... |
"use strict";
var w = 780; //width
var h = 400; //height
var padding = {
top: 40,
right: 190,
bottom: 40,
left: 45
};
var stack = d3.layout.stack();
var colorsList = ["#000000", "#3300BB", "#1f77b4", "#2ca02c", "#999955", "#ff7f0e", "#ff0000", "#ff69b4", "#992299", "#551a8b", "#777777"];
//Easy colo... |
/*
* @project YASMIJ.js, 'Yet another simplex method implementation in Javascript'
* @author Larry Battle
* @license MIT License <http://www.opensource.org/licenses/mit-license>
*/
var YASMIJ = require('./YASMIJ.base.js');
/**
* Output Class
* @constructor
*/
var Output = function (obj) {
this.result = obj;
t... |
// CodeMirror, copyright (c) by Marijn Haverbeke and others
// Distributed under an MIT license: http://codemirror.net/LICENSE
(function(mod) {
if (typeof exports == "object" && typeof module == "object") // CommonJS
mod(require("node_modules/codemirror/lib/codemirror.js"));
else if (typeof define == "function... |
'use strict';
const { Project, Role, Tool, behaviorFactory } = require('cv-core');
const restify = require('restify');
const util = require('../util');
const getProjectBehavior = util.getBehavior(behaviorFactory.types.PROJECT);
const projectSchema = {
id: '/project',
type: 'object',
properties: {
name: {
... |
/**
* Module dependencies.
*/
var merge = require('utils-merge')
, AuthorizationError = require('../errors/authorizationerror');
/**
* Handles requests to obtain a response with an access token and ID token.
*
* References:
* - [OpenID Connect Standard 1.0 - draft 21](http://openid.net/specs/openid-connect-s... |
var nconf = require('nconf');
nconf.file('settings.json').env();
var client = new Evernote.Client.new({
consumerKey: nconf.get('Consumer Key'),
consumerSecret: nconf.get('Consumer Secret'),
sandbox: true // Optional (default: true)
});
/*
client.getRequestToken('YOUR CALLBACK URL', function(error, oauthToken, o... |
exports.BUFFER_SIZE = 2048;
|
'use strict';
// Examinations controller
angular.module('examinations').controller('ExaminationsController', ['$scope', '$stateParams', '$location', 'Authentication', 'Examinations', 'lodash', '$q', 'Patients', 'CoreProperties', 'ActionsHandler', 'Toolbar', 'Logger',
function ($scope, $stateParams, $location, Auth... |
import React, { Component } from 'react';
import moment from 'moment';
var embeddedScript = '<!-- TradingView Widget BEGIN -->' +
' <script type="text/javascript" src="https://d33t3vvu2t2yu5.cloudfront.net/tv.js"></script>' +
' <script type="text/javascript">' +
' new TradingView.widget({'... |
var related__4_8js =
[
[ "searchData", "related__4_8js.html#ad01a7523f103d6242ef9b0451861231e", null ]
]; |
function clickHandlers(){
removeFromTable("bayiler","/iletisim/sil",function(){});
}
function formHandlers(){
}
function otherScripts(){
} |
'use strict';
var express = require('express');
var passport = require('passport');
var auth = require('../auth.service');
var router = express.Router();
router
.get('/', passport.authenticate('facebook', {
scope: ['email', 'user_about_me', 'manage_pages', 'manage_notifications', 'publish_pages'],
fail... |
$("body").delegate("[data-do='open-product']", "click", function(){
$.post('/catalog/ajax/get/product/', {
id: $(this).data('product-id'),
csrfmiddlewaretoken: '{{ csrf_token }}'
},
function(data) {
if ('success' == data.status){
// ะะฐะฟะพะปะฝัะตะผ ะฑะฐะทะพะฒัั ะธะฝัะพัะผะฐัะธั ะพ ัะพะฒะฐัะต... |
import React from 'react';
import DropDownMenu from 'material-ui/lib/DropDownMenu';
import MenuItem from 'material-ui/lib/menus/menu-item';
var MenuWrapper = React.createClass({
getInitialState: function(){
return {data:[],value:2};
},
handleChange: function (event) {
this.setState({value: event.target.v... |
'use strict';
/**
* Module dependencies.
*/
var mongoose = require('mongoose'),
User = mongoose.model('User'),
Operation = mongoose.model('Operation'),
async = require('async'),
config = require('meanio').loadConfig(),
crypto = require('crypto'),
templates = require('../template');
/**
* Auth callback
*/
exports... |
/* global JSON */
import {Promise} from 'es6-promise';
import xmlhttprequest from 'xmlhttprequest';
export {METADATA_KEY} from './consts.js';
import handler from './handler.js';
var _config = {
endPoint: ''
};
var _requestJSON = function (method, path, bodyObject) {
// relative starts with '/'
var url = path[... |
// Generated on 2014-03-14 using generator-angular 0.7.1
'use strict';
// # Globbing
// for performance reasons we're only matching one level down:
// 'test/spec/{,*/}*.js'
// use this if you want to recursively match all subfolders:
// 'test/spec/**/*.js'
module.exports = function (grunt) {
// Load grunt tasks au... |
import React, { Component } from 'react';
import SongSearch from './SongSearch';
import SearchResult from './SearchResults.js';
class Room extends Component {
render() {
return (
<div>
<SongSearch />
<SearchResult />
</div>
);
}
}
export de... |
"use strict";
/**
* input api
*/
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
var tip_1 = __importDefault(require("../Message/tip"));
exports.default = {
met... |
module.exports = {
'comment': 'ไปฅไธๆฏ็คบไพๅ
ๅฎน๏ผไฝฟ็จๆถ้่ฆไฟฎๆนไธบ้กน็ฎๅฎ้
้่ฆ็ๅ
ๅฎนๅนถๅฟ
้กปๅ ้คๆฌๆฎตๆณจ้',
'../public/js/all.js': ['../public/js/prettify.js', '../public/js/lang-css.js', '../public/js/main.js'],
'../public/style/css/main.css': ['../public/style/css/logic.css', '../public/style/css/widget.css']
};
|
import { Map } from 'immutable'
import { normalize, schema } from 'normalizr'
import { createReducer } from '@cheesecakelabs/boilerplate/utils'
import { GET_REPOSITORY, AUTHORIZE } from './actions'
export const INITIAL_STATE = new Map()
export const repositorySchema = new schema.Entity('repository', {}, { idAttribute... |
window.DS = Ember.Namespace.create({
// this one goes past 11
CURRENT_API_REVISION: 12
});
|
/**
* @namespace GeometryTools
* @memberof SQR
*
* @description Tools to work with geometries/buffers.
*/
SQR.GeometryTools = (function() {
var geoTools = {};
var MAX_BUFFER_SIZE = 65535;
/**
* @method batch
* @memberof SQR.GeometryTools
*
* @description Combines all the geometries in a tree into o... |
angular.module('sgRequest', ['sgPersistent'])
.service('RequestService', [ '$q', 'Persistent',
function($q, Persistent){
/**
* This is a private function to have common functionality
* of request handler
*/
var _requestHandler = function(model, success, error, deferred){
var sucessHandler = ... |
#!/bin/sh
var config = require('../config/app');
var server = require('../src/server');
var broker = require('../src/broker');
var log = require('../src/log');
broker.start(function() {
log.info('Events broker server started on %s', config.broker.host);
server.listen(config.port, function() {
log.info('%s li... |
/**
* grunt/pipeline.js
*
* The order in which your css, javascript, and template files should be
* compiled and linked from your views and static HTML files.
*
* (Note that you can take advantage of Grunt-style wildcard/glob/splat expressions
* for matching multiple files.)
*/
// CSS files to inject in orde... |
/*!
* mustache.js - Logic-less {{mustache}} templates with JavaScript
* http://github.com/janl/mustache.js
*/
var Mustache = (typeof module !== "undefined" && module.exports) || {};
(function( exports ) {
exports.name = "mustache.js";
exports.version = "0.5.0-dev";
exports.tags = ["{{", "}}"];
exports.parse = ... |
import React from 'react';
import PropTypes from 'prop-types';
import styles from './<%= ComponentName %>.css';
const <%= ComponentName %> = ({ children }) => {
return (
<div>
{children}
</div>
);
};
<%= ComponentName %>.propTypes = {
children: PropTypes.node,
};
export default <%= ComponentName %>;
|
"use strict";
window.keyboardMap = ["", // [0]
"", // [1]
"", // [2]
"CANCEL", // [3]
"", // [4]
"", // [5]
"HELP", // [6]
"", // [7]
"BACK_SPACE", // [8]
"TAB", // [9]
"", // [10]
"", // [11]
"CLEAR", // [12]
"ENTER", // [13]
"ENTER_SPECIAL", // [14]
"", // [15]
"SHIFT", // [16]
"CONTROL", // [17]
"ALT", // [18]
"PAU... |
/**
* Created by dcreey on 8/23/2016.
*/
'use strict';
exports.register = function (server, options, next) {
const web = server.select('web-ui');
// register core web end-points
web.route({
method: 'GET',
path: '/{param*}',
handler: {
directory: {
path... |
/**
* Abstract assertion class that will subclass all defined Chai assertions
*
* All assertions must implement the following api:
*
* - @type {function}
* executeCommand
* - @type {string}
* elementFound
* - @type {function}
* elementNotFound
* - @type {function}
* retryCommand
* - @type {string}
... |
/**
* Event emitter for JS.
*
* Inspired by https://github.com/component/emitter
*
* @author Dumitru Uzun (DUzun.Me)
* @license MIT
* @version 2.2.0
* @repo https://github.com/duzun/onemit
*/
/* Usage:
*
* OnEmit(obj);
* The `OnEmit` may also be used as a mixin.
* ... |
/*
* Package Import
*/
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
/*
* Local Import
*/
// Components
import Form from 'src/components/Contact/Form';
// Actions
import { handleInputChange } from 'src/store/ducks/form';
import { sendMessage } from 'src/store/middleware';
... |
// Load required packages
var passport = require('passport');
var BasicStrategy = require('passport-http').BasicStrategy;
var User = require('../models/user');
passport.use(new BasicStrategy(
function(email, password, callback) {
User.findOne({ email: email }, '+password', function (err, user) {
if (err) {... |
/**
* @fileOverview ๆฅๆๆงไปถๆฅ้ๆฉๅนดๆ็้จๅ
* @ignore
*/
var $ = require('jquery'),BUI = require('bui-common'),
PREFIX = BUI.prefix,
Component = BUI.Component,
CLS_TEXT_YEAR = 'year-text',
CLS_TEXT_MONTH = 'month-text',
CLS_ARROW = 'x-datepicker-arrow',
CLS_PREV = 'x-datepicker-prev',
CLS_NEXT = 'x-datepicker... |
'use strict';
var path = require('path');
var clientSrc = path.join(__dirname, 'client', 'src');
var clientDest = path.join(__dirname, 'client', 'web');
module.exports = {
paths: {
styles: {
src: path.join(clientSrc, 'styles'),
dest: path.join(clientDest, 'styles')
},
... |
define(function(require, exports, module) {
var $ = require('$')
var data = require('./data')
var Ball = require('./ball')
var initShowInters = []
var randomShowInter
var youarehereInter
var BaseColors = {
wd: '#005A8D',
ur: '#007938',
id: '#795520',
vd: '#B9... |
bright = angular.module('bright');
bright.service('FileService', ['$http', '$q', function($http, $q) {
var folders, files, selectedFolder, selectedFile;
return {
GetFiles : function(parent) {
var deferred = $q.defer();
$http.post('/bright/json/core/factories/FileFactory/GetFiles', {a... |
'use strict';
var mongoose = require('mongoose');
var BaseSchema = require('../base/model.js');
var crypto = require('crypto');
var MemberSchema = require('../member/member.model.schema');
var Schema = mongoose.Schema;
var workingDaySchema = new Schema({
active: {
type: Boolean,
default: false
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.