text stringlengths 7 3.69M |
|---|
const mongoCollections = require("../database-utils/mongoCollections");
const users = mongoCollections.users;
async function usernameExists(username){
username = username.toLowerCase();
const loginCollection = await users();
return await loginCollection.findOne({username: username}) !== null;
}
module.... |
import React from "react";
import { Container } from "reactstrap";
import { Router, Route } from "react-router-dom";
import "./App.css";
import Topbar from "./components/Topbar";
import WrapExplore from "./containers/WrapExplore";
import history from "./components/browserHistory";
import { Provider } from "react-redux... |
const styles = {
body: {
backgroundColor: '#444444',
backgroundImage: 'url("/static/images/webpage-background.jpg")',
fontFamily: '"Trebuchet MS", Roboto, sans-serif',
color: '#dbbfff',
backgroundSize: 'cover',
},
h1: {
fontSize: '55px'
},
container:... |
import * as ACTIONS from '../actions'
const ACTION_HANDLERS = {
//loading
[ACTIONS.DICTIONARY_LOADING_STATE]: (state, action) => (
Object.assign({}, state, {
fetching: action.result
})
),
//列表
[ACTIONS.DICTIONARY_LIST_SET]: (state, action) => (
Object.assign({}, ... |
import React from 'react';
import Token from '../tokens/Token';
import { meta } from '@sparkpost/design-tokens';
import _ from 'lodash';
import color from 'color';
import { Box, Text } from '@sparkpost/matchbox';
function ColorDescription(props) {
const c = React.useMemo(() => _.find(meta, ['name', props.name]), [
... |
angular.module('mkaApp')
.controller('userController', function($http){
/**
* variables
*/
/**
* le contrôleur
* @type {angular.controller}
*/
var _this = this;
/**
* spécifie si le contrôleur a été initié
* @type {Boolean}
*/
this.initiated = false;
/**
* objet contenant les données de l'... |
$(document).ready(function() {
$('#submitSignin').click(function() {
var userID = $('#IDSignin').val();
var userPwd = $('#pwdSignin').val();
var userName = $('#nameSignin').val();
var userPwd_confirm = $('#pwd_confirmSignin').val();
if (((userID == "") || (userPwd == "")) || (userName == "")) {
alert("I... |
self.addEventListener('install', function(e) {
e.waitUntil(
caches.open('pomodoroClock').then(function(cache) {
return cache.addAll([
'/',
'/index.html',
'/assets/img/144.png',
'/assets/img/favicon.ico',
'/assets/DIGITALDREAM.... |
function renderDrawingArea(img) {
var totalMismatch = [100];
// Look ma, no jQuery!
//Clearing html make sure that there is no interferences
document.getElementsByClassName('literally')[0].innerHTML = "";
var lc = LC.init(
document.getElementsByClassName('literally')[0],
{imageURLPr... |
$(document).ready(function () {
// Affiche les figures 5 par 5
$(".trick").slice(0, 15).show();
$("#loadMore").on("click", function (
e
) {
e.preventDefault();
$(".trick:hidden").slice(0, 5).slideDown();
if ($(".trick:hidden").length === 0) {
$("#loadMore").te... |
baidu.frontia.social = baidu.frontia.social || {};
(function(namespace_) {
var Error = namespace_.error;
var SOCIAL_AUTH_URL_PREFIX = namespace_.DomainManager.getSocialDomain() + '/social/oauth/2.0/authorize';
var SOCAIL_GET_INFO_URL_PREFIX = namespace_.DomainManager.getSocialDomain() + '/social/api/2.0/user/i... |
var startGamebackground
var gameState
var startGamebutton, textbutton
var currentObjects = []
function preload(){
startGamebackground = loadImage("images/startgameback.png", 1000, 1000)
startGamebimg = loadAnimation("images/start.png","images/start.png", "images/blank.png","images/blank.png", "images/blank.png"... |
var express = require("express");
var app = express();
var bodyParser = require("body-parser");
app.use(bodyParser.urlencoded({extended: true}));
app.set("view engine","ejs");
var friends = ["A", "B", "C", "D"];
app.get("/",function(req,res){
res.render("home");
});
app.get("/friends",function(req,res){
res.rend... |
$(function () {
$("nav a").smoothScroll();
}); |
import React, { useEffect, useState } from 'react';
import PropTypes from 'prop-types';
import styled from 'styled-components';
import { Button } from 'reactstrap';
import ProjectCard from '../Components/Cards/ProjectCards';
import { getProjects } from '../helpers/data/projectData';
import ProjectForm from '../Componen... |
import SignIn from '@components/SignIn'
import { connect } from 'react-redux'
import { AsyncStorage } from 'react-native'
import { graphql, compose } from 'react-apollo'
import gql from 'graphql-tag'
import { writeTokenToStorage, setFormValue } from '@actions/login'
import { getLogin, getPassword } from '@selectors/log... |
const Util = require('../util');
/**
* A command in the bot.
*/
class Command {
/**
* @param {TrelloBot} client
*/
constructor(client) {
this.client = client;
this.subCommands = {};
}
/**
* @private
*/
_preload() {
if (!this.preload() && this.client.config.debug)
this.client.... |
const requestBody = {
query: `
query {
events {
_id
title
description
price
date
creator {
_id
firstName
lastName
email
... |
/**
* Manager for user notifications.
*/
const mailerManager = require('./mailer-manager');
class NotificationsManager {
constructor(){
this.NotificationTypes = {
GENERAL: 0,
NEW_MATCH: 1,
MESSAGE: 2
};
}
init(){
return new Promise((resolve, reject) =>{
resolve();
}... |
import React from "react";
import { withRouter } from "react-router";
import { Helmet } from "react-helmet";
import Expand from "react-expand-animated";
import styled from "styled-components";
import Colors from "../../../global/styles/colors";
import { Text, SubText, Button } from "../../../global/styles/styles";
impo... |
var FreelancerProfile = {
init: function () {
this.cacheElements();
this.bindEvents();
this.addWidgets();
},
cacheElements: function () {
this.$rating = $('select#rating');
this.$form = $('form#project-notification-form');
this.$industries = this.$form.find('select#industries');
this.$profess... |
var express = require('express');
var app = express();
var orm = require('orm');
var paging = require('orm-paging');
var server = require('http').createServer(app);
app.use(express.bodyParser({}));
app.use(orm.express("mysql://root:123456@localhost/microwin", {
define: function (db, models) {
db.use(paging);
... |
import React, { Component } from 'react';
import { FlatList, Text, View, StyleSheet, Image } from 'react-native';
import backgroundRound from '../../images/backgroudRound/round.png';
class Avatar extends Component {
constructor(props) {
super(props);
}
render() {
return (
<View style={styles.conta... |
const initialState = {
isPop: false,
popIndex: -1,
};
const search = (state = initialState, action) => {
switch (action.type) {
case "TOGGLE_POPUP_BOX":
return { isPop: !state.isPop, popIndex: action.dataIndex };
default:
return state;
}
};
export default search;
|
const mainColor = "#159793";
const lightestColor ="#FFF";
const darkestGray = "#3C4043"
export {
mainColor,
lightestColor,
darkestGray
} |
import React, { Component } from 'react';
import {
StyleSheet,
View
} from 'react-native';
import Navigation from './src/view/navigation/Navigation';
import { Provider } from 'react-redux';
import { createStore, applyMiddleware } from 'redux';
import reducers from './src/redux/reducers';
import ReduxThunk from 'r... |
import React, { useState, useEffect } from "react";
import { Form, Button, Card } from "react-bootstrap";
import { useParams, useHistory, withRouter } from "react-router-dom";
import ChallangeService from "../services/ChallangeService";
import moment from "moment";
import queryString from "query-string";
function Edit... |
var Accordion = function (rootElement) {
this.rootElement = rootElement;
this.buttonItemClickOne = this.rootElement.querySelector('.accordion-click-one');
this.buttonItemClickTwo = this.rootElement.querySelector('.accordion-click-two');
this.buttonItemClickTree = this.rootElement.querySelector('.accordi... |
class VigenereCipheringMachine {
constructor(isDirect=true) {
this.isDirect = isDirect;
}
encrypt(message, key) {
if (arguments.length < 2) {
throw new Error('Wrong arguments!');
} else {
const encryptedChars = [];
for (let i = 0, omissions = ... |
/*
DYNAMICALLY CREATE CLICK EVENTS LISTENERS
https://toddmotto.com/attaching-event-handlers-to-dynamically-created-javascript-elements/
POPULATE BUTTONS FROM JSON RECEIVED FROM SERVER
-resources-
http://stackoverflow.com/questions/21747878/how-to-populate-a-dropdown-list-with-json-data-dynamically-section-wise-in... |
/// <reference types="Cypress" />
describe("Login", () => {
context("when not logged in", () => {
it("redirects to the login page with a message", () => {
cy.visit('/');
// shows the login form
cy.contains("Log In");
cy.url().should('include', 'login');
// shows an error message... |
angular.module('starter.controllers', [])
.controller('DashCtrl', function($scope) {})
.controller('ChatsCtrl', function($scope, Chats) {
// With the new view caching in Ionic, Controllers are only called
// when they are recreated or on app start, instead of every page change.
// To listen for when this page i... |
import React from 'react'
import moment from 'moment';
const ArticleIndividual = (props) => {
console.log('ai render', props);
let date = new Date(props.data.date);
let formattedDate = moment(date).format("DD/MM/YYYY HH:mm");
return (
<div className="article-individual">
{/* <div className="article-... |
import {Form, Input, Button, Radio, Select, DatePicker, Col, Row} from 'antd';
import React from 'react'
import ruleUtils from '../rules/ruleUtils';
const FormItem = Form.Item;
const checkPhone = (rule, value, callback) => {
if (value!='') {
callback();
//console.log(`11111`)
return;
}
... |
const ArgumentInterpreter = require('./structures/ArgumentInterpreter');
const Trello = require('./structures/Trello');
const Util = require('./util');
const prisma = require('./prisma');
module.exports = class Events {
constructor(client) {
this.client = client;
client.on('messageCreate', this.onMessage.bin... |
const express = require ('express')
// generate a router object from the express library
// A router is sort of an empty 'app' that only has route logic
const router = express.Router()
// a route that says yay
router.get('/new', (reg, res) => {
res.send('Yay new user')
})
// a route that oretends to have deleted a... |
import React from 'react'
import './css/home.css'
import connect from 'redux-connect-decorator';
import { fetchUsers } from '../actions/blogAction'
@connect((store) => {
return {
users: store.blog.users
}
})
export default class Home extends React.Component {
constructor(props) {
super(prop... |
const videoShowCase = document.getElementsByTagName("video")[0];
videoShowCase.muted = true;
console.log(videoShowCase);
document.querySelector("#icon-search-menu").addEventListener("click", () => {
document.querySelector(".search-box").classList.toggle("active");
});
document.querySelector(".notifications").addEve... |
const express = require('express');
const app = express();
const {v4: uuidv4} = require("uuid");
const router = express.Router()
app.use(express.json()) // Permite utilizar json em mais de uma rota.
const pets = [];
/**
* Query params - vamos utilizar para buscar informações especifícas ou toda a informaç... |
const path = require('path');
const express = require('express');
const rootDir = require('../util/path');
const router = express.Router();
router.get('/protected-section-1', (req, res, next)=>{
res.render('protected', {content: 'Protected Section'});
});
router.post('/protected-section-1', (req, res, next)=>{
... |
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var toDoSchema = new Schema({
title: { type: String, reqiured: true },
comment: String,
deadline: { type: Date, default: undefined},
done: { type: Boolean, default: false },
});
var toDo = mongoose.model('toDo', toDoSchema);
module.exports... |
var a;
(function() {a=50})(); |
import constants from '../constants.js'
export { handleMissingInput }
const handleMissingInput = (inputToCheck, notificationElement) => {
const inputValue = inputToCheck.value
if(inputValue === '') {
inputToCheck.classList.add('missing-input')
notificationElement.textContent = constants.MELDUNG_BITTE_ER... |
import types from './model/actionTypes'
import * as http from './http.fake'
export default Object.freeze({
[types.getNumber]: async ({ id = 'blah', a, b, cached } = {}) =>
http.get(`/numbers/${id}`, {a, b}, cached),
[types.setNumber]: async ({ id = 'blah', number } = {}) =>
http.set('POST', `/numbers/${id... |
import React from 'react';
import Button from './Button.jsx';
// https://www.npmjs.com/package/crontrans
class CronList extends React.Component {
constructor() {
super();
}
render() {
if (this.props.data.length > 0) {
let cronNodes = this.props.data... |
// \x00\x01...\xAB
var data = "<DATA>";
var url = "<URL>";
xhr = new XMLHttpRequest():
xhr.open("POST", url, true);
var boundary = "---------------------------";
boundary += Math.floor(Math.random()*32768);
boundary += Math.floor(Math.random()*32768);
boundary += Math.floor(Math.random()*32768);
xhr.setRequestHeader... |
import React from 'react';
import withStore from '~/hocs/withStore';
import styles from './about.scoped.css';
class About extends React.Component {
constructor(props) {
super(props);
this.TEXT = this.props.stores.textsStore;
this.versions = this.props.stores.versions;
}
render() {
let ve... |
'use strict';
var gulp = require('gulp');
var webpack = require('gulp-webpack');
var run = require('run-sequence');
var BrowserSyncPlugin = require('browser-sync-webpack-plugin');
/**
* Creates a default development instance and watches for app changes
* and rebuilds while devel... |
// require('dotenv').config({ path: '.env' });
const express = require('express');
const bodyParser = require('body-parser');
const cors = require('cors');
const socketIO = require('socket.io');
const http = require('http');
const app = express();
const server = http.createServer(app);
const io = socketIO(server);
... |
const fs = require("fs");
const fsp = fs.promises;
/**
* Try to unlink a file, silently failing if the file doesn't exist.
* @param {string | Buffer | URL} path
*/
module.exports = async function unlinkOptional(path) {
try {
await fsp.unlink(path);
} catch (e) {
if (e.code === "ENOENT") retu... |
/**
* @project iii-for-vk
* @author Valentin Popov <info@valentineus.link>
* @license See LICENSE.md file included in this distribution.
*/
import urlParseLax from 'url-parse-lax';
import queryString from 'querystring';
import iiiClient from 'iii-client';
import EventEmitter from 'events';
import inherits from 'inh... |
import { Button } from '@material-ui/core';
import { useContext } from 'react';
import { getAlbumList } from '../../../apis/albumActions';
import { DatabaseContext } from '../../../DatabaseContext';
import AlbumList from './album-list/AlbumList';
import './AlbumPage.css';
function AlbumPage() {
const data = useConte... |
import { Route } from "react-router-dom";
import "./App.css";
import Home from "./components/Home";
import NavBar from "./components/NavBar";
import About from "./components/About";
import Contact from "./components/Contact";
import WishList from "./components/WishList";
import Login from "./components/Login";
import S... |
export const config = {
username: 'test',
password: 'test',
secret: 'WhiskeyWhiskeyWhiskey',
};
|
"use strict";
/*
Copyright [2014] [Diagramo]
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 to in writi... |
loginCheck("orders");
function _getDate() {
var month_names = new Array("Января", "Февраля", "Марта", "Апреля", "Мая", "Июня", "Июля", "Августа", "Сентября", "Октоября", "Ноября", "Декабря");
var d = new Date();
var current_date = d.getDate();
var current_month = d.getMonth();
var current_year = d.getFullYear();
... |
const multer = require('multer');
const path = require('path');
const fs = require("fs")
, aws = require('aws-sdk');
var makeDirectory = function(dirPath, mode, callback) {
//Call the standard fs.mkdir
fs.mkdir(dirPath, mode, function(error) {
//When it fail in this way, do the custom steps
if ... |
const Input = {
UP : Symbol('UP'),
DOWN : Symbol('DOWN'),
LEFT : Symbol('LEFT'),
RIGHT : Symbol('RIGHT'),
ATTACK : Symbol('ATTACK'),
NONE : Symbol('NONE')
};
class KeyboardInput {
constructor() {
this.leftKey = new Key(KeyCode.LEFT).listen();
this.rightKey = new ... |
import rp from 'request-promise'
import _ from 'lodash'
import { GOUV_API_URL, GOUV_ENDPOINT } from '../../constants'
export default (text) => {
return new Promise((resolve, reject) => {
const CP = text.match(/\b\d{5}\b/g);
let param = '';
if (CP && !_.isEmpty(CP)) {
param = `codePostal=${_.first(C... |
(function(){
'use strict';
var app = angular.module('eissonApp', [
'ngRoute',
'ngAnimate',
'angular-loading-bar',
'ui.materialize',
'angularMoment',
'ui.validate',
'Controllers']);
app.config(['$routeProvider', 'cfpLoadingBarProvider',function($routeProvider, cfpLoadingBarProvider){
cfpLoadin... |
import {createStore} from "redux";
import {imageProcessorReducer} from "./reducer";
export const store = createStore(imageProcessorReducer);
|
import React, { Component } from 'react';
import { View, Text, StyleSheet, TouchableOpacity, TouchableWithoutFeedback, Keyboard, Button, Alert, ScrollView} from 'react-native';
import { CreditCardInput } from 'react-native-credit-card-input';
import GradientButton from 'react-native-gradient-buttons';
import Colors fro... |
queue()
.defer(d3.json, "/premierleague/team/LIVERPOOL")
.await(makeGraphs);
function makeGraphs(error, premierleagueData) {
if (error) {
console.error("makeGraphs error on receiving dataset:", error.statusText);
throw error;
}
var ndx = crossfilter(premierleagueData);
var yea... |
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const express_1 = require("express");
const config_1 = require("../config/config");
const bcrypt_1 = __i... |
import React from "react";
import { Link } from "react-router-dom";
function Header({ authUser, location, signOut }) {
return (
<header>
<div className="container container--header">
<div className="brand">
<nav>
<Link to="/">
<strong>PlainChat</strong>
... |
var SnapCount = 0;
function Increment(id){
Image = document.getElementById("Button");
Image.src = "../Images/ButtonB.png";
setTimeout("Reset()",100);
console.log(id);
SnapCount = SnapCount + 1;
console.log(SnapCount);
Num = document.getElementById("SnapNum");
Num.innerHTML = SnapCount;
}
function Reset(){
Im... |
import React, { Component } from 'react';
import Row from './MerchantDealRow';
export class Main extends Component {
render() {
let merchantDeals = this.props.deals;
const datamerchantDeals = merchantDeals.map( deal => <Row deleteDeal={this.props.deleteDeal} updateDeal={this.props.updateDeal} key={deal.i... |
$(function(){
'use strict';
var isMobile = false;
var backgroundImg = 'img/laptop-cover-bw.jpg';
var image = new Image();
var $grid = $('.grid');
var $header = $('.header');
var $year = $('.js-year');
$year.html( new Date().getFullYear() );
skrole
.scroll(f... |
/**
* Authors: Diego Ceresuela, Luis Jesús Pellicer, Raúl Piracés.
* Date: 16-05-2016
* Name file: OAuth.js
* Description: Provides callback after Twitter authentication.
*/
(function () {
var OAuth = require('oauth').OAuth;
/**
* Init OAuth object with the twitter application consumer key and secre... |
// @flow
// a package.json file
export type Package = {
// core properties
name: string,
version: string,
// For some bizare reason flow thinks that dependencies is
// at some point merged with publishConfig, release, and repository
// so throws a hissy fit when you try to give dependencies
// a more conc... |
/**
* LINKURIOUS CONFIDENTIAL
* Copyright Linkurious SAS 2012 - 2018
*
* - Created on 2015-06-19.
*/
'use strict';
const _ = require('lodash');
/**
* Actions that can be set to a custom group.
*/
const PUBLIC_ACTIONS = [
{
key: 'admin.connect',
description: 'Connect the data-source and read the confi... |
import limitWordNumTextarea from './limit-word-num-textarea.vue'
export default limitWordNumTextarea |
const hamburger = document.querySelector('.hamburger'),
menu = document.querySelector('.menu'),
closeElem = document.querySelector('.menu__close');
hamburger.addEventListener('click', () => {
menu.classList.add('active');
});
closeElem.addEventListener('click', () => {
menu.classList.remove('active')
});
const ... |
const Style = {
color:'#666666',
fontFamily: 'Poppins',
fontSize: '1rem'
};
const BlogDate = props => (
<div>
<div style={Style}>
{props.children}
</div>
</div>
);
export default BlogDate;
|
//REQUIREMENTS
const User = require("../models/user");
//REGISTER FORM
module.exports.renderRegister = (req, res)=>{
res.render("users/register")
}
//REGISTER POST
module.exports.register = async(req,res)=>{
try{
const {email, username, password} = req.body;
const user = new User({email, username});
... |
import React, { useState } from "react";
import NewMessageForm from "./NewMessageForm";
import MessageList from "./MessageList";
function App() {
const [messages, updateMessage] = useState([]);
const sendHandler = message =>
updateMessage(messages => [...messages, message]);
return (
<div>
<NewMessa... |
console.log('okkkkkkkkkk');
|
/**
* Date Author Des
*----------------------------------------------
* 2018/8/10 gongtiexin 通用搜索表格组件
* */
import React, { Component } from 'react';
import { observer } from 'mobx-react';
import { withRouter } from 'react-router-dom';
import { upObject } from 'up-utils';
impo... |
({
generateSearchToken: function(component, event, helper) {
//console.log('>>>>>> generateSearchToken');
try {
var deferred = event.getParam('deferred');
var action = component.get('c.getEmptyFilterToken');
action.setParams({
searchHub: component... |
import React, { Component } from 'react'
import { connect } from 'react-redux'
import {
fetchContents,
intoLoading,
exitLoading,
} from './actions.js'
import FlatButton from 'material-ui/FlatButton';
import PageSteps from './PageSteps.js'
import Users from './Users.js'
import Chart from '../components/Chart.js... |
#pragma strict
// Class for the Ai
class GomokuAi {
// Variables
public var isWhite : boolean;
public var aiLevel : int;
private var recursionDepth : int;
private var ownColor : Occupation;
private var enemyColor : Occupation;
private var scanList = {};
private var outList = {};
// Contructors
public fu... |
import React, {useEffect, useState} from 'react';
import {StyleSheet, View, InteractionManager} from 'react-native';
import Screen from '../Screen';
import {Colors, Layout, Styles, Fonts, SCREEN_KEYS} from '@app/constants';
import {Button} from 'native-base';
import {Circle, Flex, MapMarker, StyledText} from '@app/comp... |
test('subject_text');
function test(id)
{
document.getElementById(id).innerHTML="STANDARD MESSAGE";
}
|
import React from 'react'
import PropTypes from 'prop-types'
import Menu from '@material-ui/core/Menu'
import MenuItem from '@material-ui/core/MenuItem'
import { More as MoreIcon } from '../../icons'
import './more-menu.scss'
function MoreMenu({ options, onClick }) {
const [anchorEl, setAnchorEl] = React.useState(... |
import React from 'react';
import styles from './footer.module.css';
export default function Footer() {
return (
<footer className={styles.footer}>
Thomas Maxwell Smith Portfolio, made with React. View on <a href="https://github.com/atomcorp/react-portfolio">Github</a>
</footer>
);
} |
import React, { Component } from 'react';
import './App.css';
import Navigation from './components/Navigation/Navigation.js'
import Logo from './components/Logo/Logo.js'
import Particles from 'react-particles-js';
import {particleOptions} from './particle.js'
import ImageLinkForm from './components/ImageLinkForm/ImageL... |
function createDiv2(){
//creare il testo
let txt2 = document.createTextNode("DIVE E P creati dal secondo js caricato");
//console.log(txt2);
//creare p tag e append textnode nel tag
let parag2 = document.createElement("p");
parag2.setAttribute("class", "pagf2");
parag2.appendChild(txt2);... |
function Racers (name , fuel , tire , pominati ) { // konstruktor
this.name = name ;
this.fuel = fuel;
this.tire = tire ;
this.pominati = pominati;
this.getFuel = function () {
return this.fuel; // geter na fuel
}
this.setFuel = function (fuel) {
this.fue... |
import glob from 'glob';
import Promise from 'bluebird';
import initDebug from 'debug';
import path from 'path';
const debug = initDebug('happy:slack:utils:skillDictionary');
export default () => (
new Promise((resolve) => {
glob(path.join(__dirname, '../skills/**/config.js'), {}, (err, files) => {
let sk... |
console.log("first task");
console.time();
for (let i = 0; i < 10000; i++) {
const h3 = document.querySelector("h3");
h3.textContent = "Hey, everyone is waiting for me";
}
console.timeEnd();
console.log("Next task");
console.log("-----------------------");
console.log("firs task");
setTimeout(() => {
console.lo... |
export default {
// "some.translation.key": "Text for some.translation.key",
//
// "a": {
// "nested": {
// "key": "Text for a.nested.key"
// }
// },
//
// "key.with.interpolation": "Text with {{anInterpolation}}"
"name-app":"SupperMarket App",
"menu":{
"home":"Home",
"products":"P... |
pm_domain_url = null;
sender_guid = "";
popup_onload = false;
object_cnt = null;
// 2015.04.03 hwjang start websock_areaID[index]와 AreaID 관련성 확인
//AreaID = null;
socketIndex_AreaID = null;
// 2015.04.03 hwjang end websock_areaID[index]와 AreaID 관련성 확인
Guid2 = null;
function Bems_postmessage(domain, popup_nam... |
/* eslint-env node,browser,amd */
//
// SaltThePass - DomainNameRule
//
// Copyright 2013 Nic Jansma
// http://nicj.net
//
// https://github.com/nicjansma/saltthepass.js
//
// Licensed under the MIT license
//
(function(root, factory) {
"use strict";
if (typeof define === "function" && define.amd) {
//... |
import users from "./User/routes";
import posts from "./Post/routes";
import express from "express";
import bodyParser from "body-parser";
import { createJWToken } from "./libs/auth";
import allowCrossDomain from "./middleware/node-express-cors-middleware";
import MyLogger from "./middleWare/myLogger";
import axios fro... |
import React from 'react';
// 引入路由
import { NavLink } from 'react-router-dom';
// 引入icon-font
import '../../style/iconfont/iconfont.css';
// 引入样式
import './style.scss';
const tabData = [
{ id: 0, title: 'goods', icon: 'iconfont icon-good', path: '/good' },
{ id: 1, title: 'home', icon: 'iconfont icon-home', path:... |
const express = require('express');
const router = express.Router();
const items_controller = require('../controllers/items.controller');
// get items
router.get('/', items_controller.items_all);
// find item by id
router.get('/:id', items_controller.item_details);
module.exports = router;
|
import { exists, window } from "browser-monads"
import { navigate } from "gatsby"
import React from "react"
import { getCurrentUser, isLoggedIn } from "../../utils/auth"
export default ({ component: Component, ...rest }) => {
if (exists(window) && !isLoggedIn()) {
navigate(`/auth`)
}
const user = getCurrentU... |
"use strict";
var ugly = require('uglify-js');
var path = require('path');
var content = require('../lib/content');
var relativePaths = require('./js.files.json');
var pub = path.join(__dirname, '..', 'public', 'js');
var scriptsDir = path.join(__dirname, 'js');
module.exports.getDevSripts = function getDevScripts() ... |
import React from "react";
import { BrowserRouter, Switch, Route, Link } from "react-router-dom";
import axios from "axios";
import "./App.css";
import { makeStyles } from '@material-ui/core/styles';
import Button from '@material-ui/core/Button';
import { AdminAuthContextProvider } from "./AdminComponents/AdminAuthCo... |
import React from "react";
// core components
import Paper from "@material-ui/core/Paper";
import InputAdornment from "@material-ui/core/InputAdornment";
import Email from "@material-ui/icons/Email";
import Button from "../../../components/CustomButtons/Button";
import CustomInput from "../../../components/CustomInpu... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.