text stringlengths 3 1.05M |
|---|
/*
* Globalize Culture es-NI
*
* http://github.com/jquery/globalize
*
* Copyright Software Freedom Conservancy, Inc.
* Dual licensed under the MIT or GPL Version 2 licenses.
* http://jquery.org/license
*
* This file was generated by the Globalize Culture Generator
* Translation: bugs found in this file need t... |
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([[4],{
/***/ "./node_modules/babel-loader/lib/index.js?!./node_modules/vue-loader/lib/index.js?!./resources/js/Pages/MovieInfo.vue?vue&type=script&lang=js&":
/*!*************************************************************************************************... |
import { createAction, handleActions } from 'redux-actions';
/* Types */
const LOGIN = 'Auth/LOGIN';
const LOGIN_SUCCESS = 'Auth/LOGIN_SUCCESS';
const LOGIN_FAILURE = 'Auth/LOGIN_FAILURE';
const LOGOUT = 'Auth/LOGOUT';
const LOGOUT_SUCCESS = 'Auth/LOGOUT_SUCCESS';
const UPDATE_TOKEN = 'Auth/UPDATE_T... |
var five = require("johnny-five"),
board = new five.Board();
board.on("ready", function() {
var piezo = new five.Piezo(3);
board.repl.inject({
piezo: piezo
});
piezo.play({
song: [
["G5", 1 / 2],
[null, 1 / 2],
["G5", 1 / 2],
[null, ... |
import datetime as dt
from time import sleep
from airflow import DAG
from airflow.operators.python_operator import PythonOperator
import pandas as pd
url = "https://archive.ics.uci.edu/ml/machine-learning-databases/00382/c2k_data_comma.csv"
def download():
print('download')
df = pd.read_csv(url)
df.to_cs... |
import mongoose from "mongoose";
const RateReview = new mongoose.Schema(
{
rate: {
type: String,
default: 0,
},
starImg: {
type: String,
},
review: {
type: String,
},
customer: {
type: String,
},
},
{ timestamps: true }
);
const imagePath = new mongoo... |
// modules are defined as an array
// [ module function, map of requires ]
//
// map of requires is short require name -> numeric require
//
// anything defined in a previous bundle is accessed via the
// orig method which is the require for previous bundles
(function (modules, entry, mainEntry, parcelRequireName, glo... |
/*!
* OpenUI5
* (c) Copyright 2009-2020 SAP SE or an SAP affiliate company.
* Licensed under the Apache License, Version 2.0 - see LICENSE.txt.
*/
sap.ui.define(["sap/ui/test/actions/Action"],function(t){"use strict";var e=t.extend("sap.ui.test.actions.Drop",{metadata:{properties:{aggregationName:"string",before:"b... |
../../_bignumber.js@9.0.0@bignumber.js |
import setuptools
# If you want a package (something with an __init__.py) to wind up installed, you need to list it
# here.
packages = [
"zendesk"
]
# Pull requirements from requirements.txt file.
requirements_lines = [line.strip() for line in open('requirements.txt').readlines()]
install_requires = list(filter(N... |
console.log('m3는 인자값을 가지는 함수를 exports 하는 모듈');
var t = module.filename
module.exports = (score) => {
return {
'sum': () => score.kor + score.eng,
'avg': () => (score.kor + score.eng) / 2
};
}; |
import React from "react";
import styled from "styled-components";
import { withRouter } from 'react-router-dom';
import XSvg from "../../Design/SVGs/XSvg";
import {Popup} from "./PopUp";
const PopUpBaseContainer = styled.div`
min-width: 35vw;
min-height: 20vh;
background-color: rgba(211,211,211,1);
display: f... |
$(document).ready(function () {
$("#delete-button").click(function(){
$('#confirmation-modal').modal('show');
});
$("#sure-confirmation-button").click(function(){
$('#security-code-modal').modal('show');
});
$("#submit-security-code-button").click(function(){
$.ajax({
type: "POST",
... |
from typing import List
from app.schemas import Field, Deck
from pydantic import BaseModel
class FileProps(BaseModel):
headers: List[Field] = [Field.text, Field.answer]
default_deck: Deck
delimeter: str = "\t"
|
#!/usr/bin/env python
import rospy
import pdb
import numpy as np
import tf
import os
import time
import sys, select, termios, tty
from race.msg import drive_param
from ackermann_msgs.msg import AckermannDriveStamped, AckermannDrive
from std_msgs.msg import Header
pub = rospy.Publisher("vesc/high_level/ackermann_cmd_m... |
/* PrismJS 1.21.0
https://prismjs.com/download.html#themes=prism&languages=markup&plugins=line-highlight+toolbar+copy-to-clipboard */
var _self="undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{},Prism=function(u){var c=/\blang(?:uage)?-([\w-]+)\b/i,n=0,M={... |
/*
* If not stated otherwise in this file or this component's LICENSE file the
* following copyright and licenses apply:
*
* Copyright 2020 RDK Management
*
* 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 cop... |
const express = require('express');
const bodyParser = require('body-parser');
const app = express();
const clientsRoute = require('./server/routes/clientsRoute')
app.use(bodyParser.json({limit: '50mb'}));
app.use('/client', express.static('client/'));
app.all('*', function(req, res, next) {
res.header("Access-Cont... |
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... |
import agent from 'superagent';
const moltin = require('moltin')({
publicId: process.env.MOLTIN_CLIENTID,
secretKey: process.env.MOLTIN_CLIENTSECRET,
});
module.exports = [
{
method: 'POST',
path: '/api/login',
handler: (request, reply) => {
moltin.Authenticate(() => { // eslint-disable-line
... |
/*!
* ${copyright}
*/
sap.ui.define([
"sap/ui/test/Opa5",
"sap/ui/mdc/integration/testlibrary/filterfield/Actions",
"sap/ui/mdc/integration/testlibrary/filterfield/Assertions"
], function(
Opa5,
FilterFieldActions,
FilterFieldAssertions
) {
"use strict";
Opa5.extendConfig({
testLibBase: {
mdcTestLibrar... |
// const webpack = require('webpack');
const merge = require('webpack-merge');
const baseConfig = require('./base.config.js');
module.exports = merge(baseConfig, {
mode: 'production',
output: {
filename: 'click-and-drag.min.js',
},
});
|
'use strict';
var asides = document.querySelectorAll('aside');
var recommendedUnit = '1.5';
var recommendedReplacements = [];
var heatingType = '',
fullSysOrReplace = '';
var d = document,
unitName = d.querySelector('.unit-name'),
unitTonnage = d.querySelector('.unit-tonnage'),
unitSeer = d.querySele... |
"use strict";
import {Obj} from "./object";
class MyObj {
constructor() {
}
}
describe("Object Utilities Tests", ()=> {
it("should transform Object to Query String", ()=> {
expect(Obj.objectToQuery({name: 'test', value: 'foo'})).toBe("name=test&value=foo");
});
it("should transform Query S... |
define(["require", "exports", "../../../Styling"], function (require, exports, Styling_1) {
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var GlobalClassNames = {
root: 'ms-PlainCard-root'
};
function getStyles(props) {
var theme = props.theme, c... |
import { put, delay } from "redux-saga/effects";
import uuid from "uuid/dist/v4";
import { doSetNotification, doRemoveNotification } from "../actions/notifications";
const id = uuid();
const timeout = 5000;
function* handleNotification(action) {
const { payload: { message, alert } } = action;
yield put(doSetN... |
import numpy as np
import rl_utils
class Arch(object):
def __init__(self, gt_func=None):
self.gt_func = gt_func
def run_episode(self, env, policy, val_func, model, recurrent_steps, use_timestep, add_padding=True):
if self.gt_func is None:
self.gt_func = env.lander.get_state_agent5
... |
# SPDX-FileCopyrightText: Copyright (c) 2021-2022, NVIDIA CORPORATION &
# AFFILIATES. All rights reserved. SPDX-License-Identifier:
# Apache-2.0
#
# 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 ... |
# -*- coding: utf-8 -*-
"""
Created on Mon Apr 22 11:31:13 2013
Copyright (c) 2013-2014, CEA/DSV/I2BM/Neurospin. All rights reserved.
@author: Tommy Löfstedt and Edouard Duchesnay
@email: tommy.loefstedt@cea.fr, edouard.duchesnay@cea.fr
@license: BSD 3-clause.
"""
from . import dice5
__all__ = ['dice5']
|
import React from 'react'
import { TimelineHeadersConsumer } from './HeadersContext'
import PropTypes from 'prop-types'
import SidebarHeader from './SidebarHeader'
import { RIGHT_VARIANT, LEFT_VARIANT } from './constants'
class TimelineHeaders extends React.PureComponent {
static propTypes = {
registerScroll: Pro... |
export const VERSION = "6.25.0";
|
var MisfitAPI = require('./lib/misfitapi');
module.exports = MisfitAPI; |
import ApolloClient from 'apollo-boost';
import gql from 'graphql-tag';
const client = new ApolloClient();
const query = gql`
query {
posts {
title
author {
firstName
}
}
}
`;
const body = document.body;
client.query({ query }).then((results) => {
results.data.posts.forEach( (p... |
var createError = require('http-errors');
var express = require('express');
var path = require('path');
var cookieParser = require('cookie-parser');
var logger = require('morgan');
var indexRouter = require('./routes/index');
var usersRouter = require('./routes/users');
var app = express();
//Set up mongoose connect... |
''' Handling the data io '''
from torchvision import transforms, datasets
import numpy as np
import zipfile
from io import open
import glob
from PIL import Image, ImageOps
import os
import string
# Read data
def extractZipFiles(zip_file, extract_to):
''' Extract from zip '''
with zipfile.ZipFile(zip_file, ... |
const statuses = { 3: 'sync', 4: 'seal' };
module.exports = {
statuses
};
|
import {each, callback as call, sign, valueOrDefault} from 'chart.js/helpers';
import {panFunctions, updateRange, zoomFunctions} from './scale.types';
import {getState} from './state';
import {directionEnabled, getEnabledScalesByPoint} from './utils';
function shouldUpdateScaleLimits(scale, originalScaleLimits, update... |
"""
My Data My Consent - Developer API
Unleashing the power of data consent by establishing trust. The Platform Core Developer API defines a set of capabilities that can be used to request, issue, manage and update data, documents and credentials by organizations. The API can be used to request, manage and upd... |
import os
import os.path
import getpass
import click
import pandas as pd
import sys
from fire import uuid
import fire.cli
from fire.cli.niv import (
ARKDEF_FILOVERSIGT,
ARKDEF_NYETABLEREDE_PUNKTER,
ARKDEF_SAG,
niv,
skriv_ark,
bekræft,
)
from fire.api.model import (
Sag,
Sagsinfo,
)
... |
const express = require('express')
const router = express.Router()
router.use((req, res, next) => {
const init = Date.now()
next()
console.log(`Time = ${Date.now() - init} ms.`)
})
router.get('/products/:id', (req, res) => {
res.json({
id: req.params.id,
name: 'Pen'
})
})
router.get('/clients/:id/:... |
'use strict;'
document.addEventListener("DOMContentLoaded", function(event) {
window.addEventListener("message", function(event) {
if (event.data.rpcId !== "0") {
return;
}
if (event.data.error) {
console.log("ERROR: " + event.data.error);
return;
}
var elt = document.getElementById("offer-iframe");... |
/* */
(function(process) {
var assert = require('assert');
var path = require('path');
var Q = require('q');
var util = require('./util');
var spawn = require('child_process').spawn;
var ReadFileCache = require('./cache').ReadFileCache;
var grepP = require('./grep');
var glob = require('glob');
var e... |
""" implementation of https://arxiv.org/abs/1911.11134 """
import numpy as np
import torch
import torch.distributed as dist
import torch.nn as nn
from rigl_torch.util import get_W
class IndexMaskHook:
def __init__(self, layer, scheduler):
self.layer = layer
self.scheduler = scheduler
sel... |
//========== HOVER ============
$(document).on("mouseenter", ".stars1", function() {
$(this).addClass("star-hov")
})
$(document).on("mouseenter", ".stars2", function() {
$(this).prev().addClass("star-hov")
$(this).addClass("star-hov")
})
$(document).on("mouseenter", ".stars3", function() {
$(this).prev().pre... |
import m from 'mithril';
import _ from 'underscore';
import h from '../h';
import projectCard from './project-card';
const projectRow = {
view: function({attrs}) {
const collection = attrs.collection,
title = attrs.title || collection.title,
ref = attrs.ref,
showFriends ... |
(function() {
"use strict";
angular.module("jwtWebApp")
.factory("bookService",
[
"$http", "$q", function($http, $q) {
debugger;
function getBooks() {
var deferred = $q.defer();
$http.get("/api/books").
... |
# -*- coding: utf-8 -*-
import scrapy
import json
from locations.items import GeojsonPointItem
URL = 'https://www.brookdale.com/bin/brookdale/community-search?care_type_category=resident&loc=&finrpt=&state='
US_STATES = (
"AL", "AZ", "AR", "CA", "CO", "CT", "DE", "FL", "GA",
"ID", "IL", "IN", "IA", "KS"... |
import BaseMock from "ember-caluma/mirage-graphql/mocks/base";
import { register } from "ember-caluma/mirage-graphql";
export default class extends BaseMock {
@register("Case")
handleCase({ __typename }) {
return { __typename };
}
}
|
# coding: utf-8
"""
Copyright 2016 SmartBear Software
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 applica... |
import {changeTileVersion} from '../../../src/leaflet/control/ChangeTileVersion';
import {tiledMapLayer} from '../../../src/leaflet/mapping/TiledMapLayer';
var url = GlobeParameter.ChinaProvincesURL;
describe('leaflet_ChangeTileVersion', () => {
var originalTimeout;
var testDiv, map, tileVersion;
beforeAll... |
import { combineReducers } from 'redux';
import { forcastReducer as forcast } from '../reducer';
export const rootReducer = combineReducers({
forcast
});
|
# Copyright (c) 2020 PaddlePaddle 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 required by appli... |
const defaultTheme = require("tailwindcss/defaultTheme");
const plugin = require("tailwindcss/plugin");
const Color = require("color");
module.exports = {
purge: [
"./vendor/laravel/framework/src/Illuminate/Pagination/resources/views/*.blade.php",
"./storage/framework/views/*.php",
"./resou... |
from setuptools import setup
setup(
name='django-ubigeo',
version='0.0.1',
description='Ubigeo models, forms and views for Django',
author='Hans Roman',
author_email='hans@roman.pe',
url='http://github.com/snahor/django-ubigeo',
classifiers=[
'Environment :: Web Environment',
... |
const Web3 = require('web3');
const TruffleContract = require('truffle-contract');
const contractAbi = require('./build/contracts/Profile.json');
const enviroment = require('./environment');
var web3 = new Web3(new Web3.providers.WebsocketProvider(enviroment.web3Provider_ws, {
headers: {
Origin: enviroment... |
define({
"licenseError": {
"message": "Akun Anda tidak dilisensikan untuk menggunakan Aplikasi yang Dapat Dikonfigurasi yang bukan bersifat publik. Harap minta administrator organisasi Anda untuk menetapkan Anda jenis pengguna yang menyertakan lisensi Essential App atau add-on Essential App.",
"title": "Tidak... |
# @copyright@
# Copyright (c) 2006 - 2019 Teradata
# All rights reserved. Stacki(r) v5.x stacki.com
# https://github.com/Teradata/stacki/blob/master/LICENSE.txt
# @copyright@
import json
import signal
import zmq
import pprint
import stack.mq
import stack.commands.sync.host
class Subscriber(stack.mq.Subscriber):
def... |
!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?n(exports,require("@angular/common"),require("@angular/core"),require("@angularlicious/foundation")):"function"==typeof define&&define.amd?define("@angularlicious/core",["exports","@angular/common","@angular/core","@angularlicious/foundation"],n):n((e.... |
from lib.types import IStdin, IStdout
def hello(stdin: IStdin, stdout: IStdout):
stdout.write("Hello!\n")
|
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for license information.
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may ... |
import { debounce } from '@/utils'
export default {
mounted() {
this.__resizeHanlder = debounce(() => {
if (this.chart) {
this.chart.resize()
}
}, 100)
window.addEventListener('resize', this.__resizeHanlder)
},
beforeDestroy() {
window.removeEventListener('resize', this.__resi... |
function github_api_adapter (text){
var url = 'https://api.github.com/search/repositories?q='+text+'&sort=stars&order=desc';
var articles= JSON.parse(UrlFetchApp.fetch(url))['items']
Logger.log(articles)
var adapted_gh_obj=[]
for (var i in articles){
var temp={};
temp['title']= articles[i]['na... |
import styled from "styled-components";
import {borderRadius, colors, size, typography} from "./variables";
const Card = styled.div`
background-color: white;
box-shadow: rgba(0, 0, 0, 0.2) 0 1px 2px 0;
padding: ${size.small};
border: 0 solid rgba(123, 123, 123, 0.498039);
border-radius: ${borderRadius};
fo... |
export class Firebase {
}; |
import UU5 from "uu5g04";
export const About = {
about: {
cs: [
`<uu5string/>uuVideoLibrary je online aplikace pro sdílení odkazů na vzdělávací videa mezi studenty Unicorn University. Aplikace umožňuje studentům zveřejňovat odkazy na vzdělávací videa, sdílet podrobnosti o videu, upravovat podrobnosti nebo ... |
const bcrypt = require('bcryptjs');
const jwt = require('jsonwebtoken');
const auth = {
signup: async (parent, args, ctx) => {
const password = await bcrypt.hash(args.password, 10);
const user = await ctx.db.mutation.createUser(
{
data: { ...args, password }
},
` { id } `
);
... |
"use strict";(self.webpackChunkdocs=self.webpackChunkdocs||[]).push([[9131],{42045:function(e,a,t){t.r(a),t.d(a,{_frontmatter:function(){return g},default:function(){return c}});var s,i=t(63366),n=(t(67294),t(64983)),o=t(43086),b=["components"],g={},l=(s="Preview",function(e){return console.warn("Component "+s+" was no... |
"use strict";
// renderer module
const {ipcRenderer} = require("electron");
const moment = require("moment");
const vsprintf = require("sprintf-js").vsprintf;
let newGameBtn = document.querySelector("button.new-game");
let startGameBtn = document.querySelector("button.start-game");
let elapsedTimeDiv = document.quer... |
import NavBar from "nav-bar";
var Panels = require("panels");
|
var assert = require("assert");
describe('absolution', function() {
var absolution;
it('should be successfully initialized', function() {
absolution = require('../index.js');
});
it('should pass through unrelated markup unaltered', function() {
assert.equal(absolution('<div><p>Hello <b>there</b></p></di... |
# Copyright © 2019 CAILLAUD Jean-Baptiste.
# Import the cosine and sine functions.
from math import cos, sin, sqrt, atan2, degrees, radians
class Vector2:
def __init__(self, x, y):
self.x = x
self.y = y
def __add__(self, other):
if isinstance(other, Vector2):
return Vect... |
'use strict';
Object.defineProperty(exports, '__esModule', {
value: true
});
var _constants = require('./constants');
var goldenScale = function goldenScale(fontSize) {
var scalar = arguments[1] === undefined ? 0 : arguments[1];
return fontSize * Math.pow(_constants.GOLDEN_RATIO, scalar);
};
exports.goldenSca... |
const namida = require('@tum-far/namida');
const TopicMuxer = require('./topicMuxer');
const TopicDemuxer = require('./topicDemuxer');
let _instance = null;
const SINGLETON_ENFORCER = Symbol();
class DeviceManager {
constructor(enforcer) {
if (enforcer !== SINGLETON_ENFORCER) {
throw new Error('Use ' + th... |
import {Router} from 'express'
import chalk from 'chalk'
const router = Router()
router.get('/hello', (req, res) => {
console.log(chalk.red`You find a secret location!`)
res.send('You find a secret route!')
})
export default router
|
import React from 'react';
import './HomeSider.css';
import { Layout, Menu } from 'antd';
const { Header, Content, Sider } = Layout;
export default function HomeSider(props) {
var defaultSelectedKeys = [];
if (props.defaultSelectedKey !== undefined) {
defaultSelectedKeys = [props.defaultSelectedKey];
}
... |
//全局变量
var currentCateId = -1; //当前分类id
var currentCateTable = "AllCate"; //当前分类表
var currentTaskId = -1; //当前任务 id
initAll();
function initAll() {
// localStorage.clear();
initDataBase(); //初始化数据表
initCates(); //初始化分类
initModal(); //初始化模态框
$("#task-list").innerHTML = createTaskList(queryAllTasks(... |
const discord = require('discord.js');
const bot = new discord.Client();
const prefix = "!";
const maxrank = "210";
const groupId = "3152407";
const roblox = require('roblox-js');
bot.login(process.env.token);
bot.commands = new discord.Collection()
require('fs').readdir("./commands/", (err, files) => {
console.log(... |
import numpy as np
def koppen_classification(precip, avgtemp, lat):
"""
# codigo baseado em:
# https://github.com/jgodwinWX/koppen/blob/master/koppen.py
# https://www.nature.com/articles/sdata2018214
# https://en.wikipedia.org/wiki/K%C3%B6ppen_climate_classification
import koppen
... |
const fs = require('fs')
const path = require('path')
const root = `${__dirname}/../..`
const components = fs
.readFileSync(path.join(root, 'components.txt'), 'utf8')
.split('\n')
.filter(Boolean)
const sections = components
.map(f => {
const fileName = path.join(root, f, 'test.html')
let htmlText
... |
import React, { Component } from 'react'
import {
StyleSheet,
Text,
View,
TouchableOpacity
} from 'react-native'
import Icon from '../../components/Icon'
export default class App extends Component<{}> {
constructor(props) {
super(props)
this.state = {
hoverState: false
}
}
render() {... |
/****************************************************************************
Copyright (c) 2010-2012 cocos2d-x.org
Copyright (c) 2008-2010 Ricardo Quesada
Copyright (c) 2011 Zynga Inc.
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software an... |
import { complement } from 'ramda';
import * as RA from '../src';
import MAX_SAFE_INTEGER from '../src/internal/polyfills/Number.MAX_SAFE_INTEGER';
import MIN_SAFE_INTEGER from '../src/internal/polyfills/Number.MIN_SAFE_INTEGER';
import eq from './shared/eq';
import polyfill from '../src/internal/polyfills/Number.isIn... |
const config = require("config");
module.exports = function () {
if(!config.get("jwtPrivateKey")){
throw new Error("Error: jwtPrivateKey is not defined.");
}
}; |
define([], function () {
return {
"portalUrl": "http://localhost:8081/"
}
});
|
/**
* First we will load all of this project's JavaScript dependencies which
* includes Vue and other libraries. It is a great starting point when
* building robust, powerful web applications using Vue and Laravel.
// */
import Vue from 'vue';
import VeeValidate from 'vee-validate';
Vue.use(VeeValidate);
require... |
const HttpError = require('../models/HttpError');
const jwt = require('jsonwebtoken');
const auth = (req, res, next) => {
if(req.method === "OPTIONS"){
return next();
}
let token;
try {
token = req.headers.authorization.split(' ')[1]; //Authorization bearer token
if (!token) {
... |
function replace(num) {
$("#cSharp").hide();
$("#cSharpRuby").hide();
$("#python").hide();
$("#codeProgram").hide();
$("#pythonRuby").hide();
$("#ruby").hide();
if (num===1){
$("#cSharp").show();
}else if (num===2) {
$("#cSharpRuby").show();
}else if (num===3) {
$("#python").show();
}el... |
// executar index.html
let res = []
let lista = document.getElementById('repos')
let usuario = document.getElementsByName('user')[0].value
function buscar() {
try {
axios.get(`https://api.github.com/users/${usuario}/repos`)
.then(function(response){
res = response.data.map(item => it... |
'use strict'
module.exports = function(shariff) {
var url = encodeURIComponent(shariff.getURL())
var title = shariff.getTitle()
return {
popup: false,
shareText: {
'bg': 'cподеляне',
'cs': 'sdílet',
'da': 'del',
'de': 'teilen',
'en': 'share',
'es': 'compartir',
... |
# -*- coding: utf-8 -*-
"""
.. automodule:: gkeepapi
:members:
:inherited-members:
.. moduleauthor:: Kai <z@kwi.li>
"""
import datetime
import logging
import time
import random
import enum
import six
from . import exception
DEBUG = False
logger = logging.getLogger(__name__)
class NodeType(enum.Enum):
""... |
describe('@alias tag', () => {
const docSet = jasmine.getDocSetFromFile('test/fixtures/alias.js');
// there are two doclets with longname myObject, we want the second one
const myObject = docSet.getByLongname('myObject')[1];
it('adds an "alias" property to the doclet with the tag\'s value', () => {
... |
var should = require('should')
var strava = require('../')
var testHelper = require('./_helper')
var _sampleSegmentEffort
describe.skip('segmentEfforts_test', function () {
before(function (done) {
testHelper.getSampleSegmentEffort(function (err, payload) {
_sampleSegmentEffort = payload
done()
... |
(function () {
'use strict';
angular.module('embryo.components.openlayer')
/**
* The map-mouse-position directive will add a current-mouse position panel the map.
*/
.directive('openlayerMousePosition', openlayerMousePosition);
openlayerMousePosition.$inject = ['OpenlayerService'];
... |
from .allow_count import AllowCount
from .always_ignore import AlwaysIgnore
from .always_raise import AlwaysRaise
from .ignore_asserts import IgnoreAsserts
|
const express = require("express");
const mongoose = require("mongoose");
const router = require("express").Router();
const Workout = require("../models/Workout");
router.get("/api/workouts", (req, res) => {
Workout.find({})
.then((dbWorkout) => {
res.json(dbWorkout);
})
.catch((err) => {
res... |
import React from 'react';
import ReactDOM from 'react-dom';
import PropTypes from 'prop-types';
/**
* This is your boilerplate component
* @description Here are some words to better describe what this does. Which is nothing.
*/
class Sample extends React.Component {
constructor(props) {
super(props);
... |
from time import time
def timeit(method):
"""decorator function to measure execution time"""
def timed(*args, **kw):
ts = time()
result = method(*args, **kw)
te = time()
print(f"Execution time: {(te - ts):2.2f} sec")
return result
return timed |
import React from 'react';
const VideoListItem = ({video,onVideoSelect}) => {
const imageUrl = video.snippet.thumbnails.default.url;
return(
<li onClick={() => onVideoSelect(video)} className="list-group-item">
<div className="video-list-media">
<div className="media-l... |
const parse = require('./parse');
test('return null for empty string', () => {
expect(parse('')).toBe(null);
});
test('throws error for invalid string', () => {
expect(() => parse()).toThrow(TypeError);
expect(() => parse('vCV0CHjTyl')).toThrow(Error);
expect(() => parse('Baerer vCV0CHjTyl')).toThrow(Error);
... |
import React from 'react';
import Select from 'react-select'
import {Dialog,DialogTitle,DialogContent,DialogActions} from '@material-ui/core';
import {crudAsesor} from "../../../../Services/Master/AsessorService";
import {showErrorMessage, showSuccessMessage} from "../../../../Components/Alerts";
import {pengujiTypeOp... |