code
stringlengths
2
1.05M
Iddocs = new Meteor.Collection('iddocs'); Iddocs.helpers({ update(modifier) { modifier.updatedAt = new Date(); return Meteor.call('updateDoc', this._id, modifier); }, approve() { return this.update({ status: 'APPROVED' }); }, reject(reason) { return this.update({ status: 'REJECTED', statusRe...
"use strict"; const { test } = require("tap"); const { readLastLine, run } = require("./helpers"); test("ntl forward trailing options", t => { const cwd = t.testdir({ "package.json": JSON.stringify({ scripts: { test: "node test.js" } }), "test.js": "console.log(process.argv.slice(2).join(''))" }); ...
/** * The MIT License (MIT) * * Copyright (c) 2013 Scott Will * * Permission is hereby granted, free of charge, to any person obtaining a copy of * this software and associated documentation files (the "Software"), to deal in * the Software without restriction, including without limitation the rights to * use, copy, ...
module.exports = { parse: function(inputString, inputBlocks, inputOperators) { //set default delimiter set var defaultBlocks = { warm: { "{": "}", "(": ")", "[": "]" }, cold: { "'": "'", ...
/** * model/users.js * * Provides users data access object. */ var bcrypt = require('bcrypt-nodejs'); function UsersDAO(connection) { // Adds new user to the database. this.addUser = function(data, callback) { // Generate password hash. var salt = bcrypt.genSaltSync(); var passwordHash = bcrypt....
'use strict'; System.register('sijad/pages/addPagesPane', ['flarum/extend', 'flarum/components/AdminNav', 'flarum/components/AdminLinkButton', 'sijad/pages/components/PagesPage'], function (_export, _context) { var extend, AdminNav, AdminLinkButton, PagesPage; _export('default', function () { app.routes.pages...
/** * Created by WareBare on 4/13/2017. * * @author WareBare (Daniel Kamp) * @license MIT * @website https://github.com/WareBare * */ module.exports = { contentType: `Step 1`, title: `Mastery Wizard`, wndId: `masteryWizard`, Settings: { height: `1000px`, width: `750px`, ...
define([ 'jquery', 'underscore', 'backbone', 'mustache', 'initView', 'text!templates/categories/categoriesItem.mustache', 'text!templates/categories/categoriesForm.mustache', 'categoryModel', 'categoryCollection', 'storage' ], function( $, _, Backbone, Mustache, InitView, CategoriesIte...
exports.html = require('./html'); exports.javascript = require('./javascript'); exports.sass = require('./sass'); exports.misc = require('./misc');
/*jshint esversion: 6 */ import home from './components/home'; import excelTool from './components/excelTool'; const routes = [ { path: '/home', component: home }, { path: '/excelTool', component: excelTool } ]; export default routes;
app.controller('compCtrl', ['flickr'], function(context, flickr) { context.model.photos = []; context.model.refreshPhotos = function() { flickr.getPhotos(function() { context.model.photos = flickr.photos; }); } context.model.refreshPhotos(); });
let fs = require("fs"), path = require("path"), debug = require("debug"), debugBuild = debug("graffito-build"), debugData = debug("graffito-data"), site = require("./plugins/site"), conrefifier = require("./plugins/conrefifier"), datafiles = require("./plugins/datafiles"), renderer = re...
'use strict'; angular.module('plankApp', [ 'ngCookies', 'ngResource', 'ngSanitize', 'ui.router', 'ui.bootstrap' ]) .config(function ($stateProvider, $urlRouterProvider, $locationProvider, $httpProvider) { $urlRouterProvider.otherwise('/'); $locationProvider.html5Mode(true); // true mean drop the # ...
var transform = (function() { var properties = [ 'oTransform', // Opera 11.5 'msTransform', // IE 9 'mozTransform', 'webkitTransform', 'transform' ]; var style = document.createElement('div').style; for (var i = 0; i < properties.length; i++) { /* istanbul ignore else */ if (properti...
var vm = require("vm"); var path = require('path'); var _ = require('underscore'); var iv = require(path.normalize(__dirname + '/../helpers/inputsValidation')); var response = { success: function(data){ process...
/* jshint browser:true */ /* global angular */ angular.module('griddy', ['griddy.models', 'griddy.services', 'griddy.controllers', 'griddy.directives']); //, 'templates-main' angular.module('griddy.models', []); angular.module('griddy.services', []); angular.module('griddy.controllers', []); angular.module('griddy.dir...
'use strict'; describe('Directive: indexEntry', function () { // load the directive's module beforeEach(module('godocApp')); var element, scope; beforeEach(inject(function ($rootScope) { scope = $rootScope.$new(); })); it('should make hidden element visible', inject(function ($compile) { el...
/* YOLOFly */ var posX = 320; var posY = 448; var deg = 0; var lastX = 0; var cursorX = 320; var fireballs = []; var ships = []; var expl = []; var stars = []; var ePosX = 320; var chargeLevel = 0; var HP = 100; var charging = false; var points = 0; var shield = 100; var shotNumber = 1; var difficulty = 1; var shot...
var helper = require('../spec_helper'), request = require('request'); describe('Cloudscraper', function() { var sandbox, url = 'http://example-site.dev/path/', requestedPage = helper.getFixture('requested_page.html'), headers = {'User-Agent': 'Chrome'}, /...
var events = require('events'); var util = require('util'); var _ = require('lodash'); var extend = require('node.extend'); var serialport = require('serialport'); var commands = require('./commands'); var demos = require('./demos'); var misc = require('./misc'); var sensors = require('./sensors'); var songs = requir...
#!/usr/bin/env node --harmony var REPL = require('co-repl'); // var mongoose = require('mongoose'); var fs = require('fs'); var path = require('path') // require('mongoose-q')(mongoose) function CoYongoose(mongoose) { this.mongoose = mongoose; require('mongoose-q')(mongoose); this.connect = function(conn_str) {...
$dh.Require("util/event"); DHDRAG = new DHEvent(); $dh.extend(DHDRAG, { mouseOffset: null, activeObj: null, mask: null, dragStarted: false, init: function() { $dh.addEv(document, "mousemove", DHDRAG.mouseMove); $dh.addEv(document, "mouseup", DHDRAG.mouseUp); $dh.addEv(document, ...
'use strict' const Transport = require('libp2p-tcp') const Muxer = require('libp2p-mplex') const { NOISE: Crypto } = require('libp2p-noise') module.exports = { modules: { transport: [Transport], streamMuxer: [Muxer], connEncryption: [Crypto] }, config: { relay: { enabled: true, hop: ...
import { SWITCH_SECTION, TOGGLE_NAV, SET_ACTIVE_SECTION, EXTEND_PORTFOLIO_SECTION, TOGGLE_SKILLS_ROW, LOAD_PORTOFOLIO_IMAGES, UNSET_SCROLL_TRIGGERED } from './types'; export function switchSectionTo(newSection) { return { type: SWITCH_SECTION, payload: newSection } } export function setActiveSection(newS...
'use strict'; const frontmatter = require('gulp-front-matter'); const path = require('path'); const processTree = require('../gulp-plugins/process-toc'); const fs = require('fs-extra'); module.exports = (gulp, opts) => { gulp.task('toc', toc); function toc() { return gulp.src('**/*.md', { follow: true...
var express = require('express'); var router = express.Router(); var wechatConfig = require('./wechatConfig'); var wechatSnsHelper = require('./wechatSnsHelper'); router.get('/', function (req, res, next) { console.log(req.cookies); var openid = req.cookies.openid; if(openid){ res.render('user', {...
"use strict"; function setup( postal, config, fount ) { config = config || {}; const log = postal.channel( config.logChannel || "log" ); const resolver = postal.configuration.resolver.compare.bind( postal.configuration.resolver ); const Logger = require( "./Logger.js" )( log, resolver ); const adapters = require(...
(function () { angular .module('directivas') .directive('ejercicioTarjeta2', function (){ const ddo = { }; return ddo; }); }());
module.exports = { SAHtml: require('./lib/sahtml').SAHtml };
Package.describe({ name: 'eahefnawy:accounts-coinbase', summary: 'A Meteor loginWithCoinbase Functionality.', version: '0.0.1-plugins.0', git: 'https://github.com/eahefnawy/accounts-coinbase.git', }); Package.onUse(function(api) { api.use('oauth2@1.1.3', ['client', 'server']); api.use('oauth@1.1.4', ['clie...
export const FIREBASE_URL = 'https://glowing-torch-886.firebaseio.com'; export const FIREBASE_BACKLOGS_URL = FIREBASE_URL + '/backlogs';
/** * @file Utils */ /** * @module Utils */ import {menu} from '../main/index'; /** * Get menu item by label. * @param label {string} The label of the menu item to search for. * @returns {Electron.MenuItem} - The full menu item. Can change things like checked etc. */ export function getMenuItem (label) { for...
define(function() { function ColorTable(params) { this.colors = []; this.errorColor = params.errorColor; } ColorTable.prototype.hasColor = function(r, g, b, a) { return this.lookUpColor(r, g, b, a) >= 0; }; ColorTable.prototype.lookUpColor = function(r, g, b, a) { for(var i = 0; i < this.colors.length; i++...
var M = require('../message'); /** * 指定したすべての属性が必須である * @method exports * @param {String} requiredAttrs * @return {Function} hasAllAttributes */ module.exports = function (requiredAttrs) { var names = requiredAttrs.split(','); return function hasAllAttributes (node, e) { var attrs = node.attributes...
module.exports = { GET : [{ path : '/{{api}}', action : 'GET', // policy : 'authenticated' },{ path : '/{{api}}/:id', action : 'findOne', // policy : 'authenticated' }], POST : [{ path : '/{{api}}', action : 'POST', // pol...
#!/usr/bin/env node require('babel/register'); require('./src/index');
// flow-typed signature: 5a7cf8685547d9008aad76a276f00233 // flow-typed version: <<STUB>>/chai_v^3.4.1/flow_v0.45.0 /** * This is an autogenerated libdef stub for: * * 'chai' * * Fill this stub out by replacing all the `any` types. * * Once filled out, we encourage you to share your work with the * community...
(function () { 'use strict'; angular .module('parcels.admin') .controller('ParcelsController', ParcelsController); ParcelsController.$inject = ['$scope', '$state', '$window', 'parcelResolve', 'Authentication']; function ParcelsController($scope, $state, $window, parcel, Authentication) { var vm ...
import '@babel/polyfill' import './app'
import { setData } from '@progress/kendo-angular-intl'; setData({ name: "ro-MD", likelySubtags: { ro: "ro-Latn-RO" }, identity: { language: "ro", territory: "MD" }, territory: "MD", calendar: { patterns: { d: "dd.MM.y", D: "EEEE, d MMMM...
/** * Env.js * * Released under LGPL License. * Copyright (c) 1999-2015 Ephox Corp. All rights reserved * * License: http://www.tinymce.com/license * Contributing: http://www.tinymce.com/contributing */ /** * This class contains various environment constants like browser versions etc. * Normally ...
import React, { Component } from 'react'; import { Form, Text, Select } from 'react-form'; import NotificationSystem from 'react-notification-system'; // eslint-disable-next-line const remote = eval("require('electron').remote"); // eslint-disable-next-line const {ipcRenderer} = eval("require('electron')"); let confi...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports["default"] = function (selector, context) { // get NodeList, default to document if no context specified var results = (context || document).querySelectorAll(selector); // cast into Array return Array.prototype.s...
var express = require('express'); var router = express.Router(); router.get('/', function(req, res, next) { res.render('index', { title: 'Clark Hinchcliff' }); }); module.exports = router;
import angular from 'angular'; /** * Directive that handles the model arrays */ export default function(sel, sfPath, schemaForm) { return { scope: true, controller: ['$scope', function SFArrayController($scope) { this.key = ($scope.form && $scope.form.key) ? $scope.form.key.splice(0, -2) : []; }]...
define([ "Backbone", "./collections/TasksCollection", "./views/MainView" ], function( Backbone, TasksCollection, MainView ) { return { run: function(viewManager) { var tasksCollection = new TasksCollection(); tasksCollection.fetch({ success: fu...
'use strict'; var test = require('tape'); var rewire = require('rewire'); var api = require('./PathStore.api'); var PathStore = rewire('../../../src/core/PathStore'); var PathUtilsStub = require('../path/Path.stub'); var helpers = require('./PathStore.helpers'); PathStore.__set__('PathUtils', PathUtilsStub); helpers....
module.exports = require('./lib/tls-sip-probe');
/** @module leancloud-realtime */ import d from 'debug'; import uuid from 'uuid/v4'; import IMClient from './im-client'; import { RECONNECT, RECONNECT_ERROR } from './events/core'; import { Conversation } from './conversations'; import { MessageQueryDirection } from './conversations/conversation-base'; import Message, ...
import { Router } from 'express' import path from 'path' import React from 'react' import ReactDOMServer from 'react-dom/server' import createApp from 'create-app/lib/server' import util from '../util' const { getFlatList } = util const getModule = module => module.default || module const commonjsLoader = (loadModule,...
import env from '../../src/util/env'; import gtTimer from '../../src/graviton/timer'; describe('timer', () => { let window; beforeEach(() => { window = jasmine.createSpyObj('window', [ 'requestAnimationFrame', 'cancelAnimationFrame', 'setInterval', 'clear...
import React from 'react'; import ReactDOM from'react-dom'; import {Paper} from 'material-ui'; import ReactQuill from 'react-quill'; import PostSkeleton from './PostSkeleton'; const style= {margin: '1em', height: '100px', overflow: 'scroll'}; class TextEdit extends React.Component { constructor(props) { super(p...
"use strict"; (function(exports){ function setAttributes(e, map){ for(var key in map){ e.setAttribute(key, map[key]); } } function setStyles(e, map){ for(var key in map){ e.style[key] = map[key]; } } function getOpt(opts, key, defaultValue){ if( opts && key in opts ){ return opts[key]; } else { return ...
version https://git-lfs.github.com/spec/v1 oid sha256:4c2353b8e357b6697089c454867613efd7e0b8a0b510d97497ca256ee94086ac size 113530
const { convertSlashesInPath } = require("./projectHelpers"); module.exports = function (source, map) { this.cacheable(); const { modules } = this.query; const imports = modules.map(convertSlashesInPath) .map(m => `require("${m}");`).join("\n"); const augmentedSource = ` const isAndroid...
var entity = function() { this.width = 0; this.height = 0; this.scale = 1; this.x = 0; this.y = 0; this.image = null; this.imageWidth = 0; this.imageHeight = 0; }; entity.prototype = entity; entity.prototype.init = function(width, height, scale) { this.width = width; this.height = height; this.scale = s...
var React = require('react'); var flickrLiveStore = require('../stores/flickrLiveStore'); var flickrSearchStore = require('../stores/flickrSearchStore'); var flickrSaveStore = require('../stores/flickrSaveStore'); var Flickr = require('./Flickr'); var FlickrControl = require('./FlickrControl'); var flickrActions = re...
/** * videojs-contrib-media-sources * @version 3.1.0 * @copyright 2016 Brightcove, Inc. * @license Apache-2.0 */ (function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=windo...
const webpack = require('webpack'); const path = require('path'); const { merge } = require('webpack-merge'); const HTMLWebpackPlugin = require('html-webpack-plugin'); const rootPath = (exports.rootPath = path.join(__dirname, '..')); const srcPath = (exports.srcPath = path.join(rootPath, 'src')); const distPath = (exp...
/* jshint node: true */ 'use strict'; module.exports = { normalizeEntityName: function() {} };
/*global browser, by */ 'use strict'; describe('E2E: Example', function() { beforeEach(function() { browser.get('/'); browser.waitForAngular(); }); it('should route correctly', function() { expect(browser.getLocationAbsUrl()).toMatch('/'); }); it('should show the number defined...
const webpack = require('webpack'); const sassLintPlugin = require('sasslint-webpack-plugin'); const I18nPlugin = require("i18n-webpack-plugin"); const isDev = process.env.NODE_ENV !== 'production'; const entry = isDev ? [ 'webpack-hot-middleware/client?reload=true&timeout=2000', 'react-hot-loader/patch', './cli...
export const facebook = {"viewBox":"0 0 16 16","children":[{"name":"path","attribs":{"fill":"#000000","d":"M9.5 3h2.5v-3h-2.5c-1.93 0-3.5 1.57-3.5 3.5v1.5h-2v3h2v8h3v-8h2.5l0.5-3h-3v-1.5c0-0.271 0.229-0.5 0.5-0.5z"}}]};
var _require = require('zoroaster/assert'), deepEqual = _require.deepEqual, throws = _require.throws; var context = require('../context/WroteContext'); var readJSON = require('../../src/read-json'); var readJSONTestSuite = { context, 'should read a JSON file'(_ref) { return new Promise(functio...
import gulp from 'gulp' import gutil from 'gulp-util' import del from 'del' import WebpackDevServer from "webpack-dev-server" import webpack from "webpack" const path = require('path'); const DEV_PORT = 4000, PROD_PORT = 80 const server = (webpackPath, cb)=> { let webpackConfig = require(webpackPath) let myConfig...
/** * @fileoverview Rule to flag use of arguments.callee and arguments.caller. * @author Nicholas C. Zakas */ "use strict"; //------------------------------------------------------------------------------ // Rule Definition //------------------------------------------------------------------------------ module.ex...
var React = require('react'); var App = React.createClass({ componentDidMount: function() { DesiredTravelStore.addChangeListener(this._onChange); }, componentWillUnmount: function() { DesiredTravelStore.removeChangeListener(this._onChange); }, /** * @return {object} */ render: function() {...
var http = require('http'); var parseString = require('xml2js').parseString; var countryIds = require(require('path').resolve(__dirname, 'lib', 'countries.json')); module.exports = function(localization, count, callback) { var url = "http://trends.google.com/trends/hottrends/atom/feed?pn=" + countryIds[localization...
//namespace if (!this.hook) this.hook = {}; (function () { function D3Interface(chart) { adapter.Interface.call(this); this.chart = chart; this.dataSource; } D3Interface.prototype = new adapter.Interface(); D3Interface.prototype.constructor = D3Interface; var p = D3In...
angular.module('tweetsToSoftware') .directive('topMenu', function($document) { 'use strict'; return { restrict: 'E', templateUrl: 'menu.html', scope: { menu: '=', itemActivateCallback: '=', itemHoverCallback: '=', itemLeaveCallback: '=', rootItemClick...
const bodyParser = require("body-parser"); const compression = require("compression"); const cors = require("cors"); const express = require("express"); const Joi = require("@hapi/joi"); const { HttpError, ObjectNotExistError } = require("./libs/errors"); const expressMongoDb = require("./middlewares/express_mongo_db")...
import { waitForVisibilityOf, protractorUniTestkitFactoryCreator, } from 'wix-ui-test-utils/protractor'; import { eyesItInstance } from '../../../test/utils/eyes-it'; import { createTestStoryUrl } from '../../../test/utils/storybook-helpers'; import richTextInputAreaPrivateDriverFactory from '../RichTextInputArea....
'use strict' const allowedOptions = [ '--config', '--help', '--os', '--osVersion', '--browser', '--browserVersion', '--device', '--orientation', '--size', '--timeout', '--project', '--test', '--build', '--local', '--localIdentifier', '--screenshots', '--video', '--framework' ] let path = require('path'), utils ...
'use strict'; var path = require('path'); var browserify = require('browserify'), eventStream = require('event-stream'), glob = require('glob'), vinylBuffer = require('vinyl-buffer'), vinylSource = require('vinyl-source-stream'), watchify = require('watchify'), eslintify = require('eslintify')...
var PostService = require('./post.service'); var ZiviService = require('./zivi.service'); var ConfigService = require('./config.service'); var STATES = require('../models/states'); const apiKey = ConfigService.getTelegramApiKey(); var TelegramService = require('./telegram-dummy.service'); if (!apiKey || process.env.zim...
"use strict"; var path = require('path') var grunt = require("grunt"); grunt.file.defaultEncoding = 'utf8'; function compileAsmToJs() { var pattern = this.data.pattern; var files = grunt.file.expand(pattern); var tmpl = grunt.file.read("src/programs/program.js.tmpl"); files.forEach(function(filepath) { // skip...
/* Copyright (c) 2003-2011, CKSource - Frederico Knabben. All rights reserved. For licensing, see LICENSE.html or http://ckeditor.com/license */ (function() { CKEDITOR.dialog.add( 'pastetext', function( editor ) { return { title : editor.lang.pasteText.title, minWidth : CKEDITOR.env.ie &&...
import React, { Component } from 'react'; import { Link, Match } from 'react-router'; import $ from 'jquery'; import TopActionComponent from './TopActionComponent'; class SuggestedEmployees extends Component{ constructor(context, props){ super(context, props); } componentDidMount() { } render(){ const s...
'use strict'; angular.module('keymediaApp', ['angularFileUpload']) .config(function ($routeProvider) { $routeProvider .when('/:album', { templateUrl: '/wp-content/plugins/keymedia/web/app/views/main.html', controller: 'MainCtrl' }) .otherwise({ redirectTo: '/' }); ...
import nodeResolve from 'rollup-plugin-node-resolve' import filesize from 'rollup-plugin-filesize' import commonjs from 'rollup-plugin-commonjs' import pkg from './package.json' const external = [...Object.keys(pkg.dependencies), ...Object.keys(pkg.peerDependencies)]; const plugins = [ nodeResolve({ jsnext: tru...
module.exports = /******/ (function(modules) { // webpackBootstrap /******/ // The module cache /******/ var installedModules = {}; /******/ // The require function /******/ function __webpack_require__(moduleId) { /******/ // Check if module is in cache /******/ if(installedModules[moduleId]) /******/ ret...
ScalaJS.impls.scala_Function2$mcJDI$sp$class__$init$__Lscala_Function2$mcJDI$sp__V = (function($$this) { /*<skip>*/ }); //@ sourceMappingURL=Function2$mcJDI$sp$class.js.map
module.exports = { 'rules': { 'strict': ['error', 'global'], }, }
/** * Created by Brennon Bortz on 8/6/14. */ 'use strict'; // Server var server = require('../../../server'); var app; // Config module var config = require('../../../config/config'); // Testing tools var request = require('supertest'); var should = require('chai').should(); describe('Core Controller Tests', fun...
"use strict"; class Scene { constructor(canvasId, presentBtnId) { /* const */ this.DISTANCE = 40.0; this.webglCanvas = document.getElementById(canvasId); this.presentBtn = document.getElementById(presentBtnId); this.vrDisplay = null; this.gl = this.webglCanvas.getContext("w...
(function(d,c){c.Tablecols=Class.extend({dropdown:!1,table:!1,headers:!1,columns:!1,keystorage:"",tml:'<li class="checkbox"><label><input type="checkbox" value="%%index%%" %%checked%% />%%title%%</label></li>',init:function(a,b){this.dropdown=d(a);this.table=this.dropdown.parent().find("table:first");this.headers=this....
(function(){ // Manager (static) ppc.manager = cloz(base, { init: function(){ try { ppc.logger.get('add', 'PPCの初期化を開始しました', 0, 'start initialization'); // 最大同時接続数を設定 ppc.user.set('connections', ppc.parser.created.get('val', 'connections')); // 測定日時を設定 var now = (new Date()).getTime() + (new Date())...
modulex.add("event-custom", ["modulex-event-base","modulex-util"], function(require, exports, module) { var modulexEventBase = require("modulex-event-base"); var modulexUtil = require("modulex-util"); /* combined modules: event-custom event-custom/target event-custom/observable event-custom/observer event-custom/object...
"use strict"; const mods = [ "shellfish/low", "shellfish/mid", "shellfish/high", "shell/ui", "shell/files" ]; require(mods, function (low, mid, high, ui, files) { function openPage() { var page = high.element(mid.Page); page .onClosed(page.discard) .onSwipeB...
var config = require('../config').proc, gulp = require('gulp'); gulp.task('watch', ['build'], function () { gulp.watch('src/images/**/*', ['images']); gulp.watch(['src/css/**/*.css', 'src/**/*.pug'], ['pug']); });
//jshint strict: false module.exports = function(config) { config.set({ basePath: './app', files: [ 'bower_components/angular/angular.js', 'bower_components/angular-route/angular-route.js', 'bower_components/angular-mocks/angular-mocks.js', 'bower_components/angular-local-storage/dis...
(function () { 'use strict'; var get = Ember.get, set = Ember.set, getConverter = Frzn.getConverter, relationships = Frzn.relationships; var DeferredMixin = Ember.Mixin.create({ /** Add handlers to be called when the Deferred object is resolved or rejected. @method then @...
var util = require('util'), bleno = require('bleno'); var BlenoCharacteristic = bleno.Characteristic; var BlenoDescriptor = bleno.Descriptor; function ManufacturerNameCharacteristic(manufacturer) { ManufacturerNameCharacteristic.super_.call(this, { uuid: '2a29', properties: ['read'], value: new Buff...
const Route = require('lib/router/route') module.exports = new Route({ method: 'del', path: '/', handler: async function (ctx) { const token = ctx.state.token if (!token) { return ctx.throw(401) } if (ctx.state.authMethod !== 'Bearer') { return ctx.throw(403) } token.isDele...
(function() { 'use strict'; var root = this; var Px = (function () { function Px(pxString) { this._ctor(pxString); } function _arrayOfZeroes(l) { var a = []; while (l--) { a[l] = 0; } return a; } ...
// +@typename cracked_com_blog // +@include http://www.cracked.com/blog/* // +@history (0.0.1) Initial Release // +@history (0.0.9) Removed bottom banner on pages // +@history (0.0.12) Updated addPageContent to use $target AntiPagination.add({ name: 'cracked_com_blog', tes...
import curry from '../Func/curry' import fix from '../Func/fix' // + find :: (a -> Boolean) -> [a] -> a export default fix((find) => curry((fn, [x, ...xs]) => x ? fn(x) ? x : find(fn, xs) : undefined ))
/** * Object.assign的polyfill * 解决webview等不支持ES6的浏览器兼容性 */ 'use strict'; (function() { if (!Object.assign) { Object.defineProperty(Object, 'assign', { enumerable: false, configurable: true, writable: true, value: function(target) { if (target === undefined || target === null) {...
/** * * * * * * * * * * * * */ /* Depandances PROVIDE : * ===================== */ stage.provide("deferred"); /* * Depandances REQUIRE : * ===================== */ stage.register("deferred",function(){ var deferred = function(){ this.notificationsCenter = stage.createEventsManager(); t...
/* eslint no-use-before-define:0 */ 'use strict'; var RSVP = require('rsvp'); var Promise = RSVP.Promise; module.exports = PromiseExt; // Utility functions on the native CTOR need some massaging module.exports.hash = function () { return this.resolve(RSVP.hash.apply(null, arguments)); }; module.exports.denodei...