text stringlengths 7 3.69M |
|---|
import React from 'react';
import { Provider as ReduxProvider } from 'react-redux';
import configureStore from './state/store';
import Views from './views';
import './main.scss'
const reduxStore = configureStore(window.REDUX_INITIAL_STATE); // for SSR
function Main() {
return (
<ReduxProvider store = {reduxStor... |
//定义多个属性 Object.defineProperties()函数
var book={};
Object.defineProperties(book,{
_yaer:{
writable:true,
value:2004
},
edition:{
writable:true,
value:1
},
year:{
get:function(){
return this._yaer;
},
set:function(newValue){
... |
$(document).ready(function () {
$(".attachment a").each(function () {
var text = $(this).text();
var symbol = "\\";
$(this).text(text.substring(text.lastIndexOf(symbol) +1)).append("<i class='fa fa-file-word-o'></i>");
/* $(this).text($(this).text().substring(0, 497) + "...");*/
... |
import registerUser from './register-user'
import authenticateUser from './authenticate-user'
import isUserLoggedIn from './is-user-logged-in'
import logUserOut from './log-user-out'
import retrieveUser from './retrieve-user'
import search from './search'
import registerDog from './register-dog'
import retrieveFavorite... |
import React from "react";
import PropTypes from "prop-types";
import preloader from "image-preloader";
import { cssTimeToMs } from "../../util";
import defaults from "../../defaults";
import VisibilitySensor from "react-visibility-sensor";
export class ImageLoader extends React.Component {
static propTypes = {
... |
/////////////// Geoserver中发布的 House 信息 ///////////////
var House = new ol.layer.Image({
source:new ol.source.ImageWMS({
// http://localhost:8080/geoserver/WebGIS/wms
url:'http://localhost:8080/geoserver/GIS/wms',
params:{'LAYE... |
import React from 'react';
import {
Button,
Form,
Grid,
Header,
Image,
Message,
Segment,
Checkbox,
Confirm
} from 'semantic-ui-react';
import { GraphQLClient } from 'graphql-request';
class SignUpForm extends React.Component {
constructor(props) {
super(props);
this.state = {
ema... |
require('./header');
require('./mainbar');
require('./form'); |
import React, {useState,useEffect} from 'react';
import { Audio } from "expo-av";
import { FlatList, View, StyleSheet, TouchableOpacity } from 'react-native';
const defaultSound = [
require('../../assets/DefaultAudio/cymbal.wav'),
require('../../assets/DefaultAudio/daibyoshi.wav'),
require('../../as... |
import { firebaseRef, checkLogin } from './auth';
const date = new Date();
const dateString = `${date.getDate()}-${date.getMonth()+1}-${date.getYear()+1900}`;
const dateStringYest = `${date.getDate()}-${date.getMonth()+1}-${date.getYear()+1900}`;
// var ref = new Firebase("https://<YOUR-FIREBASE-APP>.firebaseio.com");... |
const { expect } = require('chai')
const nullAddress = '0x0000000000000000000000000000000000000000'
describe('Gift contract', function () {
let gift, admin1, hippyKing1, hippyKing2, user1
before(async () => {
[admin1, hippyKing1, hippyKing2, user1] = await ethers.getSigners()
const Gift = await ethers.... |
// We are adding a function called Ctrl1
// to the module we got in the line above
export default function loginController($scope, $window, Store, $http, $routeParams, $base64, restService) {
// $scope.text = "Zurück zum login";
//$scope.folders = restService.getFolders();
$scope.login = () => {
$... |
// const mongoose = require("mongoose")
// const schema = new mongoose.schema({
// firstName:{type:String},
// children: [{type: Schema.Types.ObjectId, ref: 'User'}],
// partner: {type: Schema.Types.ObjectId, ref: 'Partner'}
// });
// const model = mongoose.model("Parent" , schema);
// module.exports = mod... |
import Vue from 'vue'
import Router from 'vue-router'
import movie from '../pages/movie';
import book from '../pages/book';
import boardcast from '../pages/boardcast';
import group from '../pages/group';
import index from '../pages/index';
import register from '../pages/register';
import login from '../pages/login';
i... |
var express = require('express');
var router = express.Router();
var userService = require('../../services/user');
/* CREATE USER */
router.post('/', userService.createUser);
module.exports = router; |
$('#myModal').on('hide.bs.modal', function () {
$(this).removeData('bs.modal');
let toopit = $('#tooltip');
toopit.css("display", "none");
});
function registerin() {
let formData = new FormData();
let img_file = document.getElementById("ipc");
let fileObj = img_file.files[0];
let uname = $... |
const gulp = require('gulp');
const sass = require('gulp-sass');
const browserSync = require('browser-sync').create();
const webpack = require('webpack');
const webpackStream = require('webpack-stream');
const wait = require('gulp-wait2');
const eslint = require('gulp-eslint');... |
/**
* Example result:
* {
* type: 'number',
* value: '6',
* startIndex: 8
* endIndex: 9
* }
*/
export const getSymbol = (program, index, context) => {
}
|
import React, { Component } from 'react';
import './../App.css';
import $ from 'jquery';
import Slider from 'react-slick';
export default class Slickslider extends Component {
render() {
const settings = {
dots: true,
infinite: true,
speed: 500,
slidesT... |
import {fbDatabase} from "fbase";
class FirebaseDatabase {
saveGoods(userId, item) {
fbDatabase.ref(`${userId}/goods/${item.id}`).set(item);
}
deleteGoods(userId, item) {
console.log(1);
fbDatabase.ref(`${userId}/goods/${item.id}`).remove();
}
syncGoods(userId, onUpdate){
const ref = fbData... |
const express = require('express');
const router = express.Router();
const aws = require('aws-sdk');
const pool = require('../database');
const { isLoggedIn, isNotLoggedIn } = require('../lib/auth');
router.get('/upload', isLoggedIn, (req, res) => {
res.render('files/upload');
});
router.get('/uploads/:ext',... |
const { DataTypes } = require('sequelize');
module.exports = (sequelize) => {
sequelize.define('order', {
total: {
type: DataTypes.INTEGER,
//allowNull: false,
},
state: {
type: DataTypes.ENUM('cart', 'created', 'processing', 'canceled', 'completed'),
allowNull: fals... |
export const serverUrl = 'http://192.168.0.108:3000/'; |
var ColorPicker = (function() {
var WIDTH = '100px';
var HEIGHT = '20px';
return function(onValueChanged) {
var controlDescriptions = COLORS.map(function(colorEntry) {
return {
title: colorEntry.name,
color: Color.toCss(colorEntry.value),
width: WIDTH,
height: HEIGHT,
onClick: function() {
... |
//
//
// var init = function() {
// chance();
// }
document.querySelector('#showContent').addEventListener('click', function() {
var chance = Math.floor(Math.random() * 9) + 1;
var chanceDOM = document.querySelector('.chance');
// chanceDOM.style.display = 'block';
chanceDOM.src = 'img/chance-' +... |
const Joi = require('joi')
module.exports.create = function createMessage(req, res, next) {
let schema = Joi.object().keys({
userName: Joi.string().regex(/^[a-zA-Z0-9]+$/g).required().description('user name'),
body: Joi.string().min(200).max(65535).required().description('message body')
})
let body = J... |
../dist/zabo.js |
import React from "react";
import { Slide, Text } from "spectacle";
const notes = `
`;
export default function() {
return (
<Slide bgColor="primary" textAlign="left" notes={notes}>
<Text bold textColor="dark">
What happens when React needs to rerender
</Text>
<div style={{ marginTop:... |
const mongoose = require('mongoose'),
bcrypt = require('bcrypt');
var UserSchema = new mongoose.Schema({
username: {
type: String,
unique: true,
},
email: {
type: String,
unique: true,
},
isAdmin:{
type:Boolean,
def... |
var assert = require('assert');
var nodeunit = require('nodeunit');
var format = require('url').format;
var parse = require('url').parse;
var resolve = require('url').resolve;
var resolveObject = require('url').resolveObject;
/**
* nodeunit test cases
*/
module.exports.testObject = function(test) {
console.log("--... |
import React, {Component} from 'react';
import * as d3 from "d3";
import * as d3scale from "d3-scale";
class RadialBarChart extends Component {
constructor(props) {
super(props);
this.state = {
width: (window.innerWidth > 500 ? 500 : window.innerWidth)
}
this.chartDiv... |
/**
* Created by Max on 4/26/2018.
*/
let mongoose = require('mongoose'),
Schema = mongoose.Schema;
let messageSchema = new Schema({
userName: {type: String, required: true},
message: {type: String, required: true},
timeStamp: {type: Number, required: true},
likes: {type: Number},
favorites... |
import VueFetch, { $fetch } from '../../plugins/fetch'
export function getCategories() {
return $fetch('category/')
.then(res => res)
.catch(err => {
console.log(err);
throw err;
});
}
export function getSubcategories() {
return $fetch('subcategory/')
.then(res => res)
.cat... |
function FindWord(text) {
let builder = "";
let remaining = text;
let result = FindWord2(builder, remaining);
return result;
}
function CheckIfExists(text) {
if (text.indexOf("car") > -1) {
console.log("Text found in", text);
return true;
}
return false;
}
function FindWord2(builder, remaining) {
... |
////Como exportar de um módulo Node para outro arquivo (forma mais comum)
module.exports = {
bomDia: 'Bom dia',
boaNoite(){
return 'Boa noite'
}
} |
const Manager = require("./lib/Manager");
const Engineer = require("./lib/Engineer");
const Intern = require("./lib/Intern");
const inquirer = require("inquirer");
const path = require("path");
const fs = require("fs");
const OUTPUT_DIR = path.resolve(__dirname, "output")
const outputPath = path.join(OUTPUT_DIR, "team... |
var globals________vars____8js__8js_8js =
[
[ "globals____vars__8js_8js", "globals________vars____8js__8js_8js.html#a3855473d838853dc775c812564d7c5ca", null ]
]; |
import React from 'react';
import api from '../utils/api';
function Card(props) {
console.log(props);
const handleSave = ()=>{
console.log(props.book)
const bookData ={
title:props.book.volumeInfo.title,
authors: props.book.volumeInfo.authors.join(', '),
description: props.book.volumeInfo.desc... |
//*************** Hello
import {SUCCESS, FAIL} from './src/redux/action/actionType';
import axios from 'axios';
import React, {useEffect} from 'react';
import {Text, View} from 'react-native';
var kk = SUCCESS + '_' + FAIL;
const HelloWorldApp = () => {
useEffect(() => {
try {
const users = axios.get('ht... |
import { Button, Grid, Typography } from "@material-ui/core";
import FormControl from "@material-ui/core/FormControl";
import IconButton from "@material-ui/core/IconButton";
import InputAdornment from "@material-ui/core/InputAdornment";
import InputLabel from "@material-ui/core/InputLabel";
import OutlinedInput from "@... |
/*
* Use this script to easily load a sprite file in a canvas and have it play as animation.
* Made by Christiaan de Die le Clercq, licensed under GPL v2 or higher.
*/
var canvas = document.getElementById("canvas");
var context = canvas.getContext("2d");
var image = new Image();
var imageWidth, imageHeight;
var num... |
var http=require('http');
var fs=require('fs');
var url=require('url');
http.createServer(function(request,response){
var pathname=url.parse(request.url).pathname;
console.log('Request for:'+pathname);
fs.readFile(pathname.substr(1),function(err,data){ //路径去掉第一个目录分隔符
if(err){
console.log... |
import { Router, browserHistory } from 'react-router';
import { ReduxAsyncConnect, asyncConnect, reducer as reduxAsyncConnect } from 'redux-connect'
import React from 'react'
import { hydrate } from 'react-dom'
import { createStore, combineReducers } from 'redux';
// 1. Connect your data, similar to react-redux @conne... |
/**
* Speed Component Module
* @module Speed/Component
* @requires react
* @requires prop-types
* @requires material-ui
* @requires react-amap
* @requires react-amap-plugin-heatmap
* @requires {@link module:Speed/Components/Echarts}
* @requires {@link module:Speed/Components/SpeedBoard}
*/
import React from '... |
var AM = new AssetManager();
//Basketball
AM.queueDownload("./img/basketball.png");
AM.queueDownload("./img/Bubble.png");
AM.queueDownload("./img/Bubble Pop.png");
AM.queueDownload("./img/Tennis Ball.png");
AM.queueDownload("./img/Bowling Ball.png");
var gameEngine;
var myManager;
AM.downloadAll(function () {
... |
const express = require("express");
const LimpController = require("../../Controllers/Sistema/LimpiezaHigiene");
const api = express.Router();
api.post("/agregar-LimpiezaHigiene", LimpController.guardarLimpieza);
api.get("/limpieza", LimpController.getLimpieza);
api.put("/updateLimpieza/:id", LimpController.updateLim... |
/**
* Copyright (c) Benjamin Ansbach - all rights reserved.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
'use strict';
const Abstract = require('./../Abstract');
const BC = require('@pascalcoin-sbx/common').BC;
const mipherAES =... |
import React, { useEffect, useState } from 'react'
import PropTypes from 'prop-types'
import { getStoryCharacters } from '../../../services/stories.service'
import CharacterCard from '../../characters/characters-card'
import Spinner from '../../spinner'
import NoContent from '../../no-content'
import { getThumbnailURL ... |
var searchData=
[
['back',['back',['../structbullet__t.html#ad0e6b6213a172f1d71e8738bb156e7ea',1,'bullet_t']]],
['back_5fbutton',['back_button',['../structgame__t.html#ac8452ffa9f2e211cbbf2b822914ca2cf',1,'game_t']]],
['background',['background',['../structgame__t.html#a69a7242ee147decd9b827b0c721a728c',1,'game_t... |
import React from "react";
import { Input, Label } from "semantic-ui-react";
import PropTypes from "prop-types";
import styles from "./RenderedField.module.scss";
export const RenderedInputField = ({ meta: { error, touched }, ...rest }) => (
<div className={styles.renderedFieldContainer}>
<Input {...rest} size="... |
import React from 'react';
import ReactDOM, { render } from 'react-dom';
import './index.css';
import registerServiceWorker from './registerServiceWorker';
import { BrowserRouter as Router, Switch, Route} from 'react-router-dom';
import Play from './pages/Play';
import Login from './pages/Login';
import Games from './p... |
function vector(x,y){
this.x = x;
this.y = y;
}
function add(v1,v2){
v1.x = v1.x + v2.x;
v1.y = v1.y + v2.y;
}
function sub(v1,v2){
v1.x = v1.x - v2.x;
v1.y = v1.y - v2.y
}
function mult(v1,v2){
v1.x = v1.x * v2.x;
v1.y = v1.y * v2.y
}
function div(v1,v2){
v1.x = v1.x / v2.x;
v1.y = v1.y / v2.y
}
function sca... |
/*!
* Start Bootstrap - New Age v5.0.1 (https://startbootstrap.com/template-overviews/new-age)
* Copyright 2013-2021 Start Bootstrap
* Licensed under MIT (https://github.com/BlackrockDigital/startbootstrap-new-age/blob/master/LICENSE)
*/
AOS.init(); |
var mongoose = require('../lib/mongoose');
var Schema = mongoose.Schema;
var User = require('./user').User;
var eventSchema = new Schema({
title: {
type : String,
max : 30,
required : true
},
details: {
type : String,
max : 500
},
cov... |
export filter from './filter'
export data from './data' |
var mergeTwoLists = function (l1, l2) {
function merge(left, right) {
if (!left) return right;
if (!right) return left;
if (left.val < right.val) {
left.next = merge(left.next, right);
return left;
} else {
right.next = merge(left, right.next);
return right;
}
}
return... |
import React, { useState, useEffect } from 'react'
import {
Checkbox,
Grid,
Header,
Icon,
Image,
Menu,
Segment,
Sidebar,
Button,
Container,
Popup,
} from 'semantic-ui-react'
import {estadoInicialComentario} from '../../estadosIniciales/estadoInicial-comentario';
import {agregarComentarios, obtener... |
function dosomething() {
if (confirm("do you want to proceed to youtube?") == true)
{window.open('https://www.youtube.com/watch?v=U66dciR-fCY')}
else {}
}
function MOWYPINW() {
if (confirm("do you want to proceed to youtube?") == true)
{window.open('http://www.huffingtonpost.com/2015/05/06/bsl-... |
import { getBeers } from "../../../utils/api.js";
import handleServerResponseOnLoadMore from "./ServerReponseOnLoadMore.js";
export default async ({ store, actionCreators }) => {
const { toggleLoading, handleError, handleDelete } = actionCreators;
try {
store.dispatch(toggleLoading(true));
const { search... |
let obj={
x:10,
y:20,
z:30
}
console.log(obj.x)
console.log(obj['y'])
//Update property
obj.x=100
obj.y=200
obj.z=300
console.log(obj)
let withString='x'
console.log(obj[withString]) |
const express = require("express");
const router = express.Router();
const Test = require("../models/test");
// Getting all
router.get("/", async (req, res) => {
try {
const testsBelongingToOwner = await Test.find({ owner: req.body.owner });
res.json(testsBelongingToOwner);
} catch (err) {
re... |
var NOTIFICATIONS_CENTER;
var NOTIFICATIONS_URL = buildUrlWithContextPath("notifications");
var LOGOUT_URL = buildUrlWithContextPath("logout");
$(function () {
setInterval(refreshNotifications, 2000);
});
function refreshNotifications() {
ajaxRefreshNotifications( function (notificationsCenter) {
NOTI... |
const modelProduct =require('../model/Products.js');
const bodyParser = require('body-parser');
const Product = require('../model/Products.js');
const session = require('express-session');
exports.findAll= (req, res) => {
var sess
sess=req.session;
if(sess.role!=1){
res.redirect("error")
return ... |
// ================================================================================
//
// Copyright: M.Nelson - technische Informatik
// Die Software darf unter den Bedingungen
// der APGL ( Affero Gnu Public Licence ) genutzt werden
//
// weblet: crm/person/picture
// ============... |
import React, { useState, useEffect } from "react";
import Update from "./Update";
function ToDo({ task, done, id, entries, setEntries }) {
const [show, setShow] = useState(false);
const [entry, setEntry] = useState(task);
const [color, setColor] = useState("darkblue");
useEffect(() => {
let updatedEntrie... |
import React, { useState } from 'react';
import ReactDOM from 'react-dom';
import 'react-responsive-modal/styles.css';
import { Modal } from 'react-responsive-modal';
const ModalEvent = (props) => {
console.log(props)
// console.log(props.modal_trigger_value)
const [open, setOpen] = useState(props.moda... |
/*
* @lc app=leetcode.cn id=135 lang=javascript
*
* [135] 分发糖果
*/
// @lc code=start
/**
* @param {number[]} ratings
* @return {number}
*/
var candy = function(ratings) {
const len = ratings.length;
let left = new Array(len).fill(0);
for (let i = 0; i < len; i++) {
if (i > 0 && ratings[i - 1]... |
import React from 'react'
import { StyleSheet, Text, View } from 'react-native';
import {Avatar} from "react-native-paper"
const AvatarComponent = ({size, source, avatarStyle}) => {
return (
<Avatar.Image size={size} source={{uri:source}} style={avatarStyle}/>
)
}
export default AvatarComponent
|
import React from "react";
import styled from "styled-components";
import { useDispatch, useSelector } from "react-redux";
import { actionsClientes } from "../../store/actions/clientes";
const AccordionWrapper = styled.div`
width: 80%;
display: flex;
justify-content: center;
ul {
li {
list-style-typ... |
import React from 'react';
import { Link } from 'react-router-dom';
import logo from '../../assets/images/logo.svg';
const Hero = () => {
return (
<section className="hero">
<div className="hero__header">
<img src={logo} alt="logo"></img>
</div>
<div className="hero__claim">
<di... |
// every and some will look at conditions and returning true and false
const users = [
{
name: "Mike",
isActive: true,
createdAt: 1601234512420,
socialProfiles: [
{
site: "twitter",
username: "mzetlow",
},
{
site: "facebook",
... |
import initialState from './initialState';
import * as Action from '../actions/types';
// Reducer for currentGame store section
export default function gameReducers(state = initialState.currentGame, action) {
switch(action.type) {
// The user starts a new game
case Action.START_GAME:
return {... |
function createRoleFromArray(roleNameArray) {
return new Promise((resolve, reject) => {
const saveRoles = roleNameArray.map((roleName) => {
const newRole = new Parse.Object("_Role");
newRole.set("name", roleName);
const aclObj = new Parse.ACL();
aclObj.setRoleWriteAccess("admin", true);
... |
var searchData=
[
['velocity',['velocity',['../class_m_d___r_encoder.html#a3f8a093ef5da74530daab77c066f5b18',1,'MD_REncoder']]]
];
|
import React from "react";
import { shallow, mount } from "enzyme";
import GuessSection from "./guess-section";
describe("Renders Guess Section", () => {
it("Shallow renders Guess Section", () => {
shallow(<GuessSection />);
});
});
|
import React, { useEffect } from 'react';
import { Link } from 'react-router-dom';
import { connect } from 'react-redux';
import styled from 'styled-components';
import { PropTypes } from 'prop-types';
import StyledSection from '../../components/LandSection';
import DarkOverlay from '../../components/Dark-overlay';
imp... |
const express = require('express');
const router = express.Router();
const cartController = require('../controllers/cartController');
// Hiển thị trang giỏ hàng
router.get('/', cartController.renderCart);
// Xoá sản phẩm trong giỏ hàng
router.get('/remove/:id', cartController.remove);
// Thêm số lượng 1 cho sản phẩ... |
var utils = require('utils')
var Message = require(__dirname+'/message')
var PrivateKey = require(__dirname+'/private_key')
class Signature {
constructor(message, privateKey) {
utils.assert(message instanceof Message)
utils.assert(privateKey instanceof PrivateKey)
// generate signature!
thro... |
var pdaInitID = [];
var pdaFinalID = [];
var pdaCheck = false;
var pdaId;
var pdaStack = '';
var testCaseList3 = []
function findAlledgesFromOneNodePDA(xmlDoc, id) {
var packagelist = [];
// var list = $(xmlDoc).find('transition').children()
var counter = 0;
while ($(xmlDoc).find('transition').children()[coun... |
// TODO:
// Variables
const PLAYER1 = 0;
const PLAYER2 = 1;
const OPEN_SPACE = -1;
const UNPLAYABLE = -2;
const PLAYER1_COLOR = "black";
const PLAYER2_COLOR = "white";
const PLAYER1_FILE = "img/pieceDark.png";
const PLAYER2_FILE = "img/pieceLight.png";
const PLAYER1_SHADE_FILE = "img/pieceDarkPossibleMove.png";
cons... |
// The number 3797 has an interesting property. Being prime itself, it is possible
// to continuously remove digits from left to right, and remain prime at each
// stage: 3797, 797, 97, and 7. Similarly we can work from right to
// left: 3797, 379, 37, and 3.
// Find the sum of the only eleven primes that are both tru... |
import { app } from '../../server.js'
import { RootController } from '../../controllers/root/index.js'
import {validationResult} from 'express-validator/check';
import _root_validator_ajouter_action from '../../validators/root/index.js'
import { sanitizeBody } from 'express-validator/filter';
app.get('/', (req, res) ... |
/*global ODSA */
"use strict";
// Remove slideshow
$(document).ready(function () {
var av_name = "BSTremoveCON";
var config = ODSA.UTILS.loadConfig({"av_name": av_name}),
interpret = config.interpreter, // get the interpreter
code = config.code; // get the code object
var av = ... |
module.exports = {
recno: 10,
order_no: 10,
code: 20,
description: 50,
actions: 10,
} |
const mongoose = require('mongoose');
// Direccion del cluster de la base de datos en MongoDB
mongoose.connect('mongodb+srv://albertopacheco23:becks2323@pachecocluster-gyot5.mongodb.net/Presupuesto', {
useCreateIndex: true,
useNewUrlParser: true,
useUnifiedTopology: true
})
.then(db =>console.log('La ba... |
const Jiji = require("jiji-js");
module.exports = {
title: "Home",
command: "$ npm install -g jiji-cli",
constructor: function (callback) {
/* before mount */
callback();
},
mounted: function () {
const controller = this;
const canvas = document.querySelector('canvas... |
"use strict";
let area = document.querySelector('.area')
let areaW, areaH, startPosX, startPosY;
document.querySelector('.area__toggle').addEventListener('mousedown', function (e) {
startPosX = e.screenX;
startPosY = e.screenY;
areaW = area.clientWidth;
areaH = area.clientHeight;
document.querySelect... |
const express = require("express");
const app = express();
const PORT = process.env.PORT || 5000;
const logger = require("morgan");
const mongoose = require("mongoose");
require("dotenv").config();
// middleware for logging incoming requests
app.use(logger("dev"));
// middleware for parse JSON data
app.use(express.jso... |
var express = require("express");
var router = express.Router();
let {users} = require("../db/arrayData")
//display registration form
router.get("/adduser", function(req, res, next) {
res.render("adduser", { response: "" });
});
router.post("/adduser", function(req, res, next) {
let user = {
id: users.lengt... |
var settings = {
gamename: "0",
version: "LD-0",
DEBUG: window.location.href.indexOf("DEBUG") > -1,
silent: window.location.href.indexOf("SILENT") > -1,
ghostv: 32,
Dmin: 0.5,
}
var beaten = {}
function getlevels() {
var ret = ["north", "south"]
if (beaten.north) {
ret.push("northwest")
ret.push("nort... |
angular
.module('Home')
.factory('HomeService', HomeService);
HomeService.$inject = [
'$log', '$http'
];
function HomeService (
$log, $http
) {
/// HomeService
var service =
{
/// constants
NEAR_ME_MOBIDULE : 0,
ALL_MOBIDULE : 1,
MY_MOBIDULE : 2,
DEFAULT_SEARCH_TY... |
/* eslint-env node */
'use strict';
module.exports = function (body) {
return '<html><title>test template</title><body>' + body + '</body></html>';
};
|
$(document).ready(function() {
/* Every time the window is scrolled ... */
$(window).scroll( function(){
/* Check the location of each desired element */
$('.hideme').each( function(i){
var bottom_of_object = $(this).offset().top + $(this).outerHeight();
var bottom_of_w... |
module.exports = {
options: {
connection: 'postgres://api_user:api_password@localhost:5432/api_development',
schema: ['myApp', 'myAppPrivate'], // Command line comma separated options must be entered as arrays
jwtSecret: 'myJwtSecret',
defaultRole: 'myapp_anonymous',
token: 'myApp.jwt_token',
},... |
'use strict';
angular.module('UserProfileApp', [
'ngRoute',
'ui.bootstrap'
]).
config(function($routeProvider,$locationProvider) {
$routeProvider.
otherwise({redirectTo: '/userList'});
$locationProvider.html5Mode(true);
}); |
import React, { useState, useEffect, memo } from 'react';
import { oneOfType, string, number, func } from 'prop-types';
import useModalView from '../hooks/useModalView';
import Popup from './Popup';
import PointPopupPhoto from './PointPopupPhoto';
import PointPopupLegend from './PointPopupLegend';
const propTypes = {... |
import React, {Component} from 'react';
import {
HashRouter as Router,
Route,
Switch
} from 'react-router-dom';
import Home from '../containers/Home'
export default class RouterMap extends Component {
render(){
return (
<div>
<Router>
<Switch>
... |
Ext.define('Admin.view.main.Main', {
extend: 'Ext.Container',
xtype: 'main',
requires: [
'Ext.button.Button',
'Ext.container.Container',
'Ext.list.Tree',
'Ext.toolbar.Fill'
],
controller: 'main',
viewModel: 'main',
cls: 'sencha-dash-viewport',
itemId: '... |
var isShowConsole = false;
$(".console-content").hide();
$("#aside-showhide-console").click(function () {
isShowConsole = !isShowConsole;
if (isShowConsole) {
$("#aside-showhide-console").attr("src", "images/triangle_up.png");
$(".console-content").show();
} else {
$("#aside-showhi... |
let bobSecretKey='f22811807eed1f2ae5b871e8dab4f5d879c708f0d0f0e4345b4eae799933d391fc4860560cec170d9e8866d889d54962ec9779bf57f7684a7a4cd0e1b28cef72';
let bobPublicKey='ak_2v7Dxo7cjwfgto3inBw9RBw7n2QXDavym4da5Ss3HMDEaDf3v9';
let bobClient=null;
let generalClient=null;
let bobKeyPairObj= null;
function generate... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.