code stringlengths 2 1.05M |
|---|
/*
*
*/
(function ()
{
//@ 全局对象,同时支持页面主线程,WebWorker线程,和Node.js
var i_InNodeJs = ("undefined" == typeof self);
var l_Glb = i_InNodeJs ? global : self;
//@ 如果本文件已经包含过
if (l_Glb.nWse && l_Glb.nWse.nUi && l_Glb.nWse.nUi.nCmnWgts && l_Glb.nWse.nUi.nCmnWgts.t$$$)
{
//@ 避免重复执行相同的初始化代码
return;
}
//@ 包含
l_Glb... |
'use strict'
const _ = require('lodash')
class SelectBase {
constructor(parentSelector) {
const fieldsToSelect = parentSelector.select
const dataSource = parentSelector.dataSource
this.select = applySelectKeysToQuery(null, fieldsToSelect, dataSource)
this.select = `SELECT ${this.s... |
import _ from "underscore";
import {module, inject} from "angular-mocks";
import TableauPile from "../../../app/klondike/piles/tableauPile.js";
import RemainderPile from "../../../app/klondike/piles/remainderPile.js";
describe("A tableau pile", function () {
"use strict";
beforeEach(module("klondike.scoring"));
... |
/**************************************************************
* Copyright (c) Stéphane Bégaudeau
*
* This source code is licensed under the MIT license found in
* the LICENSE file in the root directory of this source tree.
***************************************************************/
import React from 'react'... |
/**
* @fileoverview
*
* Contains implementation of logic required by the Tutorial 5.
*
* @author Juan Docal
* @date 21-02-2013 23:35
*/
(function () {
'use strict';
// Imports
var Log;
// Consts
var APP_ID = NaN,
API_KEY = '';
// Variables
var localRenderEnabled = false,
previewSinkI... |
// All code points in the Hanunoo block as per Unicode v7.0.0:
[
0x1720,
0x1721,
0x1722,
0x1723,
0x1724,
0x1725,
0x1726,
0x1727,
0x1728,
0x1729,
0x172A,
0x172B,
0x172C,
0x172D,
0x172E,
0x172F,
0x1730,
0x1731,
0x1732,
0x1733,
0x1734,
0x1735,
0x1736,
0x1737,
0x1738,
0x1739,
0x173A,
0x173B,
0x... |
#!/usr/bin/env node
var express = require('express');
var app = express();
var cons = require('consolidate');
var env = process.env;
var config = {
tasks: {url: env.TASKS_URL || ""},
jenkins: {url: env.JENKINS_URL || ""},
events: {url: env.EVENTS_URL || ""},
serverStatus: {url: env.SERVER_STATUS_URL ... |
//Global variables
var width_dip = parseFloat(d3.select("#divHemi_dip").node().parentElement.clientWidth);
var height_dip = width_dip * 0.5208333333333333;
var radius_dip = width_dip / 2 - 16; //Math.min(width, height)/2;
var svg_dip = d3.select("#divHemi_dip")
.append("svg")
.attr("width", width_dip)
.at... |
/*
* Copyright (c) 2020, Hugo Freire <hugo@exec.sh>.
*
* This source code is licensed under the license found in the
* LICENSE.md file in the root directory of this source tree.
*/
const { Route } = require('serverful')
const Boom = require('@hapi/boom')
const Logger = require('modern-logger')
const Database =... |
import Promise from 'bluebird'
var DDS_MAGIC = 0x20534444;
var DDSD_CAPS = 0x1,
DDSD_HEIGHT = 0x2,
DDSD_WIDTH = 0x4,
DDSD_PITCH = 0x8,
DDSD_PIXELFORMAT = 0x1000,
DDSD_MIPMAPCOUNT = 0x20000,
DDSD_LINEARSIZE = 0x80000,
DDSD_DEPTH = 0x800000;
var DDSCAPS_COMPLEX = 0x8,
DDSCAPS_MIPMAP = 0x400000,
DDSCA... |
import constants from './constants'
export default function(title, description, imageLink) {
const imageUrl =
typeof imageLink === 'string' ? imageLink : constants.socialMediaImageUrl
return [
{
hid: 'description',
name: 'description',
content: description
},
// Facebook
{
... |
const config = {
github: {
client_id: '',
client_secret: '',
redirect_uri: '',
auth_url: ''
}
}
export default config
|
'use strict';
angular.module('myApp.view3', ['ui.router'])
.config(['$stateProvider', function($stateProvider) {
$stateProvider.state({
name: 'step3',
url: '/step3',
templateUrl: 'views/step3.html',
controller: 'View3Ctrl'
});
}])
.controller('View3Ctrl', [ '$scope', function... |
/**
* @fileoverview Tests for curly rule.
* @author Nicholas C. Zakas
*/
"use strict";
//------------------------------------------------------------------------------
// Requirements
//------------------------------------------------------------------------------
const rule = require("../../../lib/rules/curly"),... |
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
* @fileoverview functions used on the server databases list page
* @name Server Databases
*
* @requires jQuery
* @requires jQueryUI
* @required js/functions.js
*/
/* global MicroHistory */ // js/microhistory.js
/**
* Unbind all event handler... |
angular.module('umbraco.mocks.resources')
.factory('tagsResource', function () {
return {
getTags: function (group) {
var g = [
{"id":1, "label":"Jordbærkage"},
{"id":2, "label":"Banankage"},
{"id":3, "label":"Kiwikage"},
{"id":4, "label":"Rabarbertærte"}
];
return g;
}
};
}); |
// 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... |
import {connect} from 'react-redux';
import {bindActionCreators} from 'redux';
import SettingsView from './SettingsView';
import {M,K} from '../../utils/constants'
import * as SettingsStateActions from './SettingsState';
import * as ConfigurationStateActions from '../static/StaticState'
export default connect(
state... |
let Web3 = require("web3");
let web3 = new Web3(new Web3.providers.HttpProvider('http://localhost:8545'));
let web3Handler = require("./Web3Handler.js");
let contract;
const domainDNS = "https://xcontract.herokuapp.com";
let clipboard = require("clipboard-polyfill");
const noInjectedProviderFound = "no injected provide... |
/*
* heatmap.js OpenLayers Heatmap Class
*
* Copyright (c) 2011, Patrick Wied (http://www.patrick-wied.at)
* Dual-licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
* and the Beerware (http://en.wikipedia.org/wiki/Beerware) license.
*
* Modified on Jun,06 2011 by Antonio Santiag... |
require(['d3', 'reactivis'], function (d3, reactivis) {
var div = document.getElementById('scatterPlotContainer'),
scatterPlot = reactivis.ScatterPlot();
// respond to browser window resizes
reactivis(scatterPlot).listenForResize();
scatterPlot.set('div', div);
scatterPlot.set({
getX: function (d... |
/*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it wi... |
// start at beginning, go to the item just before "ace"
const upperRange = IDBKeyRange.upperBound("ace", true);
|
'use strict'
var child_process = require('child_process')
// Required for type checking.
var Log = require('./Log')
/**
* The executable cache.
* @type {Object.<!Executable>}
*/
var registry = Object.create(null)
/**
* A memoized executable command. The first time the command is run, the results are stored.
*... |
import React from 'react'
import { Navbar, Header } from '.'
import '../static/stylesheets/globals.scss'
import contentStyle from '../static/stylesheets/content.scss'
export const NotFoundPage = (props) => {
return (
<div>
<Navbar />
<div className={contentStyle.contentWrapper}>
<Header heade... |
"undefined"==typeof EDP&&(EDP={}),"undefined"==typeof EDP.L10n&&(EDP.L10n={}),EDP.L10n.Locale="fr_FR",EDP.L10n.Language="fr",EDP.L10n.DecimalSeparator=",",EDP.L10n.ThousandSeparator=" ",EDP.L10n.Regex.RxFloatValidation=/^[0-9]+(,[0-9]+)?$/,EDP.L10n.Functions.TryParseDate=function(e){var n=/([0-9]{1,2})\/([0-9]{1,2})\/(... |
var tape = require('tape')
var eos = require('./index')
var fs = require('fs')
var cp = require('child_process')
var net = require('net')
var http = require('http')
var stream = require('stream')
tape('fs writestream destory', function (t) {
var ws = fs.createWriteStream('/dev/null');
eos(ws, function(err) {
t.o... |
/**
* Created by sdikramanjian on 4/7/2017.
*/
(function(ng){
'use strict';
function PlayerService(){
return {
getNewPlayer:_getNewPlayer,
getWinner: _getWinner
};
/**
* @name getWinner
* @description returns the winner if any , else return... |
const users = [
{
name: 'brynn',
avatar: 'https://s3.amazonaws.com/uifaces/faces/twitter/brynn/128.jpg'
},
{
name: 'brann',
avatar: 'https://s3.amazonaws.com/uifaces/faces/twitter/brynn/128.jpg'
},
{
name: 'brunn',
avatar: 'https://s3.amazonaws.com/uifaces/faces/twitter/brynn/128.jpg'
},... |
var gpio = require('./protocols/gpio');
var i2c = require('./protocols/i2c');
var spi = require('./protocols/spi');
var close = require('./close');
var file = 'getters_and_setters.js';
var componentUtils = require('./component_utils');
function initializeComponent() {
var fvr = this;
var protocol = _fvr[this._index... |
import React from 'react';
import PropTypes from 'prop-types';
import Paper from '@material-ui/core/Paper';
import { withStyles } from '@material-ui/core/styles';
import Grid from '@material-ui/core/Grid';
const styles = {
root: {
width: 400,
},
paper: {
padding: 16,
textAlign: 'center',
},
};
fun... |
import React from 'react';
import docTemplate from './HTML.js';
import { renderToString } from 'react-dom/server';
import { match, RouterContext } from 'react-router';
import { Provider } from 'react-redux';
import Helmet from 'react-helmet';
import routes from './routes.js';
import getStore from './store.js';
import {... |
export { default } from 'ember-kinetic-form/components/kinetic-form/loading'; |
export default (store) => ({
path : 'view*',
/* Async getComponent is only invoked when route matches */
getComponent (nextState, cb) {
/* Webpack - use 'require.ensure' to create a split point
and embed an async module loader (jsonp) when bundling */
require.ensure([], (require) => {
... |
/**
* @author Markus Näsman
* @copyright 2012 (c) Markus Näsman <markus at botten dot org >
* @license Copyright (c) 2012, Markus Näsman
* All rights reserved.
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* *... |
var holidays = require('../');
var dates = holidays(process.argv[2]);
console.dir(dates);
|
// 歌词
module.exports = (query, request) => {
query.cookie.os = 'pc'
const data = {
id: query.id,
lv: -1,
kv: -1,
tv: -1,
}
return request('POST', `https://music.163.com/api/song/lyric`, data, {
crypto: 'api',
cookie: query.cookie,
proxy: query.proxy,
realIP: query.realIP,
})
}... |
const fa_columns = 'M224 1536h608v-1152h-640v1120q0 13 9.5 22.5t22.5 9.5zm1376-32v-1120h-640v1152h608q13 0 22.5-9.5t9.5-22.5zm128-1216v1216q0 66-47 113t-113 47h-1344q-66 0-113-47t-47-113v-1216q0-66 47-113t113-47h1344q66 0 113 47t47 113z'
export default fa_columns |
describe('authenticate', function() {
var $httpBackend, authenticate, authRequestHandler, $localStorage, $location, $browser;
// load the module
beforeEach(module('authClient.services'));
beforeEach(inject(function($injector, baseUrl) {
// Set up the mock http service responses
$httpBackend = $inject... |
var utils = require("./utils.js");
module.exports = BboxAlignedText;
/**
* Creates a new BboxAlignedText object - a text object that can be drawn with
* anchor points based on a tight bounding box around the text.
* @constructor
* @param {object} font - p5.Font object
* @param {string} text - String to display
... |
/*
* Altair Admin
* page_contact_list.js (page_contact_list.html)
*/
$(function() {
// dynamic grid
altair_contact_list.init();
});
altair_contact_list = {
init: function() {
// get all filters
var userArray = [];
$('#contact_list').children().each(function() {
... |
/* ===========================================================
* trumbowyg.allowTagsFromPaste.js v1.0.2
* It cleans tags from pasted text, whilst allowing several specified tags
* http://alex-d.github.com/trumbowyg
* ===========================================================
* Author : Fathi Anshory (0x00000F5C)
... |
'use strict'
import { expect } from 'chai'
import { methods } from '../../src/constants'
import Route from '../../src/router/route'
import Router from '../../src/router'
export default function()
{
describe('Route', function()
{
it(`should throw if the argument router is not an instance of Router`, f... |
var expect = require('chai').expect;
var SQLBuilder = require('../index');
var util = require('util');
describe('SQL Builder Tests',function(){
var builder = new SQLBuilder();
beforeEach(function(){
builder.reset();
});
context('correct usages',function(){
it('simple selct test',functio... |
(function($) {
$(document).ready(function(){
var $loading = $('#loading');
getAvatar();
getDataJSON('/api/v1/users', $loading);
$('#user-id').change(function(){
var $chartDiv = $('#chart-div'),
$errorContainer = $('#data-error'),
selected... |
angular
.module('larakit.form')
.component('formfieldColor', {
templateUrl: '/packages/larakit/ng-adminlte/larakit.form/formfield-color.html',
transclude: true,
bindings: {
error: '=',
desc: '=',
label: '=',
model: '='
},
co... |
/**
* @typedef {import('./types.js').Rule} Rule
* @typedef {import('./types.js').RulePseudo} RulePseudo
* @typedef {import('./types.js').RulePseudoNth} RulePseudoNth
* @typedef {import('./types.js').RulePseudoSelector} RulePseudoSelector
* @typedef {import('./types.js').Parent} Parent
* @typedef {import('./types.... |
/**
* # Functions used by the client of MiniSvo Game
*/
module.exports = {
init: init,
//precache: precache,
//selectLanguage: selectLanguage,
instructions: instructions,
quiz: quiz,
quiz2: quiz2,
choices: choices,
feedback: feedback,
totalpayoff: totalpayoff,
postgame2: postg... |
'use strict';
/**
* Module dependencies.
*/
var jobsPolicy = require('../policies/jobs.server.policy'),
jobs = require('../controllers/jobs.server.controller');
module.exports = function (app) {
// jobs collection routes
app.route('/api/jobs').all(jobsPolicy.isAllowed)
.get(jobs.list)
.post(jobs.creat... |
import {nextAvailableId} from "lib/misc/factoryIdGenerator";
var FooWithRecursion_Schema = {
name: "FooWithRecursion",
documentation: 'A dummy Object.',
id: nextAvailableId(),
fields: [
{name: "name", fieldType: "String"},
{name: "inner", fieldType: "FooWithRecursion"}
]
};
export... |
{
expect.assertions(2);
generateEmptyCoverage.mockImplementation(() => {
throw new Error("SyntaxError");
});
return new Promise((resolve, reject) => {
worker(workerOptions, (error, result) => {
if (!error) {
reject(result);
return;
}
expect(error.message).toMatch(
... |
'use strict';
// Articles controller
angular.module('articles').controller('ArticlesController', ['$scope', '$stateParams', '$location', 'Authentication', 'Articles', 'Metadata',
function ($scope, $stateParams, $location, Authentication, Articles, Metadata) {
$scope.authentication = Authentication;
// Updat... |
var context = context || {};
context.MAX_HEIGHT = 400;
context.MAX_WIDTH = 400;
context.MIN_HEIGHT = 150;
context.MIN_WIDTH = 280;
context.PANE_PADDING_WIDTH = 10;
context.PANE_PADDING_HEIGHT = 5;
context.BRANDING_HEIGHT = 21;
context.MAX_QUERY_WORDS = 6;
context.MAX_QUERY_LENGTH = 200;
context.WIKIPEDIA_MOBILE_HOS... |
var fs = require("fs");
var utils = require('../modules/utils');
fs.readdir('../', function(err, files) {
if (err) throw err;
fs.writeFile('result.txt',
utils.createNiceListofFiles(files),
function(err, data) {
if (err) throw err;
console.log("great");
});
});
//Cette function... |
define(function(require) {
'use strict';
const _ = require('underscore');
const BaseComponent = require('oroui/js/app/components/base/component');
const EmailFolderTreeView = require('oroemail/js/app/views/email-folder-tree-view');
const FolderTreeComponent = BaseComponent.extend({
emailFo... |
var gulp = require('gulp');
var sass = require('gulp-sass');
var browserSync = require('browser-sync');
var reload = browserSync.reload;
gulp.task('sass', function () {
return gulp.src('app/scss/yui.scss')
.pipe(sass())
.pipe(gulp.dest('app/css'))
.pipe(gulp.dest('dist/css'))
});
gulp.task('serve', function ()... |
const flavours = [
{
'colour': '#FFFFFF',
'name_el': 'κλασσικό',
'name_en': 'classic',
'ordering': 1
},
{
'colour': '#DE0914',
'name_el': 'φράουλα',
'name_en': 'strawberry',
'ordering': 2
},
{
'colour': '#F3E5AB',
'name_el': 'βανίλια',
'name_en': 'vanilla',
'ord... |
Triangulum.Load = function (game) {
this.game = game
Triangulum.WIDTH = 800;
Triangulum.HEIGHT = 400;
};
Triangulum.Load.prototype = {
preload: function () {
// set background color and preload image
this.game.stage.backgroundColor = '#000000';
this._preloadBar = this.game.add.sprite((Triangulum.W... |
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* *
* Copyright (C) 2015 Lukas Mayerhofer <lukas.mayerhofer@guh.guru> *
* ... |
export * from "./validationError";
export { default as collectionContainer } from "./collectionContainer";
export { default as fetchModelContainer } from "./fetchModelContainer";
export { default as Provider } from "./Provider";
export { default as searchContainer } from "./searchContainer";
export { default as storeC... |
angular.module('angularEditLabel', [])
.directive('editLabel', ['$timeout', function ($timeout) {
function link(scope, element, attrs) {
scope.editing = false;
scope.onLabelClick = function() {
scope.editing = true;
$timeout(function() {
angular.element(element[0].children[1]).focus();
});
}
... |
function sticksCreate(A){function F(b){var d=new Image;d.onload=function(){var c=d.width,a=d.height,e=document.createElement("canvas");e.width=c;e.height=a;var C=new THREE.Texture(e),g=e.getContext("2d"),q=new THREE.Sprite(new THREE.SpriteMaterial({opacity:b.opacity,map:C}));q.updateInfo=function(e){g.drawImage(d,0,a*T... |
version https://git-lfs.github.com/spec/v1
oid sha256:3cad76f5070b9cc2618a00f2463a9d0f48a8e9f1363b55a7539efeac249a1bdb
size 40003
|
export default Ember.Route.extend({
model: function() {
return this.store.createRecord('pad', {title: 'Un-Named Pad'});
},
exit: function() {
if(!this.get('currentModel').get('id')) {
this.get('currentModel').deleteRecord();
}
}
}); |
const animateFrame = window.requestAnimationFrame ||
window.mozRequestAnimationFrame ||
window.webkitRequestAnimationFrame ||
function(callback) { setTimeout(callback, 1000/60) };
export default animateFrame.bind(window); |
import { getTagDef, getTagDefForTagName } from "@marko/babel-utils";
import * as t from "../../babel-types";
import { enter, exit } from "../util/plugin-hooks";
/**
* Applies custom transformers on tags.
*/
export const visitor = {
MarkoTag: {
enter(path) {
const transformers = getTransformersForTag(path... |
// Generated on 2013-11-17 using generator-angular 0.5.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) {
require('load-grunt-tas... |
"use strict";
const express = require('express');
const router = express.Router();
const moment = require('moment');
const sqlite3 = require('sqlite3').verbose();
const db = new sqlite3.Database('./data/homeautomation.db');
/* GET last values electricity. */
router.get('/', function (req, res, next) {
db.all('SEL... |
// jscs:disable requireCamelCaseOrUpperCaseIdentifiers
const config = {
twitter: {
consumer_key: 'dGyHfD9vih9ND3iEzuabbw',
consumer_secret: '9pwl7ypmg1kLutJrjSeKhahq97Ewhx7tG9hU4pg5c',
access_token: '92252898-jDICTbun7HfWAhyk9MESYABCeii2knyhwAfPUuIx4',
access_token_secret: 'RmUo1UTgr... |
var expect = require('chai').expect;
var request = require('request');
var axios = require('axios');
var path = require('path');
var amorphicContext = require('../../lib/AmorphicContext');
var serverAmorphic = require('../../index.js');
function afterEachDescribe(done) {
if(amorphicContext.appContext.connectServe... |
/**
* Created by Miku on 16/4/14.
*/
module.exports= function (AV) {
'use strict';
// var AV = require('leanengine');
var AreaPointIndex = AV.Object.extend("AreaPointIndex");
var AreaPointIndexService = {};
/**
* 加载区域首页项
* @param userId
* @param type
* @returns {*|T|{}}
... |
/**
* Contains some infos and stuff used in every tasks
*
*/
var fs = require('fs');
exports.capitalize = function(str){
return str.replace(/\w\S*/g, function(txt){return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();});
};
// can't use trim() as we need to escape white space for node.js
exports.... |
var searchData=
[
['actionsresolved',['ActionsResolved',['../class_sensorberg_s_d_k_1_1_internal_1_1_services_1_1_resolver.html#af9c426c0e270af2e4e3254e5bb34f1c7',1,'SensorbergSDK.Internal.Services.Resolver.ActionsResolved()'],['../interface_sensorberg_s_d_k_1_1_services_1_1_i_resolver.html#ae3ecae8e02ee01e0b7a24af71... |
var searchData=
[
['fd',['fd',['../structelfInfo.html#ac8a1c6ebaf5d5c6884294d969ed5c1fd',1,'elfInfo']]],
['fileinfoidx',['fileInfoIdx',['../structcompileUnit.html#a88f5799c82d8396a64a64accec9c6618',1,'compileUnit']]],
['fileinfos',['fileInfos',['../structcompileUnit.html#a36a3253e2946874e0ecc09655da66d02',1,'comp... |
/**
_ ____ _ _ __ ____ ___
| | _ \ / \ | |/ / __ _|___ \ / _ \
_ | | |_) / _ \ | ' / \ \ / / __) || | | |
| |_| | __/ ___ \| . \ \ V / / __/ | |_| |
\___/|_| /_/ \_\_|\_\ \_/ |_____(_)___/
Multiuse Javascript Package
https://g... |
require('vue-resource');
Vue.component('championship', require('./components/Championship.vue'));
Vue.component('win-bar', require('./components/WinBar.vue'));
Vue.component('strategy-editor', require('./components/StrategyEditor.vue'));
Vue.component('logs-viewer', require('./components/LogsViewer.vue'));
const app ... |
import React, { useRef, useState } from 'react';
import AppBar from '@material-ui/core/AppBar';
import IconButton from '@material-ui/core/IconButton';
import Popover from '@material-ui/core/Popover';
import Toolbar from '@material-ui/core/Toolbar';
import Typography from '@material-ui/core/Typography';
import EventIc... |
module.exports = function (grunt) {
'use strict';
grunt.initConfig({
jshint: {
all: ['Gruntfile.js', 'app/js/**/*.js']
},
karma: {
unitSingleRun: {
configFile: 'config/karma.conf.js',
singleRun: true
},
unit... |
import React from 'react';
import darkBaseTheme from 'material-ui/styles/baseThemes/darkBaseTheme';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';
import getMuiTheme from 'material-ui/styles/getMuiTheme';
import Paper from 'material-ui/Paper'
import AppBar from 'material-ui/AppBar';
import IconButt... |
/* @flow */
import React from 'react';
import Remarkable from 'remarkable';
type PropsType = {
markdown: string,
options?: {
preset?: 'default' | 'commonmark' | 'full',
html?: boolean,
xhtmlOut?: boolean,
breaks?: boolean,
langPrefix?: string,
linkify?: boolean,
typographer?: boolean,
... |
//爬虫的主要业务逻辑模块
const phantom = require('phantom')
const cheerio = require('cheerio')
const userAgent = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/61.0.3163.100 Safari/537.36'
// const urlStr = 'https://read.douban.com/kind/105?start=0&sort=hot'
/**
* 从每一页的html代码中,提取... |
var http = require('http');
var https = require('https');
var querystring = require('querystring');
var hostname = 'image-charts.com';
module.exports = {
'setHostname': function(newHostname){
hostname = newHostname;
},
'createUrl': function(chart, secure) {
var qs = getQuerystring(chart);
return ((s... |
"use strict";
/**
*
*/
angular.module("maxausApp").factory("UtilsService", function () {
var utilsService = {};
utilsService.markListItemAsSelected = function (id) {
$(".navbar-collapse li").each(function () {
var item = $(this);
if (item.attr("id") === (id)) {
item.addClass("active")... |
module.exports = function(config) {
config.set({
basePath: '../',
files: [
// bower:js
'../dist/components/jquery/dist/jquery.js',
'../dist/components/angular/angular.js',
'../dist/components/angular-sanitize/angular-sanitize.js',
'../dist/components/angular-messages/angular-me... |
import * as React from 'react';
import { expect } from 'chai';
import { createRenderer, within } from 'test/utils';
import Menu from '@mui/material/Menu';
import MenuItem from '@mui/material/MenuItem';
const NoTransition = React.forwardRef(function NoTransition(props, ref) {
const { children, in: inProp } = props;
... |
import app from './app';
app('#app');
|
export const ic_sync_outline = {"viewBox":"0 0 24 24","children":[{"name":"path","attribs":{"d":"M.01 0h24v24h-24V0z","fill":"none"},"children":[]},{"name":"path","attribs":{"d":"M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-... |
import React, { Component } from 'react';
import Router from 'next/router';
import { injectGlobal } from 'styled-components';
import Lock from '../utils/lock';
import auth from '../utils/auth';
import withData from '../lib/with-data';
import Header from '../home/header';
import Hero from '../home/hero';
import Features... |
module.exports = {
INVALID_TOKEN: function() {
return { error: 'invalid or missing token' };
},
MISSING_PARAM: function(p) {
return { error: 'missing parameter: ' + p };
},
INVALID_PARAM: function(p) {
return {
error: 'parameter: ' + p + ' is not valid or does not match'
};
},
NO_USE... |
export const dribbble = {"viewBox":"0 0 1536 1792","children":[{"name":"path","attribs":{"d":"M1024 1500q-42-241-140-498h-2l-2 1q-16 6-43 16.5t-101 49-137 82-131 114.5-103 148l-15-11q184 150 418 150 132 0 256-52zM839 893q-21-49-53-111-311 93-673 93-1 7-1 21 0 124 44 236.5t124 201.5q50-89 123.5-166.5t142.5-124.5 130.5-8... |
import { combineReducers } from 'redux';
import { userAuth } from './auth-reducers';
import { blogs } from './blog-reducers';
export default combineReducers({
userAuth,
blogs
});
|
var searchData=
[
['unreadmsgcount',['unreadMsgCount',['../struct_jmcpp_1_1_multi_unread_msg_count_changed_event.html#af6ee70f5b5c66dfafdd34c99b56c0064',1,'Jmcpp::MultiUnreadMsgCountChangedEvent']]],
['unreadusercount',['unreadUserCount',['../struct_jmcpp_1_1_receipts_updated_event_1_1_message_receipt_info.html#aad... |
import React from 'react'
import { render } from 'react-dom'
// import { Router, Route, browserHistory } from 'react-router'
import App from './components/app/App.js'
render((
<App />
), document.getElementById('app'))
// <Router history={browserHistory}>
// <Route component={App} path="/" />
// </... |
'use strict';
// Angular E2E Testing Guide:
// https://docs.angularjs.org/guide/e2e-testing
describe('FinalorderCat Application', function() {
it('should redirect `index.html` to `index.html#!/finalorders', function() {
browser.get('index.html');
expect(browser.getLocationAbsUrl()).toBe('/finalorders');
... |
'use strict';
var errors = require('./errors').errno;
var fxa = require('./fxa');
var sendError = require('./utils').sendError;
module.exports = (function(req, res, next) {
function unauthorized(res, message) {
sendError(res, errors.INVALID_AUTH_TOKEN, message || 'Unauthorized');
}
return f... |
module.exports = (pool) => {
if (pool.length === 0) {
throw new Error('cannot prepare a zero length pool')
}
const preparedPool = []
pool.sort(function(a, b) {
return b.weight - a.weight
})
pool.forEach(function (entry, index) {
let object
// check this in a way that allows the use of zeros and "false... |
// Copyright 2013 The Closure Library Authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless requ... |
require("./spec_helper.js");
describe("is sorted", function() {
var fArr = CollectionFunctions.Array.functions
var numberComparator = function(a,b){
if (a==b) {
return 0
} else if (a<b) {
return 1
... |
/*
* Copyright (c) André Bargull
* Alle Rechte vorbehalten / All Rights Reserved. Use is subject to license terms.
*
* <https://github.com/anba/es6draft>
*/
/*---
esid: sec-createdynamicfunction
description: |
Create a Function with the function body being a html open comment.
info: >
19.2.1.1.1 Runtime Seman... |
import { name, description } from '../../site'
export default {
name,
description,
url: '/',
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.