text stringlengths 2 1.04M |
|---|
import React from 'react';
import ItemDetails, { Record } from '../item-details';
import { SwapiServiceConsumer } from '../swapi-service-context';
const PersonDetails = ({ itemId }) => {
return (
<SwapiServiceConsumer>
{
({ getPerson, getPersonImage }) => {
return (
<ItemDet... |
import React from 'react';
import { EuiFieldText, EuiFlexGroup, EuiFlexItem } from '@elastic/eui';
export default function SampleText(props) {
const { text, updateSampleText } = props;
return (
<EuiFlexGroup key="text-sample">
<EuiFlexItem>
<EuiFieldText
fullWidth
prepend="Te... |
/**
* @file
* Javascript for the interface at admin/content/media and also for interfaces
* related to setting up media fields and for media type administration.
*
* Basically, if it's on the /admin path, it's probably here.
*/
(function ($) {
/**
* Functionality for the administrative file listings.
*/
Drupa... |
'use babel';
// utility for moving a point..
export default function pointMove(p, n, editor) {
const steps = Math.abs(n),
pClone = p.copy();
if (n < 0)
return movePointBack(pClone, steps, editor);
return movePointFront(pClone, steps, editor);
}
function movePointFront(p, counter, e) {
const lastRow = ... |
import searchOpacityIcon from '../images/icons/search-opacity.svg';
import algoliaLogo from '../images/logos/powered-by-algolia.svg';
import { Link, withRouter } from 'react-router-dom';
import Algolia from 'algoliasearch';
import Img from 'react-image';
import PropTypes from 'prop-types';
import React from 'react';
im... |
// Function returns the number (count) of vowels in the given string.
function getCount(str) {
var vowelsCount = str.match(/[aeiou]/gi);
if (vowelsCount != null) {
return vowelsCount.length;
} else return 0;
}
describe("Case 1", function(){
it ("should be defined", function(){
Test... |
macDetailCallback("00209c000000/24",[{"d":"1998-04-22","t":"add","a":"10080 CARROLL CANYON RD\nSAN DIEGO CA 92131\n\n","c":"UNITED STATES","o":"PRIMARY ACCESS CORP."},{"d":"2001-10-24","t":"change","a":"10080 CARROLL CANYON RD\nSAN DIEGO CA 92131\n\n","c":"UNITED STATES","o":"PRIMARY ACCESS CORP."},{"d":"2015-08-27",... |
import skuParser from '../helpers/skuParser'
// import skuFilter from '../helpers/skuFilter'
// getAll is a function that can be passed instead of skuParser to disable sku checking.
// function getAll(attributeValues) {
// return Object.keys(attributeValues).reduce((acc, curr) => {
// return {
// ...acc,
/... |
import superagent from 'superagent';
const methods = ['get', 'post', 'put', 'patch', 'del'];
export function formatUrl(path) {
if (path.substr(0, 4).toLowerCase() == 'http') {
return path;
}
const adjustedPath = path[0] !== '/' ? '/' + path : path;
return __API_URL__ + adjustedPath;
}
export default clas... |
function getUniqueUsernames(array) {
let usernames = new Set()
array.forEach(username => {
usernames.add(username)
});
let sortedUsernames = Array.from(usernames.keys()).sort((a, b) => {
let result = a.length - b.length
if (result === 0) {
return a.localeCompare(... |
import * as tslib_1 from "tslib";
import { ElementRef, NgZone, ChangeDetectorRef, Component, Input, Output, EventEmitter } from '@angular/core';
import { fromEvent as observableFromEvent } from 'rxjs';
import { debounceTime } from 'rxjs/operators';
import { VisibilityObserver } from '../../utils/visibility-observer';
l... |
/*
* jQuery Hotkeys Plugin
* Copyright 2010, John Resig
* Dual licensed under the MIT or GPL Version 2 licenses.
*
* Based upon the plugin by Tzury Bar Yochay:
* http://github.com/tzuryby/hotkeys
*
* Original idea by:
* Binny V A, http://www.openjs.com/scripts/events/keyboard_shortcuts/
*/ |
/*
Template Name: Color Admin - Responsive Admin Dashboard Template build with Twitter Bootstrap 3.3.7
Version: 2.1.0
Author: Sean Ngu
Website: http://www.seantheme.com/color-admin-v2.1/admin/html/
*/
var handleEmailActionButtonStatus = function() {
if ($('[data-checked=email-checkbox]:checked').length !== 0) {
... |
/* global module, inject, chai, _ */
"use strict";
var utils = hqImport('icds_reports/js/spec/utils');
var pageData = hqImport('hqwebapp/js/initial_page_data');
describe('Adolescent Girls Directive', function () {
var $scope, $httpBackend, $location, controller, controllermapOrSectorView;
pageData.register... |
/* global JSON:false */
var mongoose = require('mongoose'),
///////////////////////////////////////////////////////////////////////////////
// Schemas
///////////////////////////////////////////////////////////////////////////////
/**
* ...
*/
StateChangeMongooseSchema = exports.StateChangeMongoos... |
/*
* Copyright (c) Microsoft Corporation.
* Licensed under the MIT License.
*
* Code generated by Microsoft (R) AutoRest Code Generator.
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
*/
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
const { Operat... |
'use strict';
var assert = require('chai').assert;
var sinon = require("sinon");
var configModule = require('./../../../src/config/default');
describe('config/default', function () {
it('should be an exportable node module in form of a function', function () {
assert.isFunction(configModule);
});
it('sho... |
'use strict';
var should = require('should');
var sinon = require('sinon');
var dashcore = require('@geekcash/geekcash-lib');
var TxController = require('../lib/transactions');
var _ = require('lodash');
describe('Transactions', function() {
describe('/tx/:txid', function() {
it('should have correct data', funct... |
module.exports = {
rules: {
/**
* 禁止函数在不同分支返回不同类型的值
* @category Best Practices
* @reason 太严格了
*/
'consistent-return': 'off'
}
}; |
const router = require('express').Router();
const { PR } = require('../models');
router.get('/', async (request, response) => {
const prs = await PR.find({}).then(data => data);
prs.sort((a, b) => a._id - b._id);
const indices = prs.reduce((obj, { _id }, index) => {
obj[_id] = index;
return obj;
}, {})... |
const { accounts, defaultSender, contract } = require('@openzeppelin/test-environment');
const { expect } = require('../../chai-local');
const { expectRevert, expectEvent, BN } = require('@openzeppelin/test-helpers');
const XTransferRerouter = contract.fromArtifact('XTransferRerouter');
describe('XTransferRerouter', ... |
import React from 'react';
import Calender from './Calender';
import renderer from 'react-test-renderer';
import { shallow, mount } from 'enzyme';
import sinon from 'sinon';
test('Render component calender', () => {
const component = renderer.create(
<Calender onChange={() => {}} value={new Date('1996-03-14')} />
... |
var NAVTREEINDEX =
{
"index.html":[],
"index.html":[0],
"std_locales.html":[0,0],
"using_boost_locale.html":[0,1],
"locale_gen.html":[0,1,0],
"collation.html":[0,1,1],
"conversions.html":[0,1,2],
"formatting_and_parsing.html":[0,1,3],
"messages_formatting.html":[0,1,4],
"charset_handling.html":[0,1,5],
"boundary_analys... |
/* global describe, it */
describe( 'SMAAPass', () => {
it( 'is bundlable', () => {
should.exist( Three['SMAAPass'] )
} )
it( 'is instanciable', () => {
should.exist( new Three['SMAAPass']() )
} )
} ) |
"use strict";
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Refl... |
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
try {
var info = gen[key](arg);
var value = info.value;
} catch (error) {
reject(error);
return;
}
if (info.done) {
resolve(value);
} else {
Promise.resolve(value).then(_next,... |
'use strict'
module.exports = one
var u = require('unist-builder')
var all = require('./all')
var own = {}.hasOwnProperty
// Transform an unknown node.
function unknown(h, node) {
if (text(node)) {
return h.augment(node, u('text', node.value))
}
return h(node, 'div', all(h, node))
}
// Visit a node.
fun... |
// We make use of this 'server' variable to provide the address of the
// REST Janus API. By default, in this example we assume that Janus is
// co-located with the web server hosting the HTML pages but listening
// on a different port (8088, the default for HTTP in Janus), which is
// why we make use of the 'window.lo... |
"use strict";
import * as tbrpg from '@oh-my-rpg/state-the-boring-rpg'
import { get_item_at_coordinates } from '@oh-my-rpg/state-inventory'
import { LS_KEYS } from './consts'
function persist(state) {
localStorage.setItem(LS_KEYS.savegame, JSON.stringify(state))
}
// TODO add error handling mechanism for play bugs,... |
const express = require('express');
const router = require('./router/index.js')
const DB = require('./db/mongo')
const config = require('./config/index')
const app = express();
//db conection
const DB_URI = `mongodb+srv://${config.db.db_user}:${config.db.db_password}@puentech.4m87s.mongodb.net/${config.db.db_name}?re... |
// This file was procedurally generated from the following sources:
// - src/dstr-assignment/obj-prop-nested-obj-yield-ident-invalid.case
// - src/dstr-assignment/syntax/for-in.template
/*---
description: When a `yield` token appears within the Initializer of a nested destructuring assignment and outside of a generator... |
exports.handler = async (event) => {
console.log(JSON.stringify(event));
var today = new Date();
var birthdaysToday = Object.keys(event.Endpoints)
.filter(endpointId => {
var bday = new Date(event.Endpoints[endpointId].User.UserAttributes.Birthdate);
return bday.getMonth() === today.getMonth() &... |
(function($) {
"use strict"; // Start of use strict
$(document).ready(function(){
setTimeout(function(){
$(".m-san-box").animate({
opacity: '1'
}, 4000);
setTimeout(function(){
$("#gh-img").animate({
opacity: '1'
}, 2000);
}, 500);
... |
import { FETCH_ALL, CREATE, UPDATE, DELETE } from '../constants/actionTypes';
import * as api from '../api';
// Action Creators
const getPosts = () => async (dispatch) => {
try {
const { data } = await api.fetchPosts();
dispatch({ type: FETCH_ALL, payload: data })
} catch (error) {
con... |
const express = require('express');
const cors = require('cors');
const corsAnywhere = require('cors-anywhere');
const path = require('path');
const port = process.env.PORT || 3030;
process.env.PWD = process.cwd();
var app = express();
let proxy = corsAnywhere.createServer({
originWhitelist: [], // Allow all origin... |
var args = arguments[0] || {};
Alloy.Globals.module = "help";
if(OS_ANDROID){
MENU.construct($,$.reminderView.contentView);
MENU.initMenu();
}else{
MENU.construct($,"");
}
COMMON.construct($);
COMMON.addSwipeUpEvent();
$.helpView.headerView.titleLabel.text= Ti.App.Properties.getString('Title') + " " +Ti.App.Pro... |
'use strict'
var ModelUtil = require('bpmn-js/lib/util/ModelUtil'),
is = ModelUtil.is,
getBusinessObject = ModelUtil.getBusinessObject
var extensionElementsHelper = require('./ExtensionElementsHelper'),
implementationTypeHelper = require('./ImplementationTypeHelper')
var InputOutputHelper = {}
module.exports =... |
import { EventGroup, getDocument } from '../../Utilities';
var MOUSEDOWN_PRIMARY_BUTTON = 0; // for mouse down event we are using ev.button property, 0 means left button
var MOUSEMOVE_PRIMARY_BUTTON = 1; // for mouse move event we are using ev.buttons property, 1 means left button
var DragDropHelper = /** @class */ (fu... |
import React, { Component } from "react";
import AddLocker from "./AddLocker";
import { API_KEY } from "react-native-dotenv";
export default class AddLockerContainer extends Component {
constructor(props) {
super(props);
this.state = {
filesToUpload: [],
reviewRating: null,
isModalVisible: ... |
import { validString, validNumber, validEmail, validAlpha } from './Regex';
export default function validate(values, preErrors) {
let errors = {};
if (!values.franchise_name) {
errors.franchise_name = 'Franchise Name is required';
}else if(!validAlpha.test(values.franchise_name)){
errors.franchise_nam... |
/**
*
* Send a sequence of key strokes to an element (clears value before). You can also use
* unicode characters like Left arrow or Back space. WebdriverIO will take care of
* translating them into unicode characters. You’ll find all supported characters
* [here](https://code.google.com/p/selenium/wiki/JsonWirePr... |
/*
if (typeof define !== 'function') {
var define = require('amdefine')(module);
}
//var binding_path = __dirname + '/../build/Release/image_binding.node'
//var cpp_mod = require('../build/Release/image_binding');
//console.log('binding_path', binding_path);
// Will not use the jpeg cpp for the moment.
// It ca... |
/*! For license information please see index~adcb47af.114f74849a9e81ef101c.js.LICENSE.txt */ |
import { Directive, ElementRef, EventEmitter, Input, Output } from '@angular/core';
import { isPresent, isTrueProperty } from '../../util/util';
export var Option = (function () {
function Option(_elementRef) {
this._elementRef = _elementRef;
this._selected = false;
this._disabled = false;
... |
import React, { Component, PropTypes } from 'react'
import { connect } from 'react-redux'
import {fetchMessage,fetchArticle} from '../actions'
import Content from '../components/Message/Content/Content'
import LinkToLogin from '../components/common/LinkToLogin/LinkToLogin'
import Header from '../components/common/Heade... |
const { promises: { readFile } } = require('fs');
const { join } = require('path');
const { buildSchema, graphql, introspectionQuery } = require('graphql');
module.exports = {
someFetchFn: async () => {
const schemaFile = await readFile(join(__dirname, '../test-documents/schema.graphql'), 'utf8');
const sche... |
/*
* © Copyright IBM Corp. 2017, 2018
*
* 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 required by applicable law or agreed t... |
/**
* @author Richard Davey <rich@photonstorm.com>
* @author Pavle Goloskokovic <pgoloskokovic@gmail.com> (http://prunegames.com)
* @copyright 2020 Photon Storm Ltd.
* @license {@link https://opensource.org/licenses/MIT|MIT License}
*/
var BaseSound = require('../BaseSound');
var Class = requi... |
"use strict"
exports.__esModule = true;
exports.SmileIconConfig = {
name: 'SmileIcon',
height: 512,
width: 496,
svgPath: 'M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm-160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14... |
// Load modules.
var OAuth2Strategy = require('passport-oauth2')
, util = require('util')
, uri = require('url')
, crypto = require('crypto')
, Profile = require('./profile')
, InternalOAuthError = require('passport-oauth2').InternalOAuthError
, FacebookAuthorizationError = require('./errors/facebookauthori... |
import React from 'react';
import PropTypes from 'prop-types';
import orgApplicationStatusMenu from 'constants/orgApplicationStatus';
import orgIsActiveMenu from 'constants/orgIsActive';
import { formatAddress, renderFromMenu } from 'utilities/format';
import InfoCard from './InfoCard';
export default function Organi... |
import LocationModel from "../models/location";
import apiResponse from "../helpers/apiResponse";
export default class LocationController {
static async addLocation(request, response) {
const { name } = request.body;
try {
const foundLocation = await LocationModel.findOne({ name });
if (foundLoca... |
export default function({ store, redirect }) {
// ユーザーが認証されていないとき
if (!store.state.users.user) {
return redirect('/')
}
} |
}else try{o=!!f.node.sheet.cssRules,r.splice(s,1),s-=1,n._progress(null,f)}catch(c){}}r.length&&(n._pollTimer=setTimeout(function(){n._poll.call(n)},n.options.pollInterval))},_progress:function(e,t){var n=this.options;e&&(t.error=e,this.errors.push({error:e,request:t})),t.node._yuiget_finished=t.finished=!0,n.onProgres... |
const express = require('express');
const router = express.Router();
const AuthApi = require('../app/controllers/authController');
const middlewareResponse = require('../app/middleware/response');
const auth = require('../app/middleware/auth');
const authApi = new AuthApi();
router.get('/', (req, res) => {
res.send(... |
import EmptyState from './EmptyState.vue';
export { EmptyState };
export default EmptyState; |
// Library Imports
import React from 'react';
import RN from 'react-native';
// Local Imports
import { styles } from './list_footer_styles';
import { UTILITY_STYLES, getUsableDimensions } from '../../utilities/style_utility';
//----------------------------------------------------------... |
import {join} from 'path';
const baseDir = join(__dirname, '..', 'app', 'node_modules');
require('app-module-path').addPath(baseDir); |
/**
* @file caps.js
* Implements XEP-0115 (Entity Capabilities)
* @see http://xmpp.org/extensions/xep-0115.html
* The disco plugin is recommended.
*/
define(['strophe.js'], ({Strophe, SHA1, $build}) => {
const cmp = (a, b) => (a !== b) * (1 - 2 * (a < b));
const cmpProp = prop => (a, b) => cmp(a[prop], b[pr... |
var ASSERTIVE_NAME = 'Hariko API Server';
module.exports = function () {
return function (req, res, next) {
res.set('X-Powered-By', ASSERTIVE_NAME);
next();
};
}; |
module.exports = {
default: {
src: [
'packages/ember-model/**/*.js',
'test_helpers.js',
'dist/ember-model'
],
options: {
on_change: 'grunt dev_build',
test_page: 'tests/index.html',
reporter: 'tap',
launch_in_ci: ['Chrome'],
launch_in_dev: ['Chrome'],
... |
/*
Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/ |
"use strict";
var clc = require("cli-color");
var _ = require("lodash");
var firebaseApi = require("../../firebaseApi");
var prompt = require("../../prompt");
var logger = require("../../logger");
var utils = require("../../utils");
var NO_PROJECT = "[don't setup a default project]";
var NEW_PROJECT = "[create a new pr... |
// @flow
import { combineReducers } from 'redux';
import { connectRouter } from 'connected-react-router';
import type { HashHistory } from 'history';
import { submitPasswordType } from '../actions/auth';
import createReducer from './createReducer';
export default function createRootReducer(history: HashHistory) {
r... |
Template.postSubmit.events({
'submit form': function(e) {
e.preventDefault();
var post = {
url: $(e.target).find('[name=url]').val(),
title: $(e.target).find('[name=title]').val()
};
var errors = validatePost(post);
if (errors.title || errors.url) {
return Session.set('postSubmitErrors', errors);
... |
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @polyfill
*
* @format
*/
'use strict';
/* eslint-disable no-bitwise */
global.__r = metroRequire;
global.__d = define;
glo... |
const path = require('path');
const fs = require('fs-extra');
const { Ret, execCommand,
setupLocalJest, formatErrorJest } = require('./utils');
class TestTask {
constructor(config) {
this.config = config;
}
async run() {
const { config: tc } = this;
const ret = new Ret();
... |
/* eslint-env mocha */
const isbot = require('..')
const BROWSER_UA = 'Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.86 Safari/533.4'
const CRAWLER_UA = 'Mozilla/3.0 (compatible; Web Link Validator 2.x)Web Link Validator http://www.relsoftware.com/ link validat... |
module.exports = function(app) {
var multer = require("multer"); // npm install multer --save
var upload = multer({ dest: "./client/public" });
var widgetModel = require("../models/widget/widget.model.server");
app.post("/api/page/:pid/widget", createWidget);
app.get("/api/page/:pid/widget", findA... |
/**
* @overview datejs
* @version 1.0.0-beta-2014-03-25
* @author Gregory Wild-Smith <gregory@wild-smith.com>
* @copyright 2014 Gregory Wild-Smith
* @license MIT
* @homepage https://github.com/abritinthebay/datejs
*/
/*
* DateJS Culture String File
* Country Code: mt-MT
* Name: Maltese (Malta)
* Format: "k... |
import isURL from 'validator/lib/isURL'
import isDataURI from 'validator/lib/isDataURI'
import isDecimal from 'validator/lib/isDecimal'
import configure from '../config'
import { ACCOUNT_REGEXP } from '../constants'
const { env } = configure()
export const log = (message) => {
if (env !== 'test') {
// eslint-di... |
/*!
DataTables Foundation integration
©2011-2015 SpryMedia Ltd - datatables.net/license
*/
(function(d){"function"===typeof define&&define.amd?define(["jquery","datatables.net"],function(a){return d(a,window,document)}):"object"===typeof exports?module.exports=function(a,b){a||(a=window);if(!b||!b.fn.dataTable)b=requ... |
import * as React from 'react';
import createSvgIcon from './utils/createSvgIcon';
import { jsx as _jsx } from "react/jsx-runtime";
import { jsxs as _jsxs } from "react/jsx-runtime";
export default createSvgIcon( /*#__PURE__*/_jsxs(React.Fragment, {
children: [/*#__PURE__*/_jsx("path", {
d: "M15.95 7l-1.83-2H9.88... |
var gulp = require('gulp');
var browserify = require('browserify');
var babelify = require('babelify');
var source = require('vinyl-source-stream');
var webserver = require('gulp-webserver');
var uglify = require('gulp-uglify');
var concat = require('gulp-concat');
gulp.task('browserify', function() {
browserify('... |
"use strict";
var Vehiculos_agregar = (function () {
function Vehiculos_agregar() {
this.peticion = new Peticion({ url: this.url_api });
this.inicializar();
}
Object.defineProperty(Vehiculos_agregar.prototype, "url_api", {
get: function () {
return localStorage.getItem('u... |
"use strict";var KTCookie={getCookie:function(e){var o=document.cookie.match(new RegExp("(?:^|; )"+e.replace(/([\.$?*|{}\(\)\[\]\\\/\+^])/g,"\\$1")+"=([^;]*)"));return o?decodeURIComponent(o[1]):void 0},setCookie:function(e,o,n){n||(n={}),(n=Object.assign({},{path:"/"},n)).expires instanceof Date&&(n.expires=n.expires.... |
import Vue from "vue";
import App from "./App.vue";
import "bootstrap/dist/css/bootstrap.css";
import "../static/style.css";
import VueApollo from "vue-apollo";
import router from "./router";
import ApolloClient from "apollo-boost";
import { InMemoryCache } from "apollo-boost";
Vue.use(VueApollo);
Vue.config.product... |
/**
* @author OA Wu <comdan66@gmail.com>
* @copyright Copyright (c) 2015 - 2019, Ginkgo
* @license http://opensource.org/licenses/MIT MIT License
* @link https://www.ioa.tw/
*/
const rq = require;
const Ginkgo = rq('../Ginkgo');
const cc = Ginkgo.cc;
const ln = Ginkgo.ln;
const pp = Ginkgo.pp;
... |
import { STRICT } from '../helpers/constants';
QUnit.test('String#padStart', assert => {
const { padStart } = String.prototype;
assert.isFunction(padStart);
assert.arity(padStart, 1);
assert.name(padStart, 'padStart');
assert.looksNative(padStart);
assert.nonEnumerable(String.prototype, 'padStart');
asse... |
/*! Widget: grouping - updated 11/10/2015 (v2.24.4) */ |
import React from 'react'
import Enzyme, { shallow } from 'enzyme'
import Adapter from 'enzyme-adapter-react-16'
import { CollectionDetailsBodyContainer } from '../CollectionDetailsBodyContainer'
import CollectionDetailsBody from '../../../components/CollectionDetails/CollectionDetailsBody'
Enzyme.configure({ adapter:... |
import React from 'react';
import WeatherComponent from '../components/WeatherComponent';
import SevenHour from '../components/SevenHour';
import TenHour from '../components/TenDay';
import CurrentWeather from '../components/CurrentWeather';
import { shallow, mount } from 'enzyme';
import '../setupTests';
describe('We... |
'use strict';
module.exports = {
extends: 'stylelint-config-antife',
rules: {
'function-comma-space-after': 'always-single-line',
}
} |
/* eslint-disable no-console */
import LintingEsLint from '../linting-eslint/index.js';
import LintingPrettierMixin from '../linting-prettier/index.js';
import LintingCommitlintMixin from '../linting-commitlint/index.js';
const LintingMixin = subclass =>
class extends LintingCommitlintMixin(LintingPrettierMixin(Lint... |
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('@carbon/icon-helpers'), require('prop-types'), require('react')) :
typeof define === 'function' && define.amd ? define(['@carbon/icon-helpers', 'prop-types', 'react'], factory) :
(global.... |
import React, { Component } from 'react';
import { StyleSheet, Text } from 'react-native';
import {
Button,
} from 'native-base';
import PropTypes from 'prop-types';
import colors from '../util/colors';
const styles = StyleSheet.create({
button: {
width: 200,
alignSelf: 'center',
paddingLeft: 0,
},
... |
const fs = require("fs");
const uniqid = require('uniqid');
module.exports = (app) => {
app.get('/api/notes', (req, res) => {
fs.readFile('./db/db.json', 'utf8', (error, data) =>
error ? console.error(error) : res.json(JSON.parse(data))
);
});
app.post('/api/notes', (req, res) ... |
import reduceList, * as listActions from './utils/list'
import reduceView, * as viewActions from './utils/view'
import * as websocketActions from './websocket'
import * as msgQueueActions from './msgQueue'
export const MSG_TYPE = 'UPDATE_EVENTLOG'
export const DATA_URL = '/events'
export const ADD = 'EV... |
"use strict";
/** @internal @packageDocumentation */
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) ... |
//== Class definition
var DefaultDatatableDemo = function () {
//== Private functions
// basic demo
var demo = function () {
var datatable = $('.m_datatable').mDatatable({
data: {
type: 'remote',
source: {
read: {
url: 'https://keenthemes.com/metronic/themes/themes/metronic/dist/preview/in... |
// IE Fix
if (!Array.prototype.includes) {
Object.defineProperty(Array.prototype, "includes", {
enumerable: false,
value: function(obj) {
var newArr = this.filter(function(el) {
return el == obj;
});
return newArr.length > 0;
}
});
}
w... |
"use strict";
/**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[... |
// Flash Player Version Detection - Rev 1.5
// Detect Client Browser type
// Copyright(c) 2005-2006 Adobe Macromedia Software, LLC. All rights reserved.
var isIE = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;
var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false;
var isOp... |
import React, { createElement as h } from "react";
import { observer } from "mobx-react";
import page from "components/Page";
import paper from "components/Paper";
import spinner from "components/spinner";
import alertAjax from "components/alertAjax";
export default context => {
const { tr } = context;
const Page ... |
const fs = require('fs-extra')
const path = require('path')
const chalk = require('chalk')
const vfs = require('vinyl-fs')
const Vinyl = require('vinyl')
const through2 = require('through2')
const babylon = require('babylon')
const traverse = require('babel-traverse').default
const t = require('babel-types')
const gene... |
// Modules
import React, {Component, Fragment} from 'react';
// Github Pages requires HashRouter to properly route subpages
import {HashRouter as Router, Route} from 'react-router-dom';
import ReactGA from 'react-ga';
import { createBrowserHistory } from 'history';
// Styles
import './assets/scss/style.scss';
// Conte... |
import React from 'react';
import { storiesOf } from '@storybook/react';
import { Settings } from './';
storiesOf('views/Settings', module).add('Main', () => <Settings />); |
import React, {Component} from 'react'
import {connect} from 'react-redux'
import {withRouter, Route, Switch} from 'react-router-dom'
import PropTypes from 'prop-types'
import {Login, Signup, UserHome} from './components'
import {AddEmail} from './components/email-form'
import {AddShoutout} from './components/shoutout-... |
/**
* @fileoverview This file is generated by the Angular 2 template compiler.
* Do not edit.
* @suppress {suspiciousCode,uselessCode,missingProperties}
*/
/* tslint:disable */
var __extends = (this && this.__extends) || function (d, b) {
for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
function __() ... |
var C = require("../contex/index");
var CP = require("../contex-primitives/index")(C);
var CI = require("../contex-image/index")(C);
var CT = require("../contex-tiled/index")(C, CI);
var gloop = require('gloop')();
require('keyboardevent-key-polyfill').polyfill();
var Contex = C.Contex;
var Color = C.Color;
var Color... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.