code
stringlengths
2
1.05M
'use strict' //Content Scripts go here console.log('scripts.js running')
import news from './news.js' import user from './users.js' import comment from './comment.js' export default [ news, user, comment ]
var settings = require( "modules/settings" ), throttle = require("modules/throttle"); module.exports = function( el ) { var $el = $( el ), $window = $( window ), timer; settings.scrollContainer = $('.main-wrapper .js-Pjax-add').length > 0 ? $('.main-wrapper .js-Pjax-add') : $( '.inner-wrapper' ); fun...
/** * typescript:commonjscreatevalue * 这个文件由工具生成,请不要手动修改 * * Efront Authors * 2020-05-22T15:06:22.318Z */ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) { Object.defineProperty(o, "default", { enumerable: true, value: v }); }) : function(o, v) { o["default"...
var falcorExpress = require('falcor-express'); var Router = require('falcor-router'); var express = require('express'); var Library = require('./db.json'); var app = express(); app.use('/library.json', falcorExpress.dataSourceRoute(function (req, res) { return new Router([ { route: "books.list", get:...
/*! angular-types - v0.2.0 - * https://github.com/decipherinc/angular-types * Copyright (c) 2015 FocusVision Worldwide; Licensed MIT */ (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'...
'use strict'; angular.module("ngLocale", [], ["$provide", function($provide) { var PLURAL_CATEGORY = {ZERO: "zero", ONE: "one", TWO: "two", FEW: "few", MANY: "many", OTHER: "other"}; function getDecimals(n) { n = n + ''; var i = n.indexOf('.'); return (i == -1) ? 0 : n.length - i - 1; } function getVF(n...
/* global requestAnimationFrame */ export async function waitForGLTFAssets(gltfObjects) { const remaining = []; gltfObjects.scenes.forEach(scene => { scene.traverse(model => { Object.values(model.model.getUniforms()).forEach(uniform => { if (uniform.loaded === false) { remaining.push(u...
export default () => !!( typeof window !== 'undefined' && window.document && window.document.createElement );
import PropTypes from "prop-types"; import React from "react"; import { thumbnailContainer, inputContainer } from "./imageInput.css"; import FileInput from "../FileInput"; import ImagePreview from "../../../imagePreview/ImagePreviewWithDeleteAndHover"; const ImageInput = ({ id, url, onAdd, onDelete }) => url ? ( ...
/** * Various HTTP helper functions and defaults. */ 'use strict'; /** * Module dependencies. */ var crypto = require('crypto'); var debug = require('debug')('swagger-framework:http'); var fresh = require('fresh'); var http = require('http'); var querystring = require('querystring'); /** * Default charset. */...
// Generated by IcedCoffeeScript 108.0.8 (function() { var Parser, alt, alternatives, grammar, name, o, operators, token, tokens, unwrap; Parser = require('jison').Parser; unwrap = /^function\s*\(\)\s*\{\s*return\s*([\s\S]*);\s*\}/; o = function(patternString, action, options) { var addLocationDataFn, ma...
define( 'webAudioAPI' , [ 'utils' ] , function( utils ) { 'use strict'; window.AudioContext = window.AudioContext || window.webkitAudioContext; var context = new AudioContext(); var test = function( sourceURL , spriteName , spriteMap ) { var _this = this; _this.audio = {}; _this.spriteMap = {}; _this...
const { CommentValidationError } = require('../../shared/errors'); function formatCommentResponse(comment) { const clone = { ...comment }; clone.id = clone._id; clone.user = { ...clone._user }; clone.user.id = clone.user._id; delete clone._id; delete clone._user; delete clone.user._id; return clon...
/*! monring - v0.1.0 - 2013-03-25 * https://www.monring.com * Copyright (c) 2013 Arain; Licensed MIT */ this.ayujs = { _ayujs : this.ayujs }; ayujs._utils = {}; ayujs._config = { preload : [] }; ;(function(utils) { var toString = Object.prototype.toString; utils.isArray = Array.isArray || function(val) { ret...
/***************************************************************************/ /* NAVIGATION VISIBLE ON SCROLL */ /***************************************************************************/ $(document).ready(function () { mainNav(); }); $(window).scroll(function () { mainNav(); }); if (matchMedia(...
"use strict"; var _require = require('./index-esm'), uncontrollable = _require.default, useUncontrolled = _require.useUncontrolled; module.exports = uncontrollable; module.exports.useUncontrolled = useUncontrolled; module.exports.uncontrollable = uncontrollable;
#!/usr/bin/env node // We use Node 4 to keep compatibility high, so need the 'use strict' statement. // eslint-disable-next-line 'use strict'; const chalk = require('chalk'); const program = require('commander'); const pack = require('../package.json'); const isImagemagickInstalled = require('../src/imagemagick/is-im...
import Ember from 'ember'; import DS from 'ember-data'; import Model from 'ember-data/model'; import getRequestErrorMessage from 'ghost/utils/ajax'; import ValidatorExtensions from 'ghost/utils/validator-extensions'; import PostValidator from 'ghost/validators/post'; import SetupValidator from 'ghost/validators/setup'...
'use strict'; /** * Module dependencies. */ var mongoose = require('mongoose'), errorHandler = require('./errors.server.controller'), Producto = mongoose.model('Producto'), _ = require('lodash'); /** * Create a Producto */ exports.create = function(req, res) { var producto = new Producto(req.body); producto....
// flow-typed signature: 8cfd8cbd11ff0832877936eb7f30ee34 // flow-typed version: <<STUB>>/eslint-plugin-import_v^2.2.0/flow_v0.37.0 /** * This is an autogenerated libdef stub for: * * 'eslint-plugin-import' * * Fill this stub out by replacing all the `any` types. * * Once filled out, we encourage you to share...
/** * Executes an asynchronous task, and buffers a fixed amount of results. * * @param sourceQueue the queue that feeds data into this queue; can be null * @param createTask function(input, callback) that returns a running * asynchronous task which can be aborted by calling cancel() * ...
var init, TreeWalker, oninitdone, onwalkerfile, onstdindata, onerror, emitter; init = require('../init'); TreeWalker = require('../../TreeWalker'); oninitdone = function oninitdone(path) { var treeWalker; treeWalker = new TreeWalker(path, './directory/subDirectory/hello.txt'); tr...
'use strict'; var dbm; var type; var seed; var fs = require('fs'); var path = require('path'); var Promise; /** * We receive the dbmigrate dependency from dbmigrate initially. * This enables us to not have to rely on NODE_PATH. */ exports.setup = function(options, seedLink) { dbm = options.dbmigrate; type =...
import React from 'react' import { bindActionCreators } from 'redux' import { FlightSearch } from 'routes/Flights/components/FlightSearch' import { shallow } from 'enzyme' describe('(Component) FlightSearch', () => { let _props, _spies, _wrapper beforeEach(() => { _spies = {} _props = { flights : {f...
import * as tslib_1 from "tslib"; import { Injectable, RendererFactory2, ViewEncapsulation } from '@angular/core'; import { PlatformState } from '@angular/platform-server'; import { TransferState } from './transfer-state'; var ServerTransferState = (function (_super) { tslib_1.__extends(ServerTransferState, _super)...
module.exports = function() { this.num = null this.message = null this.stmt = "" this.params = [] }
const chai = require('chai'); const isPostcode = require('../../../app/lib/isPostcode'); const expect = chai.expect; describe('isPostcode', () => { it('should return false for an invalid postcode', () => { const result = isPostcode('Not a postcode'); expect(result).to.be.false; }); it('should return tru...
#! /usr/bin/env node 'use strict'; require('babel-register'); let argv = require('yargs').argv; let path = require('path'); let _ = require('lodash'); let fs = require('fs'); let ncp = require('ncp').ncp; let ejs = require('ejs'); let chalk = require('chalk'); let pjson = require('./package.json'); /...
// generated on 2016-03-23 using generator-webapp 2.0.0 import gulp from 'gulp'; import del from 'del'; import {stream as wiredep} from 'wiredep'; import replace from 'gulp-replace'; var gulpLoadPlugins = require('gulp-load-plugins'); const $ = gulpLoadPlugins(); const config = { htmlFiles: 'src/*.html', fontFile...
var angular = require('angular') angular.module('ngApp', [ require('ngComponentRouter') , require('angular-cookies') , require('angular-animate') , require('angular-messages') , require('angular-resource') , require('angular-material-data-table') , require('angular-material') //make sure ...
var group___c_a_n___public___types = [ [ "CAN_PinCFG_Type", "struct_c_a_n___pin_c_f_g___type.html", [ [ "RD", "struct_c_a_n___pin_c_f_g___type.html#aa0c09653c36b22acfbb2748701b8f4c3", null ], [ "TD", "struct_c_a_n___pin_c_f_g___type.html#ab202627e40dfc220d388c935b8bfc950", null ] ] ], [ "CAN_MSG...
/** * @class consumes * @description 积分消费模块 * @time 2014-12-03 17:42 * @author StarZou **/ (function (window, document) { 'use strict'; var consumes = angular.module('consumes', []); consumes.config(['$stateProvider', function ($stateProvider) { $stateProvider .state('points.consu...
import meta from '../meta'; import actionTypes from '../../constants/actionTypes'; describe('test meta reducer', () => { test('no input', () => { expect(meta(null, { type: actionTypes.SET_META })).toEqual({ description: 'description', keywords: 'keywords', title: 'Title' }); }); });
var tape = require("tape"), map = require(".."); tape("map(array, callback[, thisArg]) creates a new object with the results of calling a provided function on every element in this object", function(assert) { assert.deepEquals( map({ a: "a", b: "b", c: "c" }...
import test from 'tape'; import src from '../src/index.js'; import key from '../src/key.js'; import isObject from 'lodash/isObject.js'; import isFunction from 'lodash/isFunction.js'; import isPlainObject from 'lodash/isPlainObject.js'; test('global', assert => { assert.plan(3); const signal = src; assert.ok(isFunc...
const TodoList = ({todos, onTodoClick }) => ( <ul> { todos.map(todo => <Todo key={ todo.id } {...todo} onClick={ () => onTodoClick(todo.id)} /> )} </ul> ) const Todo = ({ onClick, completed, text }) => ( <li onClick={ onClick } style = {{ textDecoratio...
(function(root, factory) { if(typeof exports === 'object') { module.exports = factory(require, exports, module); } else if(typeof define === 'function' && define.amd) { define(['require', 'exports', 'module'], factory); } else { var req = function(id) {return root[id];}, ...
import { Interface } from 'alien.js'; export class Trackers extends Interface { constructor() { super('.trackers'); this.initHTML(); } initHTML() { this.css({ left: 0, top: 0, width: '100%', height: '100%', zIndex: 2, ...
// Load modules var Hapi = require('hapi'); // Declare internals var internals = {}; internals.fetch1 = function (request, next) { next('Hello'); }; internals.fetch2 = function (request, next) { next(request.pre.m1 + request.pre.m3 + request.pre.m4); }; internals.fetch3 = function (request, next) { ...
var Calculator = function() { this.display = 0 this.operators = [] this.operands = [] this.resetDisplayFlag = true this.sendToDisplayFlag = false this.poppedOperator = null this.poppedOperand = null this.lastKeypress = null } Calculator.prototype = { checkForAllClear: function( value ) { if ( va...
System.register(['./options', './events', './util', 'aurelia-framework', 'aurelia-dependency-injection'], function (_export) { 'use strict'; var pruneOptions, fireKendoEvent, getEventsFromAttributes, _hyphenate, getBindablePropertyName, TaskQueue, Container, WidgetBase; function _classCallCheck(instance, Constr...
import React, {PropTypes} from 'react'; import {Link} from 'react-router'; const CourseListRow = ({course}) => { return( <tr> <td> <a href={course.watchHref} target="_blank">Watch</a> </td> <td> <Link to={'/course/' + course.id}>{course.title}</Link> </td> <td>{cours...
System.register(["angular2/core", "angular2/http", "angular2/router"], function (exports_1, context_1) { "use strict"; var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescr...
/* global test, expect, beforeEach */ import { kea, getContext, resetContext } from '../../src' import './helper/jsdom' import React from 'react' import PropTypes from 'prop-types' import { Provider } from 'react-redux' import { render, screen } from '@testing-library/react' beforeEach(() => { resetContext({ create...
import { combineReducers } from 'redux' import locationReducer from './location' import { reducer as formReducer } from 'redux-form' import { routerReducer } from 'react-router-redux' export const makeRootReducer = (asyncReducers) => { return combineReducers({ location: locationReducer, form: formReducer, ...
(function() { 'use strict'; angular.module('civic.events.genes') .directive('geneTalkRevisionSummary', geneTalkRevisionSummary) .controller('GeneTalkRevisionSummaryController', GeneTalkRevisionSummaryController); // @ngInject function geneTalkRevisionSummary() { var directive = { restrict: 'E...
// Karma configuration // http://karma-runner.github.io/0.12/config/configuration-file.html // Generated on 2015-04-24 using // generator-karma 1.0.0 module.exports = function(config) { 'use strict'; config.set({ // enable / disable watching file and executing tests whenever any file changes autoWatch: tr...
/** * fire focus in correct order * @author yiminghe@gmail.com */ KISSY.add( function (S, Dom, Event) { describe('focus', function () { it('fire is special', function () { var n = Dom.create('<input />'); Dom.append(n, 'body'); var ret = 0; Event.on(n, 'foc...
// Inspired by https://github.com/Inndy/vue-clipboard2 const Clipboard = require('clipboard'); if (!Clipboard) { throw new Error('you should npm install `clipboard` --save at first '); } export default { bind(el, binding) { if (binding.arg === 'success') { el._v_clipboard_success = binding....
'use strict' const APIError = require('./APIError') /** * Internal Server Error error class * * Creates a 500 Internal Server Error error * * @class InternalServerError * @extends Error */ class InternalServerError extends APIError { constructor (text) { super('Internal Server Error', text) this.stat...
import activities from './activities'; import connectivityStatus from './connectivityStatus'; import newMessageButton from './newMessageButton'; import sendBoxTextBox from './sendBoxTextBox'; import suggestedActions from './suggestedActions'; import toastDismissButtons from './toastDismissButtons'; import toasterHeader...
var class_pathfinder_1_1_mod_manager_1_1_attribute_1_1_additional_info_attribute = [ [ "AdditionalInfoAttribute", "class_pathfinder_1_1_mod_manager_1_1_attribute_1_1_additional_info_attribute.html#a3a8084f2d503c290d416f2f54580013a", null ], [ "Info", "class_pathfinder_1_1_mod_manager_1_1_attribute_1_1_additiona...
version https://git-lfs.github.com/spec/v1 oid sha256:1e34e920afb375035beb52ea3ae0f8d25ba1c2c84ffe92546f98ab4ac4282d12 size 5771
/* * jQuery eUtils v0.2 * https://github.com/hubgit/jquery-eutils * * Copyright 2014 Alf Eaton * Released under the MIT license * http://git.macropus.org/mit-license/ * * Date: 2014-01-16 */ (function($) { $.eutils = { search: function(term, params) { var data = $.extend({ db: 'pubmed', retmo...
import React, {PropTypes} from 'react' import styled from 'styled-components' import {Icon, Button} from 'react-materialize' import * as propsValidation from '../../propsValidation' import ADay from './ADay' import {SESSION_SELECTIONS} from '../../../../utils/constants' import {layout, colors} from '../../../../utils/s...
version https://git-lfs.github.com/spec/v1 oid sha256:76489a6b20a5c8d2b7ec73488c6e2cefb66da8758da015d50818cfd645b703b1 size 749
import { debounce } from 'throttle-debounce' import { AttributeValueUpdatedEvent } from 'model/event/RecordEvent' import ServiceFactory from 'services/ServiceFactory' import AbstractFormComponent from '../AbstractFormComponent' export default class AbstractField extends AbstractFormComponent { constructor() { ...
var searchData= [ ['ballocated',['bAllocated',['../struct_c_p_v_r_t_memory_file_system_1_1_s_file_info.html#a2474e11e41143c18e79ae141d1e15085',1,'CPVRTMemoryFileSystem::SFileInfo']]], ['brendertotexture',['bRenderToTexture',['../struct_s_p_v_r_t_p_f_x_parser_texture.html#ad13e2d4687a65a00a27ed83cd9963357',1,'SPVRTP...
/** * @fileoverview Implements the Node.js require.resolve algorithm * @author Nicholas C. Zakas */ "use strict"; //------------------------------------------------------------------------------ // Requirements //------------------------------------------------------------------------------ let lodash = require("...
import { Vector2d, Math2d } from "../shared/math2d"; //import { RenderableGameObject } from "../shared/game"; console.log('Loading renderUtility module ..'); /** * Helps to manage rendering of game objects on screen */ export class RenderUtility { /** * Create a new RenderUtility instance * @param {function(...
require('./lib/spacing.css');
import { $ } from 'uikit-util'; export default { props: { container: Boolean, }, data: { container: true, }, computed: { container({ container }) { return (container === true && this.$container) || (container && $(container)); }, }, };
module.exports = {"RougeScript":{"normal":"RougeScript-Regular.ttf","bold":"RougeScript-Regular.ttf","italics":"RougeScript-Regular.ttf","bolditalics":"RougeScript-Regular.ttf"}};
'use strict'; describe("Authentication", function() { var $window, $httpBackend, $scope, $rootScope, $controller, ctrl; beforeEach(module('myApp')); beforeEach(inject(function(_$window_, _$httpBackend_, _$rootScope_, _$controller_) { $window = _$window_; $httpBackend = _$httpBackend_; ...
(window.webpackJsonp=window.webpackJsonp||[]).push([[5],{188:function(t,e,s){"use strict";s.r(e);var o=["There's nothing here.","How did we get here?","That's a Four-Oh-Four.","Looks like we've got some broken links."],n={methods:{getMsg:function(){return o[Math.floor(Math.random()*o.length)]}}},i=s(0),h=Object(i.a)(n,...
// Quartz.Shape.Polygon // require:core.properties // require:core.util // require:core.points var Polygon = null; (function () { Polygon = qz.Polygon = function (points , offsetX , offsetY) { Points.call(this , points); offsetX != null && (this.offsetX = offsetX); offsetY != null && (th...
"use strict"; var Utils = require('./utils.js'); var VText = new Utils._class({ create : function(text){ this.text = String(text) }, type : Utils.V_TEXT }); module.exports = VText;
var async = require('async'), CentralDirectory = require('./CentralDirectoryFileHeader'); var ZipFile = module.exports.ZipFile = function(/*String*/filePath) { if (!(this instanceof ZipFile)) { return new ZipFile(filePath); } this.filePath = filePath; }; ZipFile.prototype.getCentralDirectory = function (cb) {...
/* Set the defaults for DataTables initialisation */ $.extend( true, $.fn.dataTable.defaults, { "sDom": "<'table-header clearfix'<'table-caption'><'DT-lf-right'<'DT-per-page'l><'DT-search'f>>r>"+ "t"+ "<'table-footer clearfix'<'DT-label'i><'DT-pagination'p>>", "oLanguage": { "sLengthMenu": "Per page: _MENU_"...
module.exports = function(grunt) { // Do grunt-related things in here // Project configuration. grunt.initConfig({ pkg: grunt.file.readJSON("package.json"), nodeunit: { tests: [ "test/communicator.js" ] }, jshint: { options: { curly: true, eqeqeq: true, immed: true, latedef: tru...
import combineActionsMiddleware from 'redux-combine-actions'; import thunkMiddleware from 'redux-thunk'; import { createStore, applyMiddleware, compose } from 'redux'; import createLogger from 'redux-logger'; import reducers from '../reducers'; const middleware = []; middleware.push(combineActionsMiddleware); middle...
export Dashboard from './Dashboard/Dashboard.js'; export HomePage from './HomePage/HomePage.js'; export CoinDetail from './CoinDetail/CoinDetail.js';
var express = require('express'); var router = express.Router(); /* GET home page. */ router.get('/', function(req, res, next) { res.render('index', { title: 'MPI-Sense' }); }); module.exports = router;
/** * Created by way on 16/6/19. * 读取图片拍摄方向,用于修正图片读取、上传时自动调正图片角度。苹果手机拍摄的照片一般是-90度,需旋转90度! * 从exif.js中摘出来的,减少代码大小! */ (function () { var debug = false; var root = this; var ImgOrien = function (obj) { if (obj instanceof ImgOrien) return obj; if (!(this instanceof ImgOrien)) return new ImgOrien(obj)...
(function () { 'use strict'; angular .module('templateApp') .controller('Page2', Page2); Page2.$inject = ['$rootScope', '$firebaseArray', 'FIREBASE_URL']; /* @ngInject */ function Page2($rootScope, $firebaseArray, FIREBASE_URL) { /* jshint validthis: true */ va...
version https://git-lfs.github.com/spec/v1 oid sha256:aa7c774f6af1aea302a0b10d679b93066f0bfa5254c048ad33cb13f52bec0099 size 25905
/* global angular, $ */ (function() { "use strict"; angular .module("contatosJS.users", []); angular .module("contatosJS.users") .config(config); config.$inject = ["$routeProvider"]; function config($routeProvider) { $routeProvider .when("/users", { templateUrl: "modules/users/views/list.html"...
var fixtures = require('../../support/fixtures'), should = require('should'); describe('Item', function() { var Item; before(function(done) { fixtures.Item(function(model) { Item = model; done(); }); }); describe('.validate', function() { describe('invalid data', function() { ...
module.exports = { db: { hostname: 'file_db_hostname', port: 56789 }, server: { hostname: 'file_server_hostname', port: 98765 } };
;(function() { this.Gx = this.Gx || {}; this.Gx.mapTypes = { google: { key: 'ggm', name: 'GoogleMap' }, osm: { key: 'osm', name: 'OpenStreetMap' }, gsi_std: { key: 'gss', name: 'GSI std.' } }; this.Gx.searcherTypes = { google: { key: 'ggc', name: 'Google Geocoding API' }, n...
(function(){var socialTools={myRoot:".top-sharebar-wrapper",init:function(myRoot){stickyShareBar.init();var self=this;myRoot=myRoot||this.myRoot;$myRoot=$(myRoot);$myRoot.each(function(index,myRootElement){if(wp_pb.StaticMethods.staticPostShare)wp_pb.StaticMethods.staticPostShare.init($(myRootElement),$(myRootElement)...
var crypto = require('crypto'); var uuid = require('node-uuid').v4; function BearerTokenStrategy(options) { options = options || {}; this.type = 'bearer'; this.scheme = 'Bearer'; } BearerTokenStrategy.prototype.generate = function(salt) { var unique = uuid(); var salt = salt || 'ARGO__#+'; var expires = D...
/* Copyright © 2012, GlitchTech Science All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the followi...
/* This file is part of Ext JS 4.2 Copyright (c) 2011-2013 Sencha Inc Contact: http://www.sencha.com/contact GNU General Public License Usage This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE in...
////////////////////////////////////////////////////////////////////////////// /** * Copyright (C) 2012 Benjamin Preisig * The JavaScript code in this page is free software: you can * redistribute it and/or modify it under the terms of the GNU * General Public License (GNU GPL) as published by the Free Software *...
import { ESCAPE_KEY, DELETE_KEY } from '../const' import { isValidToEscape } from '../util/isValid' import { getUniqueKey } from '../util/getset' export default function Delete() { if (!(this instanceof Delete)) { return new Delete() } } Delete.patch = function ({ patch, target, prop, old_va...
var fontName = 'seti', gulp = require('gulp'), iconfont = require('gulp-iconfont'), iconfontCss = require('gulp-iconfont-css'), svgmin = require('gulp-svgmin'); exports.font = function font () { return gulp.src(['./icons/*.svg']) .pipe(iconfontCss({ fontName: fontName, path: './styles/_fonts/...
module.exports = function( config ) { config.set( { files: [ "node_modules/jquery/dist/jquery.js", "node_modules/p-loading/dist/js/p-loading.js", "dist/js/pl-spintkit.js", "test/setup.js", "test/spec/*" ], frameworks: [ "qunit" ], autoWatch: true } ); };
import { setData } from '@progress/kendo-angular-intl'; setData({ name: "pt-AO", likelySubtags: { pt: "pt-Latn-BR" }, identity: { language: "pt", territory: "AO" }, territory: "AO", numbers: { symbols: { decimal: ",", group: " ", ...
import Ember from 'ember'; const { Route, RSVP: { Promise } } = Ember; export default Route.extend({ model() { return { promise: Promise.resolve(42), child: Promise.resolve(Ember.Object.create({ name: 'Kelly Selden' })) }; } });
// get autoprefixer module for the postcss const autoprefixer = require ( 'autoprefixer' ); const config = { // get the main js file entry: __dirname + '/public/js/main.js', // create the webpack.js file output: { path: __dirname + '/public/js/', filename: 'webpack.js' }, // watchmode watch: true, // module...
/** * NavBar controller */ window.throwaApp.controller('NavBarCtrl', function ($scope) { $scope.isCollapsed = true })
import React, {Component, PropTypes} from 'react'; import { ContentHeader } from 'components'; import { Grid, Col, Row } from 'react-bootstrap'; /* import { blogGroupBox } from '../../db/jsonData/blogGroup'; */ import { Link } from 'react-router'; import { objToArr } from '../../utils/blogTools'; import * as blogAction...
'use strict' exports.up = (knex) => knex.schema.createTable('users', (table) => { table.increments('id') table.string('name') table.string('email') table.string('hashed_password') table.timestamps() }) exports.down = (knex) => knex.schema.dropTable('users')
angular.module('starter', ['ionic']) // Global constants .constant('mapPreferenceKey', 'MAP_PREFERENCE') .constant('userPreferenceKey', 'USER_PREFERENCE') .constant('pokemonListPreferenceKey', 'POKEMON_LIST_SIZE_PREFERENCE') .constant('baseUrlGetPokemons', 'http://pokeapi.co/api/v2/pokemon?limit=') .constant('position...
function getQueryStringVars(){ var vars = [], hash; var q = document.URL.split('?')[1]; if(q != undefined){ q = q.split('&'); for(var i = 0; i < q.length; i++){ hash = q[i].split('='); vars.push(hash[1]); vars[hash[0]] = hash[1]; } } return vars; } // Test functions // E...
app.directive('mapView', function () { return{ restrict: 'E', templateUrl: 'app/components/map/mapView.html' } });
var mongo = require('mongodb').MongoClient; var url = "mongodb://localhost:27017/learnyoumongo"; var objects = {firstName:process.argv[2],lastName:process.argv[3]}; mongo.connect(url, function(err, db) { if(err) throw err; db.collection('docs').insert(objects,function(err,data){ if(err)...
let prune = { populate: function(tabId, count) { if(trees[tabId]) { if(!count) count = 5; if(count > 0 && count === Math.floor(count)) { tree = trees[`${tabId}`]; for(var i = 0; i < count; i++) { tree.getActiveNode().appendChild(new Node(tree.getActiveNode(), "dummy url")); } return this.a...