blob_id
stringlengths
40
40
language
stringclasses
1 value
repo_name
stringlengths
5
132
path
stringlengths
3
236
src_encoding
stringclasses
29 values
length_bytes
int64
8
7.94M
score
float64
2.52
5.72
int_score
int64
3
5
detected_licenses
listlengths
0
142
license_type
stringclasses
2 values
text
stringlengths
8
7.94M
download_success
bool
1 class
53101fbcf4c59f6716211efda3f5b78510702674
JavaScript
ararage/autos_express_node
/routes/auto.js
UTF-8
731
2.515625
3
[]
no_license
'use strict' //Importamos express var express = require('express') //Importamos el controlador var autoController = require('../controllers/auto') //Instanciamos un objeto Roter var api = express.Router(); //Definimos el recurso GET con url : /api/auto/:id? , recibe //un parametro y se procesa en el m...
true
21f3446f158e0de8316ad535e52c9ec790ec5455
JavaScript
tarwater/clayholt.com
/public/javascripts/corpus-to-ngrams-dist.js
UTF-8
1,996
3.015625
3
[ "MIT" ]
permissive
var fs = require('fs'); var natural = require('natural'); var _ = require("underscore"); var file = '../../storage/corpora/trump.txt'; var data = fs.readFileSync(file).toString(); var tokens = data.split(" "); // do preprocessing of data first... tokens = _.map(tokens, function (w) { if(w == w.toUpperCase()){ ...
true
fbb9c21f34f11410c62bee8649f3b0e674222aa3
JavaScript
DangerPNZ/200889-cinemaddict-10
/src/models/movies.js
UTF-8
3,924
2.5625
3
[]
no_license
import {compare} from '../utils/utils.js'; import API from '../api/index.js'; import DataAdapter from '../api/data-adapter.js'; const SortTypeValue = { DEFAULT: `default`, BY_DATE: `releaseDate`, BY_RATING: `ratingVal` }; const FilterTypeValue = { IN_WATCHLIST: `#watchlist`, ALREADY: `#history`, IN_FAVORIT...
true
40928607deb22390259f5623aab17cf0412e806c
JavaScript
developertracker/trackmyloan
/js/main.js
UTF-8
1,884
2.765625
3
[ "MIT" ]
permissive
function manageHeight(){ var winHeight = $(window).height(); var headerHeight = $(".header").height(); var totalHeight = winHeight-headerHeight; $(".content").css("height",totalHeight); } function validateForm() { var x = document.forms["searchApplication"]["appNumber"].value; var y = document.forms["searchApplic...
true
1d028e4859a235b16a226122181dc1711bb97197
JavaScript
bgoonz/UsefulResourceRepo2.0
/MY_REPOS/web-dev-notes-resource-site/2-content/Official-Documentation/en.javascript.info-master/en.javascript.info-master/2-ui/3-event-details/3-mousemove-mouseover-mouseout-mouseenter-mouseleave/mouseoverout-fast.view/script.js
UTF-8
1,030
3.015625
3
[ "MIT" ]
permissive
let parent = document.getElementById('parent'); parent.onmouseover = parent.onmouseout = parent.onmousemove = handler; function handler(event) { let type = event.type; while (type < 11) type += ' '; log(type + " target=" + event.target.id) return false; } function clearText() { text.value = ""; lastMess...
true
4f800d871767c07f5eba4b6a4b5f3b357e96dda7
JavaScript
ntl-bk/shopping-report
/src/reducers/report-list.js
UTF-8
1,031
2.578125
3
[]
no_license
const updateReportList = (state, action) => { if (state === undefined) { return { items: [], }; } if (!action.payload) { action.payload = []; } switch (action.type) { case 'ADD_ITEM': const itemIndexForAdd = state.reportList.items.findIndex( (item) => item.date === action.payload.date ); if...
true
811aed266a4d50afca2ac4cbc495c22267470beb
JavaScript
Anurag374-gtll374/discord-bot
/commands/move.js
UTF-8
1,853
2.859375
3
[ "MIT" ]
permissive
const {GuildMember} = require('discord.js'); module.exports = { name: 'move', description: 'move song position in the queue!', options: [ { name: 'track', type: 4, // 'INTEGER' Type description: 'The track number you want to move', required: true, }, { name: 'position', ...
true
cd10111e30d9a38bb7e0d73428ae78e96bdc08d3
JavaScript
jchiellini/mixed-column
/scripts/mixed-column-chart.js
UTF-8
6,640
2.734375
3
[]
no_license
"use strict"; if (d3.charts === null || typeof(d3.charts) !== 'object') { d3.charts = {}; } d3.charts.viz = function () { // Functional inheritance of common areas var my = d3.ext.base(); // Define getter/setter style accessors.. // defaults assigned my.accessor('columnWidth', 50); my.accessor('categories...
true
6cedce75cb87cfc8b2c18dff587ee695f9f4161b
JavaScript
halbhelms/jslingo
/src/utils/index.js
UTF-8
319
2.734375
3
[]
no_license
function randomIntFromInterval(min, max) { // min and max included return Math.floor(Math.random() * (max - min + 1) + min) } function randomObjectProperty (obj) { var keys = Object.keys(obj); return obj[keys[ keys.length * Math.random() << 0]]; }; export { randomIntFromInterval, randomObjectProperty }
true
af7fa206607e9a4490e4668ff39302916613cbca
JavaScript
fluffybunnies/tweether
/lib/apipoller.js
UTF-8
1,411
2.625
3
[ "MIT" ]
permissive
var sext = require('sext') ,through = require('through') ,api = require('./api') module.exports = function(path, opts){ opts = sext({ initialBuffer: 20 ,poll: 60000 ,pollFor: 5 ,findList: function(res){ return (res && Array.isArray(res.entities)) ? res.entities : []; } ,getItemId: function(item){ ...
true
1debc059318aaa0fb9d731adb95c90335b1b7a38
JavaScript
nvbach91/4IZ268-2019-2020-ZS
/www/rydm00/hw10/js/main.js
UTF-8
1,921
3.359375
3
[ "MIT" ]
permissive
/** * Memorama, Match Match, Match Up, Memory, Pelmanism, Shinkei-suijaku, Pexeso or simply Pairs */ var cities = ['Prague', 'Reykjavik', 'Stockholm', 'Bratislava', 'Vienna', 'Amsterdam', 'Brussels', 'Copenhagen', 'Athens', 'Budapest']; cities = cities.concat(cities); cities.sort(() => { return 0.5 - Math.random...
true
4f6a7fd77f452c9e008cbfbad6153fd4c3ea9bed
JavaScript
seanmu13/school-projects
/2008/web-programming/php-tickets-db-2/script.js
UTF-8
3,088
2.59375
3
[]
no_license
var xhr; function submitInfo(form,url){ var skipChecking = false; for(i=0; i<form.elements.length; i++) { if( form.elements[i].type == 'submit' && form.elements[i].value == 'Logout' && document.pressed == 'Logout' ) { skipChecking = true; break; } else if( form.elements[i].type == 'submit' && form.ele...
true
efc6c4ff46655fa1f03661e860246aae3fcaef8d
JavaScript
pjz987/2019-10-28-fullstack-night
/Assignments/pete/javascript/canvas/stick-figure/script.js
UTF-8
2,649
3.3125
3
[]
no_license
let cnv = document.querySelector('canvas'); let ctx = cnv.getContext('2d'); let width = 500; let height = 500; class StickFigure { constructor(px, py, r, color) { this.px = px;//position x this.py = py;//position y this.r = r;//radius // this.lW = this.r/7//line width this....
true
cbb68212c2628a14f036d57c22c8dfc1d3c4d51b
JavaScript
F-WJ/louwowo
/trip-website/target/classes/static/js/system/mytravelnotedetail.js
UTF-8
445
2.78125
3
[]
no_license
$(function () { var left = 0; $('.prev_btn').click(function () { if (left == 0) return; left += 240; $('.mdd_info').animate({ left: left + 'px' }) }); $('.next').click(function () { var len = $('.mdd_info').find('a').length; if ((-len + 1) * 24...
true
cbad5ad66f99f56402bfc5a007205d546c365a9b
JavaScript
TrondSpjelkavik/build-cv
/components/templates/realtimeComponents/Education.js
UTF-8
3,518
2.5625
3
[]
no_license
import { useState } from "react"; import styled from "styled-components"; import { AddButton } from "./Skills"; const EducationBox = styled.div` display: flex; flex-direction: column; word-break: break-word; padding: 5px 0 35px 25px; @media print { width: 60vw; } `; const YearText = styled.li` lis...
true
e4c47dd09e127957f820e96d526e67be4dcc012c
JavaScript
narenz/nodeSpider
/src/httpService.js
UTF-8
408
2.671875
3
[]
no_license
"use strict" const req = require('request'); var getURL = (urlToCrawl, callbackSuccess, callbackErr) => { req(urlToCrawl, (error, response, body) => { if (!error && response.statusCode === 200) { callbackSuccess(body); } else { console.log('URL not reachable' + error...
true
76fd96995713b6133f71aff7bbc345779cb42ac6
JavaScript
Olha98/Timer-RxJS
/src/common/helpers.js
UTF-8
90
2.9375
3
[]
no_license
export const getCreateTime = (time) => new Date(time * 1000).toISOString().substr(11, 8);
true
7d7c3424a6803564595330882df15695713879e5
JavaScript
CarmineVitale/ajax-ex-calendar
/js/main.js
UTF-8
3,934
3.140625
3
[]
no_license
/** * WELCOME TO MOMENT JS */ $(document).ready(function () { /** * SETUP */ // Punto di partenza var baseMonth = moment('2018-01-01'); //Referenze bottoni var btnPrev = $('.prev'); var btnNext = $('.next'); // Init Hndlenars var source = $('#day-template').html(...
true
d7aad2334ec3e327be4f9b6a26e079445f6101f5
JavaScript
adamberco/MineSweeper
/js/main.js
UTF-8
18,785
2.8125
3
[]
no_license
'use strict' /* TO DO: Best Score :Keep the best score in local storage (per level) and show it on the page 10-12 DONE Manually positioned mines 12-14 DONE Undo 14 - 16 7 BOOM! 16-18 */ const MINE = '💣' const FLAG = '🚩' const EMPTY = '' const HEART = '💖' const HINT = '💡' const soundCli...
true
6edb2b9ce0774974d9e70c1103a41a3c9e7a22ba
JavaScript
SaraDobra/HospitalManagementSystem
/src/main/resources/static/js/patientForm.js
UTF-8
2,653
2.984375
3
[]
no_license
var formFields = { id: document.getElementById("idNr"), firstName: document.getElementById("firstName"), lastName: document.getElementById("lastName"), email: document.getElementById("email"), phoneNr: document.getElementById("phoneNr"), address:document.getElementById("address"), city:docum...
true
222943294a2417e7085395dae73bcda90040c793
JavaScript
AlexPrediger/webpack-starter
/js/test/is-object.test.js
UTF-8
809
2.6875
3
[ "MIT" ]
permissive
import { isObject } from '../src/helper/is/index'; test('object is an object', () => { expect(isObject({'sdfsdf': 3})).toBe(true); }); test('short string is not an object', () => { expect(isObject('d')).toBe(false); }); test('long string is not an object', () => { expect(isObject('jsadfisiadjf sioadj fposhiad ...
true
1feac0beba1a136bb80aa6f3632fe3c0e4bd8451
JavaScript
ChrisJVoss/react-notes
/client/index.js
UTF-8
2,022
2.671875
3
[]
no_license
require('dotenv').config() import React from 'react' import ReactDOM from 'react-dom' class NoteList extends React.Component { constructor(props) { super(props) } componentDidMount() { fetch('/notes') .then(response => response.json()) .then(notes => this.props.updateState(notes)) } rende...
true
17f2007d383cfb31b7fcd0c17b07d6b4fd708aed
JavaScript
FredLackey/file-line-replacer
/src/utils/to-table.js
UTF-8
1,284
3.234375
3
[ "Apache-2.0" ]
permissive
const COL_DELIM = '|'; const LINE_CHAR = '-'; const getColumnWidths = (lines, delimiter) => { const results = []; lines.forEach(line => { const parts = line.split(delimiter); for (let i = 0; i < parts.length; i += 1) { const { length } = parts[i].trim(); if (results.length < (i + 1)) { ...
true
71bc257f9977cbc8af72f9d6e139634122d0817b
JavaScript
KameliaDimitrova/Tech-module
/SoftUni/2.SoftwareTechnologies-November2017/1.JavaScript-Basics/10.Add - Remove Elements.js
UTF-8
538
3.421875
3
[]
no_license
function commandAddOrDelete(args) { let result=[]; for(let i=0;i<args.length;i++) { let currArg=args[i].split(' '); let command=currArg[0]; let num=Number(currArg[1]) if(command=="add") { result.push(num); } if(command=="remove") {...
true
be82d62cb184ab4b7cb4df93fa123cc9b6a81455
JavaScript
flleming/shopfaBack
/utilFunction/functionUtil.js
UTF-8
1,488
2.5625
3
[]
no_license
const mime = require('mime'); const fs = require('fs'); const jwt = require("jsonwebtoken"); function uploadPhoto(res,photo) { //upload image let path = ""; let imgName = Date.now(); path = './upload/' + imgName; var matches = photo.match(/^data:([A-Za-z-+\/]+);base64,(.+)$/), response =...
true
5d93dea13e97d498ffbb967a4e7e7acacfde6c7c
JavaScript
W01fw00d/rotting_maze
/src/scripts/maze/MazeFactory.js
UTF-8
6,427
3.125
3
[]
no_license
class MazeFactory { constructor() { this.pathWidth = 10; this.wallWidth = 2; this.delayMilliseconds = 100; //3000 1 } defaultStructureConstructor() { const width = 15; const height = 30; const outerWallWidth = 2; //TODO Make the start point random ? this.startX = width / 2 | 0; ...
true
cef1f9e2248710cd1512e33b89ac559ce5370530
JavaScript
pt7-devdesk-queue/devdesk-queue
/js/demo.js
UTF-8
2,351
3.4375
3
[]
no_license
// //Demo Page const firstName = document.getElementById('firstName'); const lastName = document.getElementById('lastName'); const company = document.getElementById('company'); const email = document.getElementById('email'); const phone = document.getElementById('phone'); firstName.addEventListener('change', () => { ...
true
4f1743d7b3b2562efd606baefcd41fcb21e59ed1
JavaScript
JeanCDev/UserManagementServer
/client-server/public/dist/js/script.js
UTF-8
2,193
3.21875
3
[]
no_license
/*var name = document.querySelector('#exampleInputName'); var gender = document.querySelectorAll('#form-user-create [name="gender"]:checked'); var birth = document.querySelector('#exampleInputBirth'); var country = document.querySelector('#exampleInputCountry'); var email = document.querySelector('#exampleInputEmail');...
true
e9886ae7a0e62811a641c9c593506cc4c3795c66
JavaScript
WyrmxD/Ironhack
/week_03/patterns/javi_slides/patterns/Factory/PizzaStore.js
UTF-8
312
2.796875
3
[]
no_license
var PizzaStore = function(){ }; PizzaStore.prototype.orderPizza = function(sType){ var oPizza = null; oPizza = this.createPizza(sType); oPizza.prepare(); oPizza.bake(); oPizza.cut(); oPizza.box(); }; PizzaStore.prototype.createPizza = function(){ throw new Error("This method must be overwritten!"); };
true
1c23ce47e936caa1d0ab92d0904923fb0f36dde3
JavaScript
BolasLien/node-line-BolasLien
/index.js
UTF-8
787
2.625
3
[]
no_license
// 引用 linebot 套件 import linebot from 'linebot' // 引用 dotenv 套件 import dotenv from 'dotenv' // 引用 request 套件 import rp from 'request-promise' // 讀取 .env 檔 dotenv.config() // 宣告機器人資訊 const bot = linebot({ channelId: process.env.CHANNEL_ID, channelSecret: process.env.CHANNEL_SECRET, channelAccessToke...
true
71d422cc586d76fd9598f5cf385346b1912a9fe0
JavaScript
jjrb3/stidsjeal-js
/stids/urls.js
UTF-8
1,365
2.734375
3
[]
no_license
/** * Created by Jeremy Jose Reyes Barrios on 3/07/2017. */ Api.Uri = { crud: function(accion,controlador,carpeta) { return 'crud=true&padre=' + $('#idPadre').val() + '&hijo=' + $('#idHijo').val() + '&funcionesVariables=' + accion + '&controlador=' ...
true
23a528095617ef078fb65729beae16258d039d8c
JavaScript
patsyuck/goit-js-hw-02
/js/task-27.js
UTF-8
312
3.640625
4
[]
no_license
function filterArray(numbers, value) { const filteredNumbers = [] for (const number of numbers) { if (number > value) { filteredNumbers.push(number) } } return filteredNumbers } console.log(filterArray([12, 24, 8, 41, 76], 38)) console.log(filterArray([1, 2, 3, 4, 5], 5))
true
1a8f847e3b881fe7f8a06dda0c63a1fd62b5f750
JavaScript
mattdow/auth-shelf
/src/redux/sagas/items.saga.js
UTF-8
1,002
2.640625
3
[]
no_license
import axios from "axios"; import { put, takeLatest } from "redux-saga/effects"; function* fetchItems() { // GET ALL ITEMS try { const response = yield axios.get("/api/shelf"); yield console.log('response', response); yield put({ type: "SET_ITEMS", payload: response.data }); } catch (err) { yie...
true
4e19e3cd3cf5be74a0a2495fda12b3c8772aa68a
JavaScript
faireprogram/AlgorithmMecury
/2/2.js
UTF-8
224
2.9375
3
[]
no_license
function recursiveAdd(intVar) { if(!intVar) { return 0; } var lastDigit = intVar - parseInt(intVar / 10) * 10 ; return lastDigit + recursiveAdd(parseInt(intVar / 10)); } console.log(recursiveAdd(1435123));
true
7cfba547fa526d6645c1acb90393c83a9cf0355b
JavaScript
nangongtianci/scfl-react-front-dispatching-center
/src/component/job_report/job_report_list.js
UTF-8
2,247
2.5625
3
[]
no_license
import React, { Component } from 'react'; import './job_report.css' // 设定服务器请求路径 const baseUrl = 'http://localhost:8080/'; const jobReportPath = 'job/record/page'; // 作业报告分页查询 const jarReportTitle = ( <ul className="job_report_ul title"> <li>包点类</li> <li>方法名称</li> <li>执行状态</li> <li>...
true
e111b109697b9cca2366a70d904ab945bd893dd2
JavaScript
animanamit/MERN-Shopping-Cart
/client/src/components/Item.js
UTF-8
4,160
2.8125
3
[]
no_license
import React, { Component } from 'react'; import axios from 'axios'; class Item extends Component { constructor(props) { super(props) this.state = { title:"", price:"", description:"", photo:"", quantity:"", comments:[], reviews:[], id:"", commentWriting...
true
670712179fd9832dd620f0a7c43a82a71ad88dc9
JavaScript
Vinayabali5/Template
/src/main/webapp/resources/js/components/entities/tutor-group-remark-permission/tutorGroupRemarkPermission.service.js
UTF-8
1,538
2.765625
3
[]
no_license
/** * This is the factory definition for the StudentYear Data Service. This defines how to handle data about StudentYear objects. * * Applied Styles: [Y001, Y002, Y010, Y021, Y022, Y023, Y024, Y050, Y051, Y052, Y053] * * @type Data Service */ (function() { 'use strict'; angular .module('TutorGrou...
true
141bfdf494ee741c2af422231b98c881337f603a
JavaScript
fgridley/art-of-generation-sketches
/voronoi/voronoi-utils.js
UTF-8
1,536
3.3125
3
[]
no_license
function createRandomPoints(numPoints, offset = 0) { points = []; for (let i = 0; i < numPoints; i++) { points.push({ x: round(random(offset, width - offset)), y: round(random(offset, height - offset)) }); } return points; } function generateVoronoi(points, offse...
true
9540ac1c9453f5cd8c7e36f9a902a5648bd8a5ba
JavaScript
vincentleandr/ThesisProject
/js/validation-change-password.js
UTF-8
1,007
2.53125
3
[]
no_license
// JavaScript Document $(document).ready(function() { $('#change-password-form').validate({ rules: { OldPassword: { required: true, rangelength:[6,20] }, NewPassword: { required: true, rangelength:[6,20] }, ConfirmNewPassword: {equalTo:'#NewPassword'}, ...
true
65dd2522fd5aa696acd888589906902c26f8c83a
JavaScript
lsannicolas/GameDev
/gameengine.js
UTF-8
8,081
2.703125
3
[]
no_license
// This game shell was happily modified from Googler Seth Ladd's "Bad Aliens" game and his Google IO talk in 2011 class GameEngine { constructor() { this.entities = []; this.platforms = []; this.menus = []; this.background = null; this.ctx = null; this.surfaceWidth =...
true
9a92f8f3fae9a0acba735723edfb9af6c6875741
JavaScript
OdinVR/ng-client
/scripts/scenebuilder.js
UTF-8
3,781
2.515625
3
[]
no_license
alert('scene builder initialized ...'); var sceneModels = []; var receivedFirstScene = false; var currentScene = {}; var SceneBuilder = function () { } SceneBuilder.prototype.renderInBody = renderInBody; SceneBuilder.prototype.renderInPanel = renderInPanel; SceneBuilder.prototype.receiveSceneData = receiveSceneData;...
true
4afde002f8b3d199d5c11d5a3669e7aef757ffa9
JavaScript
orsa-unige/ant-test-3
/javascript-of-the-page.js
UTF-8
4,260
2.890625
3
[]
no_license
/// Retrieves the configuration file /// Browsers still do not accept "require()" var config = (function() { var cfg = null; $.ajax({ 'async': false, 'global': false, 'url': "./config.json", 'dataType': "json", 'success': function (d) { cfg = d; } ...
true
8f1eb996d45282182c0e1cc867fea536a3afecf5
JavaScript
XYZfinal/EChacks
/EChacks/index.js
UTF-8
1,269
2.828125
3
[]
no_license
var background = document.getElementbyTagName('body'); background.style.backgroundColor = "black"; var rand_position_x = function (width){ return Math.floor(Math.random() * (width + 1)); }; var ball_position_x = 0; //position of the ball in x axis ...
true
d08dff5f90353e2399ae55ac18daa0bc0c323073
JavaScript
Janaina-Costa/Praticando-Aulas-Cod3r-JavaScript
/Node/passandoParametroCliente.js
UTF-8
101
2.5625
3
[]
no_license
const entrada = require('./passandoParametro')('Tatiana', 'Janaina', 'Luvique') console.log(entrada)
true
f12cd4b4b87704ab329c7b2e52df69aec7ff8584
JavaScript
aleskafka/deployk
/lib/Loader/FileLoader.js
UTF-8
3,785
2.53125
3
[ "MIT" ]
permissive
var util = require('util'); var fs = require('fs'); var path = require('path'); var glob = require('glob'); var minimatch = require('minimatch'); var EventEmitter = require('events').EventEmitter; module.exports = FileLoader; /** * @param {string} * @param {Array.<string>} * @param {boolean} * @constructor *...
true
cb0d92820241d5d461a55cb9f028e80f089bfa3a
JavaScript
webmakersteve/mythicplus-thumbnail-generator
/index.js
UTF-8
2,777
2.65625
3
[]
no_license
const fs = require('fs'); const path = require('path'); const gm = require('gm'); const program = require('commander'); const colors = require('./colors'); const { ROLES, DUNGEONS, DUNGEON_NAMES } = require('./constants'); const DUNGEON_PATH = path.resolve(path.join(__dirname, 'dungeons')); const ROLE_PATH = path.res...
true
9879154a07ecee3f0b76a7782fb11904f698ac33
JavaScript
EricaJCasePhD/js-digital-clock
/index.js
UTF-8
340
3.078125
3
[]
no_license
// console.log("TEST, TEST"); $(document).ready(function() { // anonymous function console.log("ANOTHER TEST"); var getTime = function(){ console.log("Hey I'm in a clock"); timenow = $('<div id = "clock" >' + new Date() + '</div>'); $('#clock').replaceWith(timenow); }; var myTimer = setInterval(...
true
0be49bc4008f29799b9fa865fc67dcded79f4a4b
JavaScript
coderdojo-linz/FaceDetectionBackend
/dontLaughChallenge.js
UTF-8
2,659
2.859375
3
[]
no_license
var dateStart = new Date(); var timeStart = dateStart.getTime(); var timer = dateStart.getTime() - 3000; var counter = 0; window.onload = () => { socket.on('detection', function (msg) { msg = JSON.parse(msg); if (document.getElementById('lachometer')) { //show Lachometer ...
true
8d5d6d5e57064b5977c4e8b55a99f1329370357c
JavaScript
tamaradesmith/weather-app
/client/src/components/partials/details/SensorShowworking.js
UTF-8
3,263
2.8125
3
[]
no_license
import React, { useEffect, useState } from 'react'; import * as d3 from "d3"; import '../../styles/chart.css'; import { Sensor } from '../../js/requests' const data = [{ skill: "CSS", value: 80 }, { skill: "HTML", value: 70 }, { skill: "JS", value: 85 }, { skill: "ANGULAR", value: 90 }, { skill: "REACT", value: 75 },...
true
2b91f4885656e306a37a88ad84bc39b36f16fe44
JavaScript
ScoutYin/LeetCode-JavaScript
/leetcode/排序/插入排序/insertionSort1.js
UTF-8
1,001
3.953125
4
[ "MIT" ]
permissive
/** * 插入排序 */ const insertionSort = (arr) => { console.time('插入排序耗时'); const len = arr.length; // i为无序序列的起始索引,从1开始即可,因为第0个可以认为已经处于有序序列中 for (let i = 1; i < len; i++) { // 要插入的数 const target = arr[i]; // scanIndex为扫描指针,初始值为有序序列的末位索引 let scanIndex = i - 1; // 终止条件为:找到第一个比target小或者等于target的数或者扫描到有序序列左端点...
true
4537a8a600c98756dfb749be5d2ab4b464bc0022
JavaScript
G-Justin/UChan
/public/js/uchan.datatables.js
UTF-8
4,020
2.578125
3
[]
no_license
$(document).ready( function () { var reportTable = $('#reportTable').DataTable(); var moderatorTable = $('#moderatorTable').DataTable(); var keysTable = $('#keysTable').DataTable(); var bannedTable = $('#bannedTable').DataTable(); //ON OPEN $('#reportTable tbody').on('click', 'tr', function () ...
true
468b42c1547f3429e83621f475f432f7ccf9d826
JavaScript
NikChoudhury/Node.Js
/jsonNode.js/index.js
UTF-8
1,240
3.890625
4
[]
no_license
const fs = require('fs'); // File System Module //JavaScript Object const bioData = { firstName: "Nikumani", lastName: "Choudhury", age: 23 } // console.log(bioData); // console.log(bioData.firstName); //Convert JS object to JSON const jsonData = JSON.stringify(bioData); // console.log(jsonData); // cons...
true
399e7f3654cdbae900dce70b5d5c2551deff646c
JavaScript
Kim-Hyerin/Doit_Javascript_basic
/09/js/getForm.js
UTF-8
311
2.921875
3
[]
no_license
var selectMenu = document.testForm.major; //선택 목록 가져와 selectMenu에 저장 function displaySelect() { var selectedText = selectMenu.options[selectMenu.selectedIndex].innerText; //선택한 항목의 인덱스 찾고 innerText로 표시 alert("[" + selectedText + "]를 선택했습니다."); }
true
0db966c5edd86d40139d690237a001fde86ca455
JavaScript
arianaamx/advent-of-code-2020
/Day 7/SecondPart.js
UTF-8
1,514
3.078125
3
[]
no_license
const axios = require("axios"); // 5463 is too low // 35487 correct async function makeRequest() { const config = { method: "get", url: "https://adventofcode.com/2020/day/7/input", headers: { Cookie: "_ga=GA1.2.609869550.1606597228; session=53616c7465645f5f63514525ec0ca369628697393717ede01...
true
6700661780f84c51072684e5b610a749d398fe5a
JavaScript
Jerome361/Personal-files
/objectAssgnt.js
UTF-8
802
3.015625
3
[]
no_license
//Using a factory function Phone(brand,model,color,batteryLife,category){ return { brand:brand, model:model, color:color, batteryLife:batteryLife, category:category }; } let tecno=Phone('tecno',"pop2","black","24hrs","smart") let nokia=Phone('nokia','ka t...
true
40cc3ea9dac18990c77c25e59109aaf8f12cc8a7
JavaScript
austindryden/dom-exercise-20191206
/scripts/index.js
UTF-8
3,402
3.703125
4
[]
no_license
function linkPlacer(linkPath){ // debugger; const links = document.createElement("a"); links.href = linkPath; links.textContent = linkPath + ` `; linkContainer.appendChild(links); } function anchorFromObject(obj){ let link = anchorFromLinkPath(obj.url); link.textContent = obj.text; retu...
true
063ab22a96e653c3c1927ee0f4fe40b6da434330
JavaScript
JacobMJones/goofspiel-server
/public/scripts/lobby.js
UTF-8
3,461
2.8125
3
[ "MIT" ]
permissive
$(document).ready(function() { console.log('in lobby starts'); setInterval(poll, 20); }); let lastLobbyStateChange = 0; const poll = function() { $.ajax({ url: "http://localhost:8080/lobby_data", success: function(lobbyState) { checkLogForNewEvents(lobbyState); ...
true
1aa76810a2997eb73a49cf1921de4037de9766c6
JavaScript
ransonk/trainer-hub
/react-app/src/components/clientview/GraphProgress.js
UTF-8
9,250
2.5625
3
[]
no_license
import React, { useEffect } from "react"; import { useDispatch, useSelector } from "react-redux"; import { Line } from 'react-chartjs-2'; import { fetchWorkoutHistory, updateProgress } from "../../store/users"; function GraphProgress() { const dispatch = useDispatch(); const client = JSON.parse(localStorage.ge...
true
07d2aee5b350ca539fe91dc06059511048a967a4
JavaScript
ng9891/infogroup
/utils/geocode.js
UTF-8
1,641
2.921875
3
[]
no_license
const fetch = require('node-fetch'); /** * Depends on Nominatim API. @https://nominatim.org/ * Makes a request to Nominatim Geocoding API to get GeoJSON * @param {String} input */ exports.nomGeocode = (input) => { return new Promise(async (resolve, reject) => { if (!input || typeof input !== 'string') re...
true
6673637de441e9ad77a14cdb9b8f65aaba79bf44
JavaScript
ruuuh20/team-builder
/src/components/Register/Save.js
UTF-8
682
2.65625
3
[]
no_license
import React from 'react'; import './Save.css' const Save = (props) => { const elements = []; console.log(props.elements) for (let el in props.elements) { elements.push( { name: el, number: props.elements[el] } ) }; const elementOutput = elements.map(e => { return <span ...
true
80b28f455d18ae154c9815936736f773f4e153dc
JavaScript
little-chi-mai/GA-classwork
/10-ajax/callbacks/js/callbacks.js
UTF-8
1,479
4.25
4
[]
no_license
// A callback function is a function PASSED TO another function. // The passed function gets called for you, later, at some point in time. // Javascript is asynchronous. // Timers: A, C, B console.log('A'); setTimeout(function () { console.log('B: time has passed'); }, 4000) console.log('C'); // jQuery's document ...
true
fa0c5c0a89459251835ec3cd4f086dfe7e7442ea
JavaScript
Build-Week-30Before30/node-api1-guided
/index.js
UTF-8
1,487
2.625
3
[ "LicenseRef-scancode-warranty-disclaimer" ]
no_license
// import express from 'express'; const express = require('express') const db = require('./data/hubs-model.js') const server = express() server.use(express.json()); server.get('/', (req, res) => { res.send({ api: 'up and running...' }) }) server.get('/hubs', (req, res) => { db .find() .then(...
true
79fd6dbc57a4ed7163dc0600cbf7dc71ffcb2614
JavaScript
ionescurobert/HashDefuse---DistributedComputing-SS2017
/mqAPI.js
UTF-8
1,118
2.59375
3
[]
no_license
let amqp = require('amqplib/callback_api'); function sendValue(hashValue, callback) { amqp.connect('amqp://localhost', function(err, conn) { conn.createChannel(function(err, ch) { let q = 'hashQueue'; ch.assertQueue(q, {durable: false}); ch.sendToQueue(q, new Buffer(has...
true
c80f3cd2537c363a363ded67b57128e6bfee2892
JavaScript
CaiSenYu-N/caishuo-learn-note
/work/十月/20181025/第二题/js/main.js
UTF-8
75
2.671875
3
[]
no_license
for(i=0; i<1000; i++) { if(i%5==0 || i%6==0){ console.log(i); }; }
true
e06fae321cd062bf422a45fb3e73224a48d3b4ca
JavaScript
pratyushongit/Knowledge
/Node JS/web-server/frontend/static/api.js
UTF-8
255
2.9375
3
[]
no_license
const axios = require('axios'); const forecast = async ()=>{ try{ let data = await axios.get('https://jsonplaceholder.typicode.com/todos/1'); console.log(data.data); } catch(error){ console.log(error); } } forecast();
true
f676239b887d321762fbc66357d031f6f9403336
JavaScript
Colambus13/love-triangle
/src/index.js
UTF-8
657
3.4375
3
[ "MIT" ]
permissive
/** * @param preferences - an array of integers. Indices of people, whom they love * @returns number of love triangles */ module.exports = function getLoveTrianglesCount(preferences = []) { var counter = 0; var prev_first_lover, pre_prev_first_lover, pre_pre_prev_first_lover; preferences...
true
1319a1cf939db5e89d9c8bf46ca4df247d20037f
JavaScript
ViniciusGarciaSilva/izi-serv
/src/components/list-sprints.component.js
UTF-8
2,637
2.6875
3
[]
no_license
import React, { Component } from 'react'; import { Button, Container, Table } from 'semantic-ui-react' import SprintComponent from './sprint.component'; import { Sprint } from './../model/sprint'; class ListSprint extends Component { constructor(props) { super(props); this.state = { sprintList: this.pr...
true
b417a3ecd838a5a87e4694b01bd2e26dd371c163
JavaScript
djwendo/tweeter
/public/scripts/app.js
UTF-8
2,406
2.890625
3
[]
no_license
$(() => { function createTweetElement(tweet) { const username = tweet.user.name; const handle = tweet.user.handle; const avatar = tweet.user.avatars.small const text = tweet.content.text const time = moment(tweet.created_at).fromNow(); const $tweet = $('<article>').addClass('tweet'); co...
true
db8a11c46b080c9ba3800ea26b94b4beea1a54b3
JavaScript
skiephole/starwars-opdracht-Christiaan-Bakker
/starwars-opdracht/src/CharInfo.jsx
UTF-8
1,536
2.8125
3
[]
no_license
import React, {Component} from 'react'; class CharInfo extends Component { //constructor with expanded state stored in it. This expanded state is used to open en close the details of the people constructor(props) { super(props); this.state = { expanded: false, } th...
true
e6103a018cb10a1c1ef45f9b9d00ef3c31804cfc
JavaScript
jonathanjwatson/location-services-test
/assets/javascript/geolocation.js
UTF-8
1,637
3.078125
3
[]
no_license
var x = document.getElementById("demo"); // let latitude = ""; // let longitude = ""; // let token = "JkJPIZbtn3f9au9Wl19kuD2Z7zV7_s2fwxDX5pPVI-og8ItOVVXnXJdCKXEk_5OsWgCzgKnG6VTLSApMCoPxdkU0QlBiRmOxASmqJV8are3uqzYFCGecoyvWWOAlWnYx" // function ajaxCall(){ // $.ajax // ({ // url: `https://api.yelp.com/v3...
true
21523cfb99b23c0c9375afef352eb525bd2462b4
JavaScript
bdavidxyz/simple-tictactoe
/simple.js
UTF-8
1,709
3.3125
3
[]
no_license
function ttt_new_game() { var ttt_board = _.times(9, _.constant('.')); console.log(ttt_display_board(ttt_board)) _.times(4, function(){ ttt_turn(ttt_board) }) ttt_turn(ttt_board, {player1Only: true}) } function ttt_turn(ttt_board, options) { ttt_player_plays('', ttt_board, 'player1', 'x') if (!_....
true
3118ab50984419cf9bab3d2b07ffe94494d4fe4f
JavaScript
swc-project/swc
/crates/swc/tests/tsc-references/literalTypes3.1.normal.js
UTF-8
1,080
3.171875
3
[ "LicenseRef-scancode-unknown-license-reference", "Apache-2.0" ]
permissive
//// [literalTypes3.ts] function f1(s) { if (s === "foo") { s; // "foo" } if (s === "foo" || s === "bar") { s; // "foo" | "bar" } } function f2(s) { switch(s){ case "foo": case "bar": s; // "foo" | "bar" case "baz": s; // "foo" | "bar" ...
true
94f069c54239d25f9efaf99e38a3571d207276e2
JavaScript
Wayne-Bai/AST-normalize
/data/jsxgraph/jsxgraph/src/math/symbolic.js
UTF-8
14,479
2.625
3
[]
no_license
/* Copyright 2008-2013 Matthias Ehmann, Michael Gerhaeuser, Carsten Miller, Bianca Valentin, Alfred Wassermann, Peter Wilfahrt This file is part of JSXGraph. JSXGraph is free software dual licensed under the GNU LGPL or MIT License. You can redistri...
true
3b7db4ff169f28bbbcb55d2fe9a01f0bba2a0cb9
JavaScript
Margie91/bit-cs
/conditions/script1.js
UTF-8
105
3.375
3
[]
no_license
var num = 10; if(num % 2 === 0){ console.log('even'); } else { console.log("odd"); }
true
ad43a0d406be580ad93a683d5b6e1087590bdf45
JavaScript
nickboon/DiagramApp
/cubeTransformations.js
UTF-8
2,465
2.703125
3
[]
no_license
(function(app) { var transformations = app.createTransformationObject(), rotateAboutX = transformations.rotatePointAboutX, rotateAboutY = transformations.rotatePointAboutY, cubeGeometry = app.createCubeGeometryObject(), tiltAngle = cubeGeometry.angleBetweenFaceDiagonalAndCubeDiagonal...
true
6c5e7b8c0e5e381150fb5046abe8aae163564d7a
JavaScript
casukhelai/employee-generator
/index.js
UTF-8
5,061
3.640625
4
[ "MIT" ]
permissive
// require packages const inquirer = require("inquirer"); const fs = require("fs"); // require the team member JS scripts const Engineer = require("./lib/Engineer"); const Manager = require("./lib/Manager"); const Intern = require("./lib/Intern"); const { generateHTML } = require("./lib/generateHTML"); // ======== P...
true
45b9c11c2fc1af223a41ff7296a839d6d158c776
JavaScript
dmitriy-kd/js-html-blocks-render
/src/templates.js
UTF-8
1,306
2.65625
3
[]
no_license
import {row, col, css} from './utils' function title(block) { /*return ` <div class="row"> <div class="col-sm"> <h1>${block.value}</h1> </div> </div> ` */ //const tag = block.options.tag ?? 'h1' //const styles = block.options.styles const {tag = 'h1', styles} = block.options return row(col(`<${tag...
true
eaadb4f67ac7908e52a07db9f2e808ac10e06e1a
JavaScript
b2renger/b2renger.github.io
/c_spring.js
UTF-8
2,431
2.890625
3
[]
no_license
/* adapted from : // M_6_1_02.pde // Spring.pde // // Generative Gestaltung, ISBN: 978-3-87439-759-9 // First Edition, Hermann Schmidt, Mainz, 2009 // Hartmut Bohnacker, Benedikt Gross, Julia Laub, Claudius Lazzeroni // Copyright 2009 Hartmut Bohnacker, Benedikt Gross, Julia Laub, Claudius Lazzeroni // // http://www.g...
true
0e20a76c8f08304885e640e83ec6780e1f601273
JavaScript
computer-coder/Newtons-Cradle
/sketch.js
UTF-8
1,195
2.640625
3
[]
no_license
const Engine = Matter.Engine; const World = Matter.World; const Bodies = Matter.Bodies; const Body = Matter.Body; const Constraint = Matter.Constraint; var ball, roof, chain; function preload() {} function setup() { createCanvas(800, 700); engine = Engine.create(); world = engine.world; ball1 = new Ball(150...
true
c81fdf1005f81ce0846a760430bc70813f4b92c3
JavaScript
everthis/leetcode-js
/2412-minimum-money-required-before-transactions.js
UTF-8
277
3.25
3
[ "MIT" ]
permissive
/** * @param {number[][]} transactions * @return {number} */ const minimumMoney = function(transactions) { let res = 0; let v = 0; for (const a of transactions) { v = Math.max(v, Math.min(a[0], a[1])); res += Math.max(a[0] - a[1], 0); } return res + v; };
true
e4471edd592c2626c7588b376b290b4cfb6bfd0f
JavaScript
BrunoCaribe/programacao_web
/Feito em sala/js/Desafio4.js
UTF-8
1,947
3.9375
4
[]
no_license
var isTruthy = (value) => { if (value) { console.log(true) } else { console.log(false) } } isTruthy(0) isTruthy(null) isTruthy(undefined) isTruthy(false) isTruthy(NaN) isTruthy(1) isTruthy({}) isTruthy(true) isTruthy(1 + "2555555") isTruthy(2) isTruthy(3) isTruthy(4) isTruthy("teste") isTr...
true
d931e27531ca226e033efa18d178487fd6c1d71f
JavaScript
Mystogab/mopal-web
/js/spa.js
UTF-8
6,303
2.640625
3
[]
no_license
document.addEventListener('DOMContentLoaded', init, false); let data = {}; //Initial function to load default data on page function init () { //Load to headers of all API request data.headers = {}; data.headers.token = localStorage.mopalToken; //Load API URL: data.apiUrl = 'http://gabpc.ddns.net:3000/'; /...
true
7259b9f2794bf58cf3c6af79efe5c5ae0fb40cf9
JavaScript
dictadata/storage-junctions
/test/test_finally.js
UTF-8
550
3.5625
4
[ "MIT" ]
permissive
#!/usr/bin/env node function thecode() { try { console.log("trying outer"); try { console.log("trying inner"); throw new Error('oops'); return "gotcha"; } catch (ex) { console.error('inner', ex.message); return "no throw"; throw ex; } finally { console.log...
true
8d370f54b74508af63810962503b8fae87ae476e
JavaScript
fabianchoxD/ReactJsCurso
/State_en_React/index.js
UTF-8
837
3.4375
3
[]
no_license
// Contador class Counter extends React.Component { // Inicializamos nuestro estado constructor(props) { // ESTA LINEA SIEMPRE DEBE DE SER LA PRIMERA EN EL // CONSTRUCTOR super(props); this.onClick = this.onClick.bind(this); // Inicializamos el estado. Aquí creamos el objeto // dir...
true
df7354cec8418d479d7fc698ef4d69ba3d14b540
JavaScript
sirajpathan/parking-lot-express
/src/module/request-validator.js
UTF-8
2,018
2.609375
3
[ "MIT" ]
permissive
import {} from 'dotenv/config'; import Auth from './auth'; class RequestValidator extends Auth { constructor () { super(); this.MAX_REQUESTS = process.env.MAX_REQUESTS; this.REQUEST_DURATION = process.env.REQUEST_DURATION; this.userRequests = {}; setInterval(this._removeOldEnt...
true
c71e8b4b9e4a08eac02e0b59af69e9c943a61139
JavaScript
jadowdl/shengmeng-sig2020-snake
/Interface.js
UTF-8
1,664
2.640625
3
[]
no_license
const PULSE_TIME = 20; // milliseconds // Some chatter that Contants.manifest needs to come from a different package? import Constants from "expo-constants"; const { manifest } = Constants; // https://docs.expo.io/workflow/how-expo-works/ // https://create-react-app.dev/docs/proxying-api-requests-in-development/ - do...
true
61b52e1184c0139514f27a214de3f40ea968895f
JavaScript
ptomas16674/Fondo_Curioso
/js/javascript.js
UTF-8
878
3.578125
4
[]
no_license
var tabla=document.getElementById("tabla"); var numero=Math.floor(Math.random(20,5) * 10 +1); function crearFondo(elemento,n,n1,n2){ elemento.style.backgroundColor="rgb("+Math.floor(Math.random() * 255 +1)+","+Math.floor(Math.random() * 255 +1)+","+Math.floor(Math.random() * 255 +1)+")"; } function crearTabla(ntr...
true
1adc68148bb3128ff7e4c07d5e422a05cfc9486f
JavaScript
heymonicakay/holiday-road
/scripts/weather/WeatherList.js
UTF-8
792
2.953125
3
[]
no_license
import { WeatherCard } from "./WeatherCard.js" import { getWeatherData, getZip } from "./WeatherProvider.js"; import { qs } from "../utils.js" const weatherTarget = qs(".container--five-day"); const WeatherList = (data) => { let weatherHTML = ` <h3 class="heading--forecast">5-Day Forecast</h3> <h3...
true
96d5693b880fad1ed16dfe091123723e2b3b6475
JavaScript
christabella/code-test
/sample2/scripts/main.js
UTF-8
3,063
2.84375
3
[ "MIT" ]
permissive
var timer = null, time = 0, width = String($(window).width()), height = String($(window).height()); if (!Cookies.get('sessionId')) { var sessionId = ""; for (i = 0; i < 21; i++) { sessionId += Math.floor(Math.random()*10); if ((i == 5) || (i == 12)) { sessionId += "-"; ...
true
3bd5cbe3da4839abbedc1f90f9509464c9aca036
JavaScript
BryantH24/SPCH
/no-bad-word/src/pages/editor.js
UTF-8
2,080
2.75
3
[]
no_license
import React, { useState } from "react"; import { Container, Col, Button, Row } from "react-bootstrap"; import "../styles/editor.css"; import axios from "axios"; import { HighlightWithinTextarea } from "react-highlight-within-textarea"; export default function Editor() { const [state, setState] = useState(""); con...
true
c823956612d3e4ef5fb1a043eac0cabfc3212531
JavaScript
matlakh/odin-project
/Chapter_02-Web_Development_101/euler_in_javascript/problem_2.js
UTF-8
969
4.78125
5
[]
no_license
// Each new term in the Fibonacci sequence is generated by adding the previous two terms. By starting with 1 and 2, the first 10 terms will be: // 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, ... // By considering the terms in the Fibonacci sequence whose values do not exceed four million, find the sum of the even-valued terms...
true
6de5e8436591ac0b91f2077b2149ecdc3a319373
JavaScript
gcht/my-reflux-demo
/js/reflux.js
UTF-8
621
2.53125
3
[]
no_license
'use strict'; import React from 'react'; import Reflux from 'reflux'; import {render} from 'react-dom'; const action = Reflux.createActions(['getHello']); const store = Reflux.createStore({ listenables: [action], onGetHello: function (hello) { this.trigger(hello); } }); const App = React.crea...
true
04458369bd61976aabe54b6521b639dfa7a7f2ac
JavaScript
mckCodingProjects/still57
/views/contact/contact.js
UTF-8
2,400
2.65625
3
[]
no_license
//const socket = io(); // //socket.on('connect', function() { // console.log('Connected to server.'); //}); //socket.on('disconnect', function() { // console.log('Disconnected from server.'); //}); // //(function() { // 'use strict'; // window.addEventListener('load', function() { // // Fetch all the forms w...
true
4dc035998960320f09135449b34c7c9a9aa3f2ed
JavaScript
maeldonn/pendu
/src/App.js
UTF-8
5,295
2.890625
3
[]
no_license
import React, { Component } from 'react'; import './App.css'; import Score from './Score'; import Letter from './Letter'; import Keyboard from './Keyboard'; import GameOver from './GameOver'; const KEYBOARD = ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V'...
true
8c9f0fc0cd9d7a68cedfd5e670b6a743a70d21d5
JavaScript
Sohaildangol130/Airbnb-clone
/assets/js/future_getaways.js
UTF-8
2,086
2.9375
3
[]
no_license
var $future_getaways__links_container = document.querySelectorAll('.future-getaways__links-container>p'); var $future_getaways__main_container = document.querySelectorAll('.future-getaways__main-container>div'); active = (id) => { for (let i = 0; i<$future_getaways__links_container.length; i++){ if ($futur...
true
aae38e2fcd6e59b8d5590f3b5c49197aad488201
JavaScript
karsrhyder/SwarmCityShort
/shareableHashtagLinkService.js
UTF-8
8,567
2.59375
3
[]
no_license
const express = require('express') const shortid = require('shortid') const fs = require('fs') const level = require('level') const renderQ = level('./hashtagRenderQ') const PORT = process.env.PORT || 8090 const app = express(); const cors = require('cors') const browserPagePool = require('./services/browserPagePool.js...
true
a9475b2be1a8884b10ea01d85bf7a15b7945e071
JavaScript
golemhq/golem
/golem/gui/static/js/list/test_list.js
UTF-8
827
2.515625
3
[ "MIT", "CC-BY-4.0" ]
permissive
$(document).ready(function() { TestList.getTests(Global.project) }); const TestList = new function() { this.getTests = function(projectName) { xhr.get('/api/project/test-tree', {'project': projectName}, tests => { FileExplorer.initialize(tests, 'test', $('#fileExporerContainer')[0]); ...
true
8e6ae89e3bb61541508fedd23afce55d145a325c
JavaScript
kevinokerlund/scroll-block
/src/viewport-lock.js
UTF-8
1,541
2.609375
3
[ "MIT" ]
permissive
import * as Bars from './scrollbar-detector.js'; const html = document.querySelector('html'); const styleNamesWeUse = [ 'overflow', 'position', 'width', 'top', 'left' ]; const htmlLockStyles = { overflowY: 'auto', overflowX: 'auto', position: 'fixed', width: '100%', top: undefined, left: undefined }; let...
true
b6bbc1963d170e7d445a0afc2e6aeec30702fc90
JavaScript
suhas-nithyanand/Grade-Management-System
/client/app/features/teacher/teacher.controller.js
UTF-8
4,038
2.765625
3
[]
no_license
(function() { 'use strict'; angular .module('grade-management') .controller('TeacherController', [ '$http','gradesService','courseService','studentsService', TeacherController ]); function TeacherController($http,gradesService,courseService,studentsService)...
true
d220271d8d65fd46d09ee9b86604b38f280d13d3
JavaScript
foreza/learn-code
/Arcade/intro/isLucky.js
UTF-8
879
4.03125
4
[]
no_license
n isLucky(n) { var str = n.toString(); var firstHalf = ""; var secondHalf = ""; // Do input checking here. // If the number is odd, this is not going to be a lucky number. if (n.length % 2 == 0){ return false; } // Split the string in half based off of length ...
true