code stringlengths 2 1.05M |
|---|
import FieldView from '../Field'
import View from '../../View'
/**
* Text field view
*/
export default class TextFieldView extends FieldView {
/**
* Constructor
*/
constructor () {
super()
this._$input = null
}
/**
* Retrieves value from model and updates it in view.
* @return {FieldVie... |
"use strict";
export const AUTO = "auto";
export const CURSOR = "cursor";
export const COL_RESIZE = "col-resize";
export const ROW_RESIZE = "row-resize";
export const ESCAPE_KEY_CODE = 27;
|
var TextV = React.createClass({displayName: "TextV",
getInitialState: function(){
return {value: ''};
},
handleChange : function(e){
this.setState({value: e.target.value});
},
render: function () {
var value = this.state.value;
return(React.createElement("div", {className: "form-group"},
React.... |
// Tally Votes in JavaScript Pairing Challenge.
// I worked on this challenge with:
// This challenge took me [#] hours.
// These are the votes cast by each student. Do not alter these objects here.
var votes = {
"Alex": { president: "Bob", vicePresident: "Devin", secretary: "Gail", treasurer: "Kerry" },
"Bob": {... |
// text will be translated, it's just react-intl code
// translations inside app/componentsFilters/messages
const areas = [
{ code: 1, text: 'visualdiscrimination' },
{ code: 2, text: 'auditorydiscrimination' },
{ code: 3, text: 'language' },
{ code: 4, text: 'phonology' },
{ code: 5, text: 'morphosyntax' },
... |
var Mousetrap = require('mousetrap');
var $ = require('jquery');
var dispatcher = {
// Event Pub/Sub System
//
// Topics used:
// [headCellClicked] - A head cell was clicked
// @return {array} [row, column]
// [cellSelected] - A cell was selected
// @return {array} [row, colu... |
'use strict'
const tman = require('tman')
const should = require('should')
const thunk = require('thunks')()
const redis = require('../..')
tman.suite('commands:List', function () {
let client, client1
tman.before(function () {
client = redis.createClient({ database: 0 })
client.on('error', function (err... |
// This is a manifest file that'll be compiled into application.js, which will include all the files
// listed below.
//
// Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
// or any plugin's vendor/assets/javascripts directory can be referenced here using a relative ... |
import React from 'react';
import Store from './Store';
function buildList(array) {
return array.sort((a, b) => b.address - a.address)
.map((store) => {
return (
<Store key={store._id} {...store} />
);
});
}
const StoreMap = (props) => {
return (
<div className="map-container">
... |
var searchData=
[
['memory_20management',['Memory Management',['../group__CMSIS__RTOS__MemoryMgmt.html',1,'']]],
['message_20queue',['Message Queue',['../group__CMSIS__RTOS__Message.html',1,'']]],
['mutex_20management',['Mutex Management',['../group__CMSIS__RTOS__MutexMgmt.html',1,'']]],
['memory_20pool',[... |
/**
* @fileOverview A partical object for game rules.
* @author kclv@ermitejo.com (MORIYA Masaki, alias Gardejo)
* @license The MIT license (See LICENSE file)
*/
'use strict';
// ================================================================
// Game Rules
// ===========================================... |
/*
jQuery deparam is an extraction of the deparam method from Ben Alman's jQuery BBQ
http://benalman.com/projects/jquery-bbq-plugin/
*/
(function ($) {
$.extend($, {
deparam: function (params, coerce) {
var obj = {},
coerce_types = { 'true': !0, 'false': !1, 'null': null };
// Iterate o... |
import { createAction, handleActions } from 'redux-actions'
// ------------------------------------
// Constants
// ------------------------------------
export const MOVE = 'MOVE'
export const UNDO_MOVE = 'UNDO_MOVE'
// ------------------------------------
// Actions
// ------------------------------------
export con... |
var common_8h =
[
[ "InputEventCallbacks", "structInputEventCallbacks.html", "structInputEventCallbacks" ],
[ "display_update", "structdisplay__update.html", "structdisplay__update" ],
[ "display_switch", "structdisplay__switch.html", "structdisplay__switch" ],
[ "kb_update", "structkb__update.html", "s... |
// Karma configuration
// Generated on Tue Oct 06 2015 18:55:22 GMT+0200 (CEST)
'use strict';
module.exports = function (config) {
config.set({
// base path that will be used to resolve all patterns (eg. files, exclude)
basePath: '',
// frameworks to use
// available frameworks: https://npmjs.org/b... |
import Link from 'next/link'
import ErrorMessages from '../ErrorMessages'
import Loader from '../Loader'
import Avatar from '../Avatar'
import { useApi, useUser } from '../../utils'
import PageHeader from '../PageHeader'
const PlayerAlts = ({ id, color }) => {
const { hasServerPermission } = useUser()
const { load... |
import React from 'react';
import moment from 'moment';
import {ComponentAsFactory, bind} from '../tools';
import EpisodeTrackingStore, {epStatus} from '../stores/EpisodeTrackingStore';
function pad(num) {
return num < 10 ? '0'+num : num;
}
export class EpisodeTracking extends React.Component {
constructor(pro... |
import styled from 'styled-components';
export const Button = styled.button`
background-color: #f3f3f3;
border-radius: .3rem;
font-size: .75rem;
padding: .4rem;
text-transform: uppercase
width: 32%;
&:hover {
background-color: #cccccc;
}
`;
export const Container = styled.div`
display: flex;
... |
/* */
var toString = require('./toString');
/**
* Replaces matches for `pattern` in `string` with `replacement`.
*
* **Note:** This method is based on
* [`String#replace`](https://mdn.io/String/replace).
*
* @static
* @memberOf _
* @since 4.0.0
* @category String
* @param {string} [string=''] The string to ... |
/*
Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.plugins.setLang( 'pastetext', 'es', {
button: 'Pegar como Texto Plano',
title: 'Pegar como Texto Plano'
} );
|
import React from "react";
import { bindActionCreators } from "redux";
import { connect } from "react-redux";
import { fetchUpcomingReleases } from "../actions/index.js";
import { Link } from "react-router-dom";
import Loader from "../components/Loader";
class UpcomingReleases extends React.Component {
componentDi... |
var _ = require('lodash');
var path = require('path');
var Config = (function() {
var self;
function BuildConfig(options) {
self = this;
var config = _.defaults(options || {}, BuildConfig.DEFAULTS);
// Make source directory relative to root
config.src.root = this._absolutify(config.root, config.s... |
import validators from '../utils/validators';
export default {
data: {
text: '',
userId: null
},
validators: {
text: [validators.isRequired],
userId: [validators.number.isRequired]
},
fields: [
{
key: 'text',
type: 'text',
props: (form) => {
return {
fl... |
/*global Codes, Config */
var ReconnectPage = function (window) {
"use strict";
this.window = window;
this.document = this.window.frames[Config.RECONNECT_IFRAME_ID].contentWindow.document;
this.hide();
};
ReconnectPage.prototype = {
show: function () {
"use strict";
this.document.bo... |
export default function socketAuth(app) {
return (socket, next) => {
const { cookie } = socket.request.headers;
const cookies =
cookie &&
cookie.split('; ').reduce((prev, nextCookie) => {
const [name, value] = nextCookie.split('=');
return {
...prev,
[name]: val... |
var express = require('express');
var bodyParser = require('body-parser');
var app = express();
var slackEvents = require('./index')(false, function (slackEvent, cb) {
console.log(slackEvent);
cb();
});
app.use('/slack_events', bodyParser.json(), slackEvents);
app.listen(3000);
|
//Image array
var imageNames = ["bag.jpg", "banana.jpg", "boots.jpg", "chair.jpg", "cthulhu.jpg", "dragon.jpg", "pen.jpg", "scissors.jpg", "shark.jpg", "sweep.jpg", "unicorn.jpg", "usb.jpg", "water_can.jpg", "wine_glass.jpg"];
//adds image
function addImage(imageFileName) {
var container = document.getElementById("i... |
// Karma configuration
// Generated on Wed Oct 10 2012 14:10:32 GMT-0700 (PDT)
// base path, that will be used to resolve files and exclude
basePath = '../..';
// list of files / patterns to load in the browser
files = [
MOCHA,
MOCHA_ADAPTER,
'node_modules/expect.js/expect.js',
'src/**/*.js'
];
// list of... |
const packageName = 'line-awesome'
const distName = 'line-awesome'
const iconSetName = 'Line Awesome'
const prefix = 'la'
// ------------
const glob = require('glob')
const { copySync } = require('fs-extra')
const { readFileSync, writeFileSync } = require('fs')
const { resolve, basename, join } = require('path')
let... |
/**
*
*/
function Display(canvas) {
this.ctx = canvas.getContext('2d');
this.width = canvas.width = 256;
this.height = canvas.height = 240;
this.data = this.ctx.createImageData(this.width, this.height);
this.uint32 = new Uint32Array(this.data.data.buffer);
}
Object.assign(Display.prototype, {
isDisplay... |
/**
* @class Oskari.mapframework.event.common.AfterChangeMapLayerOpacityEvent
*
* Triggers when a
* Oskari.mapframework.request.common.ChangeMapLayerOpacityRequest is received.
* The event includes the maplayer with the modified opacity.
*/
Oskari.clazz.define('Oskari.mapframework.event.common.AfterChangeMapLayer... |
$(document).ready(function() {
// This callback function is invoked when the page is done loading
// Features
navigationClick();
menuBarClick();
startClick();
})
function menuBarClick() {
$($("a").not("#startButton")).click(function() {
$("#practice, #global, #stats, #about").hide();
$($(this).attr("h... |
export { default, gcd } from 'ember-math-helpers/helpers/gcd';
|
/**
* flexo-site-profile - A dead simple, responsive & flexible boilerplate.
* @version v0.12.29
* @link http://getflexo.com
* @author ()
* @license MIT
*/
(function(){var Soyjavi;window.Soyjavi=Soyjavi={version:"1.09.01"},Soyjavi.effect=function(){var resize,scroll,_el;return _el={page:$(window),document:$(... |
import Phaser from 'phaser'
export default class extends Phaser.Sprite {
constructor ({ game, x, y, asset }) {
super(game, x, y, asset)
this.anchor.setTo(0.5)
this.scale.setTo(0.5)
game.physics.enable(this, Phaser.Physics.ARCADE)
this.gravity = 10
this.gravityRadius = 50000
this.eventHori... |
(function () {
'use strict';
angular
.module('farmpros')
.controller('HarvestsListController', HarvestsListController);
HarvestsListController.$inject = ['harvestResolve'];
function HarvestsListController(harvestResolve) {
var vm = this;
vm.harvests = harvestResolve;
}
}());
|
/*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import React from 'react';
import Router from 'react-routing/src/Router';
import http from './core/HttpClient';
import App from './components/App';
import ContentPage from './components/ContentPage';
import ContactPage from './components/ContactP... |
module.exports = s => s.replace(/(_\w)/g, m => m[1].toUpperCase())
|
exports = module.exports = function() {
return function(scope, client, cb) {
process.nextTick(function() {
cb(null, 'USERINFO');
});
};
};
exports['@require'] = [];
|
require('dotenv').load();
var debug = require('debug')('Express4');
var express = require('express');
var app = express();
var http = require('http').createServer(app);
var io = require('socket.io')(http);
var logger = require('morgan');
var cookieParser = require('cookie-parser');
var bodyParser = require('body-parser... |
angular.module('IntoSpectrum').service('$library', function($rootScope, $http, $q) {
var $library = { songs: [] };
var formatSong = function(song) {
song.id = song._id;
delete song._id;
delete song.__v;
return song;
};
$library.loadSongs = function() {
var deferred = $q.defer();
$http.... |
/**
* Module dependencies.
*/
var express = require('express');
var routes = require('./routes');
var user = require('./routes/user');
var http = require('http');
var path = require('path');
var app = express();
// all environments
app.set('port', process.env.PORT || 3000);
app.set('views', __dirna... |
(function(){
'use strict';
angular.module('users')
.service('appContextService', ['$q', appContextService]);
/**
* Users DataService
* Uses embedded, hard-coded data model; acts asynchronously to simulate
* remote data service call(s).
*
* @returns {{loadAll: Function}}
* @constructor... |
var actions = {},
Quickmarks = {},
isAction, callAction, request, sender, callback, url;
isAction = function(action) {
return actions.hasOwnProperty(action);
};
callAction = function(action, config) {
request = config.request;
sender = config.sender;
callback = config.callback;
if (!isRepeat(request... |
$(window).on('load', function() {//main
const
dom = {//assigning switches and slider
sSwitch: $("#switch-s input"),
lSwitch: $("#switch-l input"),
mjSwitch: $("#switch-mj input"),
animationButton: $("#animationButton"),
coneButt... |
import {namespace} from "./def"
import {doc, p} from "../build"
import {is, cmp, cmpStr, cmpNode, P} from "../cmp"
const test = namespace("history")
function type(pm, text) { pm.tr.insertText(pm.selection.head, text).apply() }
function cutHistory(pm) { pm.history.lastAddedAt = 0 }
test("undo", pm => {
type(pm, "a... |
"use strict";
function UserMenu(adminUser) {
return {
restrict: 'A',
replace: true,
templateUrl: '../src/user/user.tpl.html',
scope: {},
bindToController: true,
controllerAs: 'ctrl',
controller: function () {
this.user = adminUser.getCurrentUser();
}
};
}
function AdminUser() {
var currentUser =... |
var gulp = require('gulp');
var source = require('vinyl-source-stream');
var browserify = require('browserify');
var gutil = require('gulp-util');
var coffee = require('gulp-coffee');
// browserify bundle for direct browser use.
gulp.task("bundle", function(){
bundler = browserify('./src/dot_... |
var utils = require('../../src/utils')
describe('utils - DOMNodeName', function () {
function testHTMLFriendlyName (html, friendlyName) {
var div = document.createElement('div')
div.innerHTML = html
var element = div.firstChild
expect(utils.DOMNodeName(element)).toEqual(friendlyName)
}
it('shou... |
(function(){
var domUtils = UM.dom.domUtils;
var widgetName = 'video';
UM.registerWidget( widgetName,{
tpl: "<link rel=\"stylesheet\" type=\"text/css\" href=\"<%=video_url%>video.css\" />" +
"<div class=\"edui-video-wrapper\">" +
"<div id=\"eduiVideoTab\">" +
"... |
'use strict';
var _ = require('lodash');
var del = require('del');
var fs = require('fs-extra');
var Gulp = require('gulp').Gulp;
var os = require('os');
var path = require('path');
var sinon = require('sinon');
var test = require('ava');
var gulp = new Gulp();
var tempPath = path.join(os.tmpdir(), 'liferay-plugin-t... |
{
ReactDOMEventListener._handleTopLevel = handleTopLevel;
}
|
var Promise = require('bluebird');
var fs = require('fs-extra');
var outputFile = Promise.promisify(fs.outputFile);
var exists = Promise.promisify(fs.exists);
var path = require('path');
var _ = require('lodash');
/**
* Write a file to disk.
*
* @param options = {
* rootPath: '/Users/jchansen/my-app/src/models/p... |
(function(Gear, Global, Constants, Util) {
/**
* Shapes are primitive form, such as: rectangles, circles, lines, etc...
* @param {Object} config
*/
var Shape = function(config) {
Gear.Node.call(this, config);
this.nodeType = Constants.NODE_TYPE.SHAPE;
this._colorKey = Gear.Color.getUnique();
Global... |
var should = require('should');
describe('js-yaml-front', function() {
var jsYaml = require('../lib/js-yaml-front')
, fs = require('fs')
, results
, testStr = '---\npost: title one\nanArray:\n - one\n - two\nsubObject:\n obj1: cool\n obj2: two';
testStr += '\nreg: !!js/regexp /pattern/gim';
... |
/**
* Created by Peter on 19.11.2015.
*/
angular.module("darksideApp")
.service("Time", function TimeService($resource) {
return $resource("json/time-periods.json", {}, {});
}); |
var sut = require('../../lib/indent').html;
var expect = require('chai').expect;
var ts = ' ';
describe('apostrophe', function () {
it('Apostrophe in tag', function () {
var expected = `
<div>
<p>I'm the best</p>
</div>
<div>
<p>I"m the best</p>
</div>
`;
expect(sut(expected, {tabString: ts})).to.equal(... |
// @ts-check
const { BundleAnalyzerPlugin } = require("webpack-bundle-analyzer")
const merge = require("webpack-merge")
const { env } = require("../utils/env")
export function bundleAnalyzer(config) {
if (!env.enableWebpackAnalyze) {
return config
}
return merge.smart(config, {
devtool: "none",
sta... |
export default {
key: 'F',
suffix: 'aug7',
positions: [
{
frets: '2314',
fingers: '2314'
},
{
frets: '6556',
fingers: '2113',
barres: 5,
capo: true
},
{
frets: '8998',
fingers: '1221',
barres: [8, 9],
capo: true
},
{
fre... |
//create a new app module (main app)
angular.module("collegeApp", ['collegeControllers']); |
const expect = require('chai').expect;
describe('[TypeScript] Smoke tests', function () {
// TODO: IMPORTANT: Azure test tasks hang when a role is used in a test, fix it immediately
it('Should run non-trivial tests', function () {
return runTests('./testcafe-fixtures/non-trivial-test.ts', null, { skip:... |
describe('Math helpers', function() {
describe('Sum', function() {
it('should return "2" when we sum 1 + 1', function() {
var fields = {
a: 1,
b: 1
},
html = "{{add a b}}",
template = Handlebars.compile(html... |
/* global jQuery, io */
(function($){
var socket = io.connect();
var $log = $('#log');
var $tl = $('#tweetlist');
var $music = $('#music');
var $sounds = $('#sounds');
var areas = {
'cv' : $('#cv'),
'ei' : $('#ei'),
'gr' : $('#gr'),
'hg' : $('#hg'),
'lc' : $('#lc'),
'nb' : $('#nb'),
'sa' : $('#sa'... |
import GL from '@luma.gl/constants';
import {getPassthroughFS} from '@luma.gl/shadertools';
import BufferTransform from './buffer-transform';
import TextureTransform from './texture-transform';
import {isWebGL2} from '@luma.gl/gltools';
import {assert, isObjectEmpty, getShaderVersion} from '@luma.gl/webgl';
import Mod... |
var express = require('express');
var app = express();
var server = require('http').createServer(app);
var io = require('socket.io')(server);
io.on('connection',function (client) {
console.log('Client connected...');
client.emit('messages',{hello:'world'});
// body...
});
app.get('/',function (req, res) {
// bod... |
/**
* @class Detector
* @author Ariel Saldana / http://ariel.io
*/
let detectorInstance = null;
class Detector {
constructor (options) {
// super(options);
if (!detectorInstance) {
detectorInstance = this;
}
this.options = {};
this.options.targets = ... |
version https://git-lfs.github.com/spec/v1
oid sha256:0e52c32bcc50d0154b056444672921ac7d0da8a2d8e67609f37d04e07ef0ad93
size 3397
|
// `Number.MAX_SAFE_INTEGER` constant
// https://tc39.github.io/ecma262/#sec-number.max_safe_integer
require('../internals/export')({ target: 'Number', stat: true }, { MAX_SAFE_INTEGER: 0x1fffffffffffff });
|
(function( root, factory ) {
// Set up appropriately for the environment.
// Start with AMD.
if ( typeof define === 'function' && define.amd ) {
define(
[
'backbone',
'collections/subset/PaginationSubset'
],
function( Backbone, Pagi... |
/**
* Route Generator
*/
const componentExists = require('../utils/componentExists');
module.exports = {
description: 'Add a route',
prompts: [{
type: 'input',
name: 'component',
message: 'Which component should the route show?',
validate: value => {
if ((/.+/).test(value)) {
retur... |
import is_nil from 'lodash/isNil'
export default (value) => !is_nil(value)
|
(function () {
'use strict';
var keyManager = function () {
return {
restrict: 'E',
templateUrl: 'voicebase-tokens/directives/key-manager.tpl.html',
replace: true,
scope: {
},
controllerAs: 'keyManagerCtrl',
controller: function($scope, voicebaseTokensApi, formValidate... |
import { merge } from 'lodash';
import { makeExecutableSchema } from 'graphql-tools';
import query from './query';
import mutation from './mutation';
import authentication from './authentication';
import album from './album';
import artist from './artist';
import genre from './genre';
import user from './user';
import ... |
'use strict';
// Module dependencies.
var express = require('express'),
morgan = require('morgan'),
errorhandler = require('errorhandler'),
chat = require('./server/data/chat-db');
var app = module.exports = exports.app = express();
app.locals.siteName = "ChatModule";
// Connect to database
var db = req... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.ListItem = exports.List = undefined;
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || fa... |
'use strict';
describe('Provider: Devise.Auth', function () {
var AuthProvider;
// load the service's module
beforeEach(module('Devise', function(_AuthProvider_) {
AuthProvider = _AuthProvider_;
}));
// instantiate service
var Auth, $rootScope, $http, $httpBackend;
beforeEach(inje... |
'use strict';
const Promise = require('bluebird');
const co = require('co');
const fs = require('fs-extra');
const merge = require('../utilities/merge');
const Task = require('../models/task');
const debug = require('debug');
module.exports = Task.extend({
run: function (options) {
return new P... |
import glslify from 'glslify'
Object.assign(exports, {
[__dirname + '/fragment/main']: glslify(__dirname + '/fragment/main.glsl'),
[__dirname + '/vertex/main']: glslify(__dirname + '/vertex/main.glsl'),
[__dirname + '/variables']: glslify(__dirname + '/variables.glsl'),
[__dirname + '/uniforms']: glslify(__dir... |
delete require.cache[require.resolve('../lib/configuration')]
const configuration = require("../lib/configuration")
const serializationFormats = require("../lib/serialization-formats")();
describe("Configuration", () => {
it("get default cacheExpiration value if not set", () => {
configuration.cacheExpiration.shoul... |
'use strict';
module.exports = function(grunt) {
grunt.config.set('copy', {
build: {
files: [{
expand: true,
cwd: '<%= pkg.paths.source %>',
src: [
'{,*/}*.{ico,png,txt,html,json}',
'img/**/{,*/}*.{png,jpg,jpeg,gif,webp,svg}'
],
dest: '<%= pkg.pa... |
import 'babel-polyfill'
import React from 'react'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import store from 'modules/state/store'
import { App } from 'modules/app'
render(
<Provider store={store}>
<App />
</Provider>,
document.getElementById('app')
)
|
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import styles from './schoolCard.css';
class SchoolCard extends Component {
render() {
return (
<div className={styles.schoolCard}>
<div className={styles.schoolCardImage}>
<img src={this.props.logo} alt={this.p... |
'use strict';
/**
* Module dependencies.
*/
var mongoose = require('mongoose'),
Schema = mongoose.Schema;
/**
* Itinerary Schema
*/
var ItinerarySchema = new Schema({
date: {
type: Date,
required: 'Please fill Itinerary date'
},
company: {
type: Schema.ObjectId,
ref... |
/*!
* SmoothScroll for websites v1.2.1
* Licensed under the terms of the MIT license.
*
* People involved
* - Balazs Galambosi (maintainer)
* - Michael Herf (Pulse Algorithm)
*/
(function(){
// Scroll Variables (tweakable)
var defaultOptions = {
// Scrolling Core
frameRate : 150, // [Hz]
anima... |
const visit = require('unist-util-visit')
const appendix = require('../type/appendix')
const defaultReferenceGenerator = (appendixIndex) => `Code appendice ${appendixIndex}`
module.exports = (ctx, tree) => {
ctx.overrides.appendix = appendix
return (node) => {
let appendix = tree.children[tree.children.length... |
/* jshint expr:true */
var chai = require('chai'),
expect = chai.expect;
var requirejs = require('requirejs');
var _ = require('lodash');
var jsonModel = require('../model-compiled.json');
var config = require('../../../lib/js/config.js');
requirejs.config(
_.extend(config, {
nodeRequire: require,
base... |
'use strict'
var Promise = require('bluebird')
module.exports = function (urn) {
var self = global.ABIBAO.services.domain
return new Promise(function (resolve, reject) {
self.CampaignModel.get(self.getIDfromURN(urn))
.then(function (model) {
delete model.id
delete model.company
d... |
var gulp = require('gulp');
gulp.paths = {
tssrc: [
'**/*.ts',
'!node_modules/**/*',
'!dist/**/*',
'!typings/**/*',
'!**/*.{ts,coffee}.js'],
jssrc: [
'*.js',
'!angular2-bootstrap.js',
'gulp-tasks/*.js',
'!node_modules',
'!**/*.{ts,coffee}.js']
};
require('require-dir')('./g... |
var searchApp = angular.module('archiveSearch', []);
function mainController($scope, $http) {
$scope.formData ={};
$scope.article = null;
// when submitting the add form, send the text to the node API
$scope.createTodo = function() {
$http.post('/api/todos', $scope.formData)
.success(function(data) {
$sco... |
'use strict';
(function (angular) {
angular
.module('advancedFolderPluginContent')
.controller('ContentHomeCtrl', ['$scope', '$timeout', 'DB', 'COLLECTIONS', 'Buildfire', 'DEFAULT_DATA', 'Modals', 'Messaging', 'Utility',
function ($scope, $timeout, DB, COLLECTIONS, Buildfire, DEFAULT_DA... |
/* jshint node: true */
'use strict';
module.exports = {
name: 'ember-cli-local-storage-wrapper'
};
|
/**
* Implement Gatsby's Browser APIs in this file.
*
* See: https://www.gatsbyjs.com/docs/browser-apis/
*/
// You can delete this file if you're not using it
|
'use strict';
var db = require('../../config/db')();
module.exports = {getAllSlides, saveSlide, getSlide};
/**
* /slides
* Type: GET
* operationId: getAllSlides
* returns array of slides
*/
function getAllSlides(req, res, next) {
db.find(function(slidesNode){
res.json({
slides: slidesNode
... |
function main(e = document.createElement("deepnav")) {
if (!e.children.length) e.innerHTML = template;
else e.children[0].setAttribute("navitem", '');
list(e, 'x');
return e;
} |
'use strict';
// Compatibility functions
// Contain classlist polyfill and bind polyfill
module.exports = function() {
//https://github.com/remy/polyfills/blob/master/classList.js
(function () {
if (typeof window.Element === 'undefined' || 'classList' in document.documentElement) return;
var ... |
var sinon = require('sinon');
var chai = require('chai');
var expect = chai.expect;
var config = {
"path": "/tmp/fake",
"secure_code": "abc",
"remote_name": "origin",
"branch": "master",
"listen_port": 3080
};
var deployment = require('../lib/deployment')(config);
var deploymentAction = deployment.... |
/**
* Module dependencies.
*/
var port = 8080;
var express = require('express');
var routes = require('./routes');
var user = require('./routes/user');
var chat = require('./routes/chat');
var http = require('http');
var path = require('path');
var app = express();
// all environments
app.set('port', process.env.... |
app.directive( "home", function() {
return {
templateUrl: 'js/directives/home-page.php'
};
}); |
'use strict';
/**
* @ngdoc overview
* @name expertioApp
* @description
* # expertioApp
*
* Main module of the application.
*/
angular
.module('expertioApp', [
'ngAnimate',
'ngCookies',
'ngResource',
'ngRoute',
'ngSanitize',
'ngTouch',
'file-model'
])
.config(function ($routePro... |
/**
* net
* @author: SimonHao
* @date: 2016-01-03 13:11:22
*/
'use strict';
var bind = require('bind');
var alert = require('alert.tpl'); |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.