commit
stringlengths
40
40
old_file
stringlengths
4
264
new_file
stringlengths
4
264
old_contents
stringlengths
0
3.26k
new_contents
stringlengths
1
4.43k
subject
stringlengths
15
624
message
stringlengths
15
4.7k
lang
stringclasses
3 values
license
stringclasses
13 values
repos
stringlengths
5
91.5k
dbd5d56fe2fa39c89d063bfbbf0f0fdfedae8168
packages/lesswrong/server/mapsUtils.js
packages/lesswrong/server/mapsUtils.js
import { getSetting } from 'meteor/vulcan:core'; import googleMaps from '@google/maps' const googleMapsApiKey = getSetting('googleMaps.serverApiKey', null) let googleMapsClient = null if (googleMapsApiKey) { googleMapsClient = googleMaps.createClient({ key: googleMapsApiKey, Promise: Promise }); } else { ...
import { getSetting } from 'meteor/vulcan:core'; import googleMaps from '@google/maps' const googleMapsApiKey = getSetting('googleMaps.serverApiKey', null) let googleMapsClient = null if (googleMapsApiKey) { googleMapsClient = googleMaps.createClient({ key: googleMapsApiKey, Promise: Promise }); } else { ...
Improve error handling without API key
Improve error handling without API key
JavaScript
mit
Discordius/Telescope,Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope
4961e4c984cee1c13f15966b670fccb0360391ee
src/main/web/js/app/pym-interactive.js
src/main/web/js/app/pym-interactive.js
$(function() { $('div.pym-interactive').each(function(index, element) { new pym.Parent($(element).attr('id'), $(element).data('url')); }); });
$(function() { $('div.pym-interactive').each(function(index, element) { var pymParent = new pym.Parent($(element).attr('id'), $(element).data('url')); pymParent.onMessage('height', function(height) { addIframeHeightToEmbedCode($(this), height); }); }); }); function addIfram...
Build embed code including height attrbute on height message from pym child
Build embed code including height attrbute on height message from pym child
JavaScript
mit
ONSdigital/babbage,ONSdigital/babbage,ONSdigital/babbage,ONSdigital/babbage
91c61c8d9ad1fc6ed7561f95de347334ea387f04
app/assets/javascripts/frontend.js
app/assets/javascripts/frontend.js
// Frontend manifest //= require transactions //= require media-player-loader //= require checkbox-filter //= require support //= require live-search //= require shared_mustache //= require templates //= require track-external-links //= require search
// Frontend manifest // Note: The ordering of these JavaScript includes matters. //= require transactions //= require media-player-loader //= require checkbox-filter //= require support //= require live-search //= require shared_mustache //= require templates //= require track-external-links //= require search
Add comment: explain JS deps ordering matters
Add comment: explain JS deps ordering matters Make it clear to others looking at the frontend.js file that the ordering of the JS includes matters.
JavaScript
mit
alphagov/frontend,alphagov/frontend,alphagov/frontend,alphagov/frontend
e781a6a037ae7f7888b84d6f83801305bf2d1205
plugins/auth/flat_file.js
plugins/auth/flat_file.js
// Auth against a flat file exports.register = function () { this.inherits('auth/auth_base'); } exports.hook_capabilities = function (next, connection) { // don't allow AUTH unless private IP or encrypted if (!net_utils.is_rfc1918(connection.remote_ip) && !connection.using_tls) return next(); var conf...
// Auth against a flat file var net_utils = require('./net_utils'); exports.register = function () { this.inherits('auth/auth_base'); } exports.hook_capabilities = function (next, connection) { // don't allow AUTH unless private IP or encrypted if (!net_utils.is_rfc1918(connection.remote_ip) && !connectio...
Fix ReferenceError: net_utils is not defined reported on IRC
Fix ReferenceError: net_utils is not defined reported on IRC
JavaScript
mit
craigslist/Haraka,hiteshjoshi/my-haraka-config,AbhilashSrivastava/haraka_sniffer,Synchro/Haraka,danucalovj/Haraka,hatsebutz/Haraka,typingArtist/Haraka,hatsebutz/Haraka,pedroaxl/Haraka,craigslist/Haraka,MignonCornet/Haraka,MignonCornet/Haraka,fredjean/Haraka,MignonCornet/Haraka,typingArtist/Haraka,Dexus/Haraka,slattery/...
67830a4214f33ee1e9c94fdfc5dd27747563579e
src/app/api/Actions.js
src/app/api/Actions.js
import { REQUESTING, RECEIVE_TOP_RATED, RECEIVE_NOW_SHOWING, RECEIVE_POPULAR } from "./ActionTypes" export function request() { return { type: REQUESTING } } export function receivedNowShowing(data) { return { type: RECEIVE_NOW_SHOWING, data } } export function receivedPopular(data) { return { type:...
import { REQUESTING, RECEIVE_TOP_RATED, RECEIVE_NOW_SHOWING, RECEIVE_POPULAR } from "./ActionTypes" export function request() { return { type: REQUESTING } } export function receivedNowShowing(data) { return { type: RECEIVE_NOW_SHOWING, data } } export function receivedPopular(data) { return { type:...
Use proper action type for different movies
Use proper action type for different movies
JavaScript
mit
Guru107/test_app
b0bc5f4bbef6c297119146f3528bfdb15138a4fd
test/minify/config.js
test/minify/config.js
// just to make sure this file is being minified properly var foobar = (function() { var anotherLongVariableName = "foo"; var baz = "baz"; return anotherLongVariableName + baz; }()); System.paths.foo = "bar";
// just to make sure this file is being minified properly // this code is a noop meant to force UglifyJS to include the // `anotherLongVariableName` (with the mangle flag off) in the minified code // for testing purposes var anotherLongVariableName; function funcName(firstLongName, lastLongName) { anotherLongVariab...
Adjust code to workaround UglifyJS dead code removal
Adjust code to workaround UglifyJS dead code removal
JavaScript
mit
stealjs/steal-tools,stealjs/steal-tools
5124396ada1aa788d80403b4056c675b6324ba34
src/client/app/boot.js
src/client/app/boot.js
import Application from './components/application'; import logger from 'debug'; import React from 'react'; import { Provider } from 'react-redux'; import startRouter from './router'; import { configureStore } from './store.js'; import en from './locales/en'; import fr from './locales/fr'; const debug = logger('app:bo...
import Application from './components/application'; import logger from 'debug'; import React from 'react'; import { Provider } from 'react-redux'; import startRouter from './router'; import { configureStore } from './store.js'; import en from './locales/en'; import fr from './locales/fr'; const debug = logger('app:bo...
Set allowMissing based on environment
Set allowMissing based on environment
JavaScript
mit
jsilvestre/tasky,jsilvestre/tasky,jsilvestre/tasky
5807a4997fb651adba6665ccf9f7edf1517c86d8
test/registry.spec.js
test/registry.spec.js
import test from 'ava'; test.todo('Write test for Registry');
import test from 'ava'; import Registry from '../src/registry'; test('Registry returns a registry', t => { let registry = Registry([document.body]); t.deepEqual(registry, { current: [], elements: [document.body], handlers: { enter: [], exit: [] }, singles: { enter: [], exit: [] ...
Add initial tests for Registry
Add initial tests for Registry
JavaScript
mit
kudago/in-view,camwiegert/in-view
67d8f92bc99e95ec0c567250eae0f8aca5cadd76
app/components/organization/Welcome.js
app/components/organization/Welcome.js
import React from 'react'; import PipelineIcon from '../icons/Pipeline'; class Welcome extends React.Component { static propTypes = { organization: React.PropTypes.string.isRequired } render() { return ( <div className="center p4"> <PipelineIcon /> <h1 className="h3 m0 mt2 mb4">Cr...
import React from 'react'; import PipelineIcon from '../icons/Pipeline'; class Welcome extends React.Component { static propTypes = { organization: React.PropTypes.string.isRequired } render() { return ( <div className="center p4"> <PipelineIcon /> <h1 className="h3 m0 mt2 mb4">Cr...
Make 'example pipelines' link the same blue link
Make 'example pipelines' link the same blue link
JavaScript
mit
fotinakis/buildkite-frontend,buildkite/frontend,fotinakis/buildkite-frontend,buildkite/frontend
ebccc846b56b4591a011666953a6ad75ef35fabc
src/components/Head.js
src/components/Head.js
import React from 'react' export default class Head extends React.Component { render() { return ( <head> <meta charSet="utf-8"/> <meta httpEquiv="X-UA-compatible" content="IE=edge, chrome=1"/> <meta name="viewport" content="width=device-width, initial-s...
import React from 'react' export default class Head extends React.Component { render() { return ( <head> <meta charSet="utf-8"/> <meta httpEquiv="X-UA-compatible" content="IE=edge, chrome=1"/> <meta name="viewport" content="width=device-width, initial-s...
Add type text/css to stylesheet
Add type text/css to stylesheet
JavaScript
mit
mlcdf/website,mlcdf/website
fab4325bf85c8aa4386464b09781d385b07f5c77
src/browser_tools/chrome_new_tab_pretty.user.js
src/browser_tools/chrome_new_tab_pretty.user.js
// ==UserScript== // @name Chrome New Tab Prettify. // @namespace https://github.com/kilfu0701 // @version 0.1 // @description Prettify UI on Chrome new tab. // @author kilfu0701 // @match /^http[s]?:\/\/www.google*/ // @run-at document-ready // @include /^http[s]?:\/\/www.googl...
// ==UserScript== // @name Chrome New Tab Prettify. // @namespace https://github.com/kilfu0701 // @version 0.1 // @description Prettify UI on Chrome new tab. // @author kilfu0701 // @match /^http[s]?:\/\/www.google*/ // @run-at document-ready // @include /^http[s]?:\/\/www.googl...
Hide logo and search bar in chrome new tab.
Hide logo and search bar in chrome new tab.
JavaScript
mit
kilfu0701/thk-user-script
6cf484c9a3ce5aa141363ae67c58fa94d055a105
app/assets/javascripts/app/views/bookmarklet_view.js
app/assets/javascripts/app/views/bookmarklet_view.js
app.views.Bookmarklet = Backbone.View.extend({ separator: ' - ', initialize: function(opts) { // init a standalone publisher app.publisher = new app.views.Publisher({standalone: true}); app.publisher.on('publisher:add', this._postSubmit, this); app.publisher.on('publisher:sync', this._postSuccess,...
app.views.Bookmarklet = Backbone.View.extend({ separator: ' - ', initialize: function(opts) { // init a standalone publisher app.publisher = new app.views.Publisher({standalone: true}); app.publisher.on('publisher:add', this._postSubmit, this); app.publisher.on('publisher:sync', this._postSuccess,...
Make sure publisher is totally hidden in bookmarklet after post success
Make sure publisher is totally hidden in bookmarklet after post success
JavaScript
agpl-3.0
geraspora/diaspora,jhass/diaspora,Flaburgan/diaspora,diaspora/diaspora,Amadren/diaspora,diaspora/diaspora,geraspora/diaspora,despora/diaspora,Amadren/diaspora,Amadren/diaspora,Muhannes/diaspora,SuperTux88/diaspora,jhass/diaspora,KentShikama/diaspora,spixi/diaspora,jhass/diaspora,SuperTux88/diaspora,SuperTux88/diaspora,...
829082a9fdb07be6892b9fc552e874e9b1eeb81c
addon/components/data-visual.js
addon/components/data-visual.js
import Ember from 'ember'; import layout from '../templates/components/data-visual'; import Stage from '../system/stage'; export default Ember.Component.extend({ classNames: [ 'data-visual' ], layout, width: 300, height: 150, stage: null, initializeGraphicsContext() { var element = this.element; ...
import Ember from 'ember'; import Stage from '../system/stage'; export default Ember.Component.extend({ classNames: [ 'data-visual' ], width: 300, height: 150, stage: null, initializeGraphicsContext() { var element = this.element; var fragment = document.createDocumentFragment(); Stage.stage...
Remove explicit layout; too eager
Remove explicit layout; too eager
JavaScript
mit
ming-codes/ember-cli-d3,ming-codes/ember-cli-d3
f073042945f2f876cccc35c59c4eff0b0cfb4535
app/assets/javascripts/bootstrap-dropdown-submenu.js
app/assets/javascripts/bootstrap-dropdown-submenu.js
$(document).ready(function () { $('ul.dropdown-menu [data-toggle=dropdown]').on('click', function (event) { event.preventDefault(); event.stopPropagation(); $(this).parent().addClass('open'); var menu = $(this).parent().find("ul"); var menupos = menu.offset(); if ((menupos.left + menu.width(...
$(document).ready(function () { function openSubMenu(event) { if (this.pathname === '/') { event.preventDefault(); } event.stopPropagation(); $(this).parent().addClass('open'); var menu = $(this).parent().find("ul"); var menupos = menu.offset(); if ((menupos.left + menu.width()) +...
Enable menu access on hover and links from section titles
Enable menu access on hover and links from section titles
JavaScript
bsd-3-clause
openHPI/codeocean,openHPI/codeocean,openHPI/codeocean,openHPI/codeocean,openHPI/codeocean,openHPI/codeocean
70b62a39c353ff3ebe4847868feb24907d27cea3
app/assets/javascripts/lga_filter.js
app/assets/javascripts/lga_filter.js
$(function() { $('#lga_filter').keyup(function(ev) { var list = $('#lga_list'); var filter = $(this).val(); if (filter === '') { // Show all when the filter is cleared list.find('div.lga').show(); } else { // Hide all LGAs that don't match the filter var filterRegexp = new Reg...
$(function() { function strip(from) { if(from !== undefined) { from = from.replace(/^\s+/, ''); for (var i = from.length - 1; i >= 0; i--) { if (/\S/.test(from.charAt(i))) { from = from.substring(0, i + 1); break; } } return from; } else ...
Fix filter bugs for council list filter
Fix filter bugs for council list filter
JavaScript
apache-2.0
NSWPlanning/data-verification-tool,NSWPlanning/data-verification-tool,NSWPlanning/data-verification-tool
10ce33fdc1035c764f27c69562b8f2a409e419fa
src/server/routes.js
src/server/routes.js
const listenerUser = require ('./listenerUser'); const listenerApp = require ('./listenerApp'); // Initialize routes. function init (app) { listenerUser.init (); listenerApp.init (); app.post ('/api/login', listenerUser.login); app.post ('/api/logout', listenerUser.logout); app.get ('/api/verifylogin', list...
const listenerUser = require ('./listenerUser'); const listenerApp = require ('./listenerApp'); // Initialize routes. function init (app) { listenerUser.init (); listenerApp.init (); app.post ('/api/login', listenerUser.login); app.post ('/api/logout', listenerUser.logout); app.get ('/api/verifylogin', list...
Correct return handling for authentication middleware function
Correct return handling for authentication middleware function
JavaScript
mit
fcc-joemcintyre/pollster,fcc-joemcintyre/pollster,fcc-joemcintyre/pollster
344b2d6018ba63f139da4529978587e209d9566b
lib/run_cmd.js
lib/run_cmd.js
'use strict' var path = require('path') var async = require('async') var config = require('./config') var child_process = require('child_process') function runCmd (cwd, argv) { var scripts = argv._.slice(1) var pkg = require(path.join(cwd, 'package.json')) if (!scripts.length) { var availableScripts = Obje...
'use strict' var path = require('path') var async = require('async') var config = require('./config') var child_process = require('child_process') var assign = require('object-assign') function runCmd (cwd, argv) { var scripts = argv._.slice(1) var pkg = require(path.join(cwd, 'package.json')) if (!scripts.len...
Refactor env in run command
Refactor env in run command
JavaScript
mit
alexanderGugel/ied,alexanderGugel/mpm
e7477b991a2f452d25ac35475e8adecceb7fac85
2017/01.js
2017/01.js
// Part 1 [...document.body.textContent.trim()].reduce((s,c,i,a)=>(c==a[(i+1)%a.length])*c+s,0) // Part 2 [...document.body.textContent.trim()].reduce((s,c,i,a)=>(l=>c==a[(i+l/2)%l])(a.length)*c+s,0)
// Part 1 [...document.body.innerText.trim()].reduce((s,c,i,a)=>(c==a[(i+1)%a.length])*c+s,0) // Part 2 [...document.body.innerText.trim()].reduce((s,c,i,a)=>(l=>c==a[(i+l/2)%l])(a.length)*c+s,0)
Use body.innerText instead of textContent
Use body.innerText instead of textContent
JavaScript
mit
yishn/adventofcode,yishn/adventofcode
fce850eeb8b91f00d4cdeaf7cfa3d74e7b47b4c0
lib/cli/src/generators/WEB-COMPONENTS/template-csf/.storybook/preview.js
lib/cli/src/generators/WEB-COMPONENTS/template-csf/.storybook/preview.js
/* global window */ import { configure, addParameters, // setCustomElements, } from '@storybook/web-components'; // import customElements from '../custom-elements.json'; // setCustomElements(customElements); addParameters({ docs: { iframeHeight: '200px', }, }); // configure(require.context('../storie...
// import { setCustomElements } from '@storybook/web-components'; // import customElements from '../custom-elements.json'; // setCustomElements(customElements);
Fix project template for web-components
CLI: Fix project template for web-components
JavaScript
mit
storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook
702c888a12716d96f7382fbf2d995fbaf4243a4a
store/search/quick-search/index.js
store/search/quick-search/index.js
let SearchStore = require('../search-store'); /** * Class standing for all advanced search information. * The state should be the complete state of the page. */ class QuickSearchStore extends SearchStore{ constructor(conf){ conf = conf || {}; conf.definition = { query: 'query', scope: 'scope', ...
let SearchStore = require('../search-store'); /** * Class standing for all advanced search information. * The state should be the complete state of the page. */ class QuickSearchStore extends SearchStore{ constructor(conf){ conf = conf || {}; conf.definition = { query: 'query', scope: 'scope', ...
Add missing property, the facets (used for group counts)
[quick-search-store] Add missing property, the facets (used for group counts)
JavaScript
mit
Jerom138/focus,KleeGroup/focus-core,Jerom138/focus,Jerom138/focus
8599b9c74d4273843cb5ae4f11a5799c2f1f8cc5
koans/AboutPromises.js
koans/AboutPromises.js
describe("About Promises", function () { describe("Asynchronous Flow", function () { it("should understand promise declaration usage", function () { }); }); });
describe("About Promises", function () { describe("Asynchronous Flow", function () { it("should understand promise usage", function () { function isZero(number) { return new Promise(function(resolve, reject) { if(number === 0) { resolve(); } else { reje...
Add type test for promises
feat: Add type test for promises
JavaScript
mit
tawashley/es6-javascript-koans,tawashley/es6-javascript-koans,tawashley/es6-javascript-koans
bf32038659afa4a77cdd79c59c52d9a9adb9b1d8
lathe/js/box-colors.js
lathe/js/box-colors.js
/* eslint-env es6 */ /* global THREE */ window.applyBoxVertexColors = (function() { 'use strict'; return function vertexColors( geometry ) { const red = new THREE.Color( '#f00'); const green = new THREE.Color( '#0f0' ); const blue = new THREE.Color( '#00f' ); geometry.faces.forEach( face => { ...
/* eslint-env es6 */ /* global THREE, Indices */ window.applyBoxVertexColors = (function() { 'use strict'; function setFaceVertexColor( face, index, color ) { if ( face.a === index ) { face.vertexColors[ 0 ] = color; } if ( face.b === index ) { face.vertexColors[ 1 ] = color; } if...
Add BoxGeometry vertex colors helper.
lathe[cuboid}: Add BoxGeometry vertex colors helper.
JavaScript
mit
razh/experiments-three.js,razh/experiments-three.js
41e40acc7a7afe8d5bde99ed41a730cd88d73e86
reddit/old-reddit-hide-offline-presence.user.js
reddit/old-reddit-hide-offline-presence.user.js
// ==UserScript== // @name Hide offline presence dot on old reddit // @namespace https://mathemaniac.org // @version 1.0 // @description Hides the offline presence dot from old reddit. Only hides offline presence, so you notice if you're displayed as online. https://old.reddit.com/r/changelog/comments/...
// ==UserScript== // @name Hide offline presence dot on old reddit // @namespace https://mathemaniac.org // @version 1.0.1 // @description Hides the offline presence dot from old reddit. Only hides offline presence, so you notice if you're displayed as online. https://old.reddit.com/r/changelog/comment...
Make script run on document start to help on dot flashes
Make script run on document start to help on dot flashes
JavaScript
mit
Eckankar/userscripts,Eckankar/userscripts
838745ae7fea6685498bab8b66a043090a582774
server/channels/__tests__/authAdmin.js
server/channels/__tests__/authAdmin.js
jest.mock('../../models/meeting'); jest.mock('../../utils'); const { emit, broadcast } = require('../../utils'); const { createGenfors } = require('../../models/meeting'); const { generateGenfors, generateSocket } = require('../../utils/generateTestData'); const { createGenfors: createGenforsListener } = require('../au...
jest.mock('../../models/meeting'); jest.mock('../../utils'); const { emit, broadcast } = require('../../utils'); const { createGenfors } = require('../../models/meeting'); const { generateGenfors, generateSocket } = require('../../utils/generateTestData'); const { createGenfors: createGenforsListener } = require('../au...
Make mocked admin password be a constant
Make mocked admin password be a constant
JavaScript
mit
dotkom/super-duper-fiesta,dotkom/super-duper-fiesta,dotkom/super-duper-fiesta
dcecb81dba5a938beb7be702f2ab2012f0545594
server/controllers/hotel-controller.js
server/controllers/hotel-controller.js
"use strict"; const HotelData = require("../data").hotel; const UserData = require("../data").users; const breedsData = require("../data/models/breeds"); function loadRegisterPage(req, res) { if(!req.isAuthenticated()){ return res.redirect("../auth/login"); } var user = req.user; res.render("hotel/re...
"use strict"; const HotelData = require("../data").hotel; const UserData = require("../data").users; const breedsData = require("../data/models/breeds"); function loadRegisterPage(req, res) { if (!req.isAuthenticated()) { return res.redirect("../auth/login"); } var user = req.user; ...
Fix redirect to home when add hotel.
Fix redirect to home when add hotel.
JavaScript
mit
ilian1902/Team-D-Animals-Hotel,ilian1902/Team-D-Animals-Hotel,knmitrofanov/animalshotel,knmitrofanov/animalshotel
e457d0dcb9af16528f6d84ff7b5c726edb2f1478
prolific.syslog/syslog.argv.js
prolific.syslog/syslog.argv.js
/* ___ usage ___ en_US ___ usage: prolific syslog <options> -a, --application <string> The application name to display in the syslog record. Defaults to the value of `process.title` which will always be `node`. -h, --hostname <string> The hostname to display...
/* ___ usage ___ en_US ___ usage: prolific syslog <options> -a, --application <string> The application name to display in the syslog record. Defaults to the value of `process.title` which will always be `node`. -h, --hostname <string> The hostname to display...
Add flag for new module loader.
Add flag for new module loader.
JavaScript
mit
bigeasy/prolific,bigeasy/prolific
651bc5ecf574d4716683343c9f543d88263fd4cb
models/base.js
models/base.js
var Arrow = require('arrow'); module.exports = Arrow.createModel('base', { connector: 'appc.redis', fields: { }, expire: function expire(seconds, callback){ return this.getConnector().expire(this.getModel(), this, seconds, callback); }, expireAt: function expireAt(date, callback){ ...
var Arrow = require('arrow'); var Base = Arrow.Model.extend('base', { connector: 'appc.redis', fields: { }, expire: function expire(seconds, callback){ return this.getConnector().expire(this.getModel(), this, seconds, callback); }, expireAt: function expireAt(date, callback){ re...
Switch out 'createModel' for 'extend'
Switch out 'createModel' for 'extend'
JavaScript
apache-2.0
titanium-forks/appcelerator.appc.redis
a25dadd4f4078965e647ec34265cdfe5fd879826
client/src/components/LastVotes.js
client/src/components/LastVotes.js
import React from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import css from './LastVotes.css'; import { voteWithNameSelector } from '../selectors/voting'; const LastVotes = ({ votes }) => ( <div className={css.component}> <h3>Siste stemmer</h3> { votes.length > 0 ? v...
import React from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import css from './LastVotes.css'; import { voteWithNameSelector } from '../selectors/voting'; import { activeIssueExists, getOwnVote, getIssueKey } from '../selectors/issues'; const LastVotes = ({ votes, hideVotes })...
Hide last votes unless there is an active issue with public votes and user has voted
Hide last votes unless there is an active issue with public votes and user has voted
JavaScript
mit
dotkom/super-duper-fiesta,dotkom/super-duper-fiesta,dotkom/super-duper-fiesta
ea7cba4da1698273cb0023c30ae4f00268129e1c
lib/tests/dashboard.js
lib/tests/dashboard.js
var Mocha = require('mocha'), _ = require('underscore'), moduleTest = require('./module'); module.exports = function (browser, dashboard, suite, config) { suite = Mocha.Suite.create(suite, dashboard.title); suite.beforeAll(function () { return browser.get(config.baseUrl + dashboard.slug) .$('bo...
var Mocha = require('mocha'), _ = require('underscore'), moduleTest = require('./module'); module.exports = function (browser, dashboard, suite, config) { suite = Mocha.Suite.create(suite, dashboard.title); suite.beforeAll(function () { return browser.get(config.baseUrl + dashboard.slug) .setWi...
Set window size to desktop display dimensions
Set window size to desktop display dimensions Some tests were failing because the default window dimensions cause the site to display in "mobile" format, truncating some elements and causing tests to fail.
JavaScript
mit
alphagov/cheapseats
07d763d5ce597abba1193cccee3ad7fca0d4cd97
plugins/cloudimport/templates/load_buttons.js
plugins/cloudimport/templates/load_buttons.js
PluginsAPI.Dashboard.addNewTaskButton( ["cloudimport/build/ImportView.js"], function(args, ImportView) { return React.createElement(ImportView, { onNewTaskAdded: args.onNewTaskAdded, projectId: args.projectId, apiURL: "{{ api_url }}", }); } ); PluginsA...
PluginsAPI.Dashboard.addNewTaskButton( ["cloudimport/build/ImportView.js"], function(args, ImportView) { return React.createElement(ImportView, { onNewTaskAdded: args.onNewTaskAdded, projectId: args.projectId, apiURL: "{{ api_url }}", }); } ); PluginsA...
Fix to show task button
Fix to show task button
JavaScript
agpl-3.0
pierotofy/WebODM,OpenDroneMap/WebODM,pierotofy/WebODM,pierotofy/WebODM,pierotofy/WebODM,OpenDroneMap/WebODM,OpenDroneMap/WebODM,OpenDroneMap/WebODM,OpenDroneMap/WebODM,pierotofy/WebODM
70b72554e264bb3d06f6116080252c20b19bce25
take-002-nodejs-server-clone/server.js
take-002-nodejs-server-clone/server.js
var express = require('express'), mongoose = require('mongoose'), app = express() app.set('port', process.env.PORT || 3000) app.set('mongodb-url', process.env.MONGODB_URL || 'mongodb://localhost/hangman') if ('test' === app.get('env')) { app.set('port', 9000) app.set('mongodb-url', 'mongodb://localhost/ha...
var express = require('express'), mongoose = require('mongoose'), util = require('util'), _ = require('lodash'), app = express() app.set('port', process.env.PORT || 3000) app.set('mongodb-url', process.env.MONGODB_URL || 'mongodb://localhost/hangman') if ('test' === app.get('env')) { app.set('port',...
Create User document after POST /me
[take-002] Create User document after POST /me
JavaScript
mit
gabrielelana/hangman-http-kata
1a573086b88669d8edf4097201d4df7ff53427ee
gulp/utils/notify.js
gulp/utils/notify.js
var notifier = new require("node-notifier")({}); var extend = require("extend"); var path = require("path"); var CFG = require("./config.js"); var pkg = require(path.join("..", "..", CFG.FILE.config.pkg)); module.exports = { defaults: { title: pkg.name }, showNotification: function (options)...
var notifier = new require("node-notifier"); var extend = require("extend"); var path = require("path"); var CFG = require("./config.js"); var pkg = require(path.join("..", "..", CFG.FILE.config.pkg)); module.exports = { defaults: { title: pkg.name }, showNotification: function (options) { ...
Update node-notifier initialization as per the new version.
Update node-notifier initialization as per the new version.
JavaScript
mit
rishabhsrao/remember,rishabhsrao/remember,rishabhsrao/remember
cde94167d2bb18a2873a943c7df25dd8258e117f
client/components/FileDescription.js
client/components/FileDescription.js
import React from 'react'; export default class FileDescription extends React.Component { render() { return <div className="file-description"> <span className="file-name">{this.props.file.name}</span> <span className="file-size">{this.props.file.size}</span> <span className="file-type">{this.p...
import React from 'react'; export default class FileDescription extends React.Component { render() { return <div className="file-description"> <span className="file-name">{this.props.file.name}</span> </div>; } }
Remove file size and type descriptors.
Remove file size and type descriptors.
JavaScript
bsd-3-clause
gramakri/filepizza,bradparks/filepizza_javascript_send_files_webrtc,hanford/filepizza,Ribeiro/filepizza,pquochoang/filepizza,jekrb/filepizza,codevlabs/filepizza,codebhendi/filepizza
930860fb4f12b720a15536b52685ba3beffa47c6
client/src/loading/loadingActions.js
client/src/loading/loadingActions.js
/* * Copyright (c) 2017 Bonnie Schulkin. All Rights Reserved. * * This file is part of BoxCharter. * * BoxCharter is free software: you can redistribute it and/or modify it under * the terms of the GNU Affero General Public License as published by the Free * Software Foundation, either version 3 of the License, ...
/* * Copyright (c) 2017 Bonnie Schulkin. All Rights Reserved. * * This file is part of BoxCharter. * * BoxCharter is free software: you can redistribute it and/or modify it under * the terms of the GNU Affero General Public License as published by the Free * Software Foundation, either version 3 of the License, ...
Add TODO for clear loading upon refresh
Add TODO for clear loading upon refresh
JavaScript
agpl-3.0
flyrightsister/boxcharter,flyrightsister/boxcharter
9ff4f729ba2970cd1407f47d7d1ceecc52dd7f61
lib/common/annotate.js
lib/common/annotate.js
define(['../is', '../array/last', '../functional'], function(is, last, functional) { var map = functional.map; var filter = functional.filter; var forEach = functional.forEach; function annotate() { var args = Array.prototype.slice.call(arguments); var fn = args.shift(); if(is....
define(['../is', '../array/last', '../functional'], function(is, last, functional) { var map = functional.map; var filter = functional.filter; var forEach = functional.forEach; function annotate() { var args = Array.prototype.slice.call(arguments); var fn = args.shift(); var doc...
Attach metadata to the right function
Attach metadata to the right function
JavaScript
mit
bebraw/funkit,bebraw/funkit
007bd9cd36f3d2069f5681245f4c80d28c3e0841
packages/core/database/lib/lifecycles.js
packages/core/database/lib/lifecycles.js
'use strict'; const createLifecyclesManager = db => { let subscribers = []; const lifecycleManager = { subscribe(subscriber) { // TODO: verify subscriber subscribers.push(subscriber); return () => { subscribers.splice(subscribers.indexOf(subscriber), 1); }; }, createE...
'use strict'; const createLifecyclesManager = db => { let subscribers = []; const lifecycleManager = { subscribe(subscriber) { // TODO: verify subscriber subscribers.push(subscriber); return () => { subscribers.splice(subscribers.indexOf(subscriber), 1); }; }, createE...
Fix return in for loop instead of continue
Fix return in for loop instead of continue
JavaScript
mit
wistityhq/strapi,wistityhq/strapi
3789c3c739f450188cdb50ffd25fe3099f8b458c
react/components/UI/LoadingIndicator/index.js
react/components/UI/LoadingIndicator/index.js
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import styled from 'styled-components'; import { space, width, height } from 'styled-system'; import { preset } from 'react/styles/functions'; import Text from 'react/components/UI/Text'; const Container = styled.div` box-sizing: border-...
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import styled from 'styled-components'; import { space, width, height } from 'styled-system'; import { preset } from 'react/styles/functions'; import Text from 'react/components/UI/Text'; const Container = styled.div` box-sizing: border-...
Support color/font size in loading indicator
Support color/font size in loading indicator
JavaScript
mit
aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell
753c56b41f2d7564dd660995d24606f17b0ffbbd
assets/src/stories-editor/helpers/test/addAMPExtraProps.js
assets/src/stories-editor/helpers/test/addAMPExtraProps.js
/** * Internal dependencies */ import { addAMPExtraProps } from '../'; describe( 'addAMPExtraProps', () => { it( 'does not modify non-child blocks', () => { const props = addAMPExtraProps( {}, { name: 'foo/bar' }, {} ); expect( props ).toStrictEqual( {} ); } ); it( 'generates a unique ID', () => { const p...
/** * Internal dependencies */ import { addAMPExtraProps } from '../'; describe( 'addAMPExtraProps', () => { it( 'does not modify non-child blocks', () => { const props = addAMPExtraProps( {}, { name: 'foo/bar' }, {} ); expect( props ).toStrictEqual( {} ); } ); it( 'adds a font family attribute', () => { ...
Remove tests that are not relevant anymore.
Remove tests that are not relevant anymore.
JavaScript
apache-2.0
ampproject/amp-toolbox-php,ampproject/amp-toolbox-php
0a77c621aed25a004b0347bf8adfdf1888dc554f
app-frontend/src/app/components/channelHistogram/channelHistogram.controller.js
app-frontend/src/app/components/channelHistogram/channelHistogram.controller.js
export default class ChannelHistogramController { constructor() { 'ngInject'; } $onInit() { this.histOptions = { chart: { type: 'lineChart', showLegend: false, showXAxis: false, showYAxis: false, mar...
export default class ChannelHistogramController { constructor() { 'ngInject'; } $onInit() { this.histOptions = { chart: { type: 'lineChart', showLegend: false, showXAxis: false, showYAxis: false, int...
Remove interactivity from cc histogram
Remove interactivity from cc histogram
JavaScript
apache-2.0
azavea/raster-foundry,azavea/raster-foundry,azavea/raster-foundry,aaronxsu/raster-foundry,aaronxsu/raster-foundry,raster-foundry/raster-foundry,raster-foundry/raster-foundry,aaronxsu/raster-foundry,aaronxsu/raster-foundry,azavea/raster-foundry,azavea/raster-foundry,raster-foundry/raster-foundry
f3d1753ded9f0ecf6c88252db1efa652e2ab632f
app/App.js
app/App.js
import React, { PropTypes } from 'react'; import { Link, IndexLink } from 'react-router'; import { Login } from 'auth'; import { ErrorHandler } from 'error'; import { rendered } from 'lib/fetchData'; export default class App extends React.Component { static propTypes = { children: PropTypes.object, }; comp...
import React, { PropTypes } from 'react'; import { Link, IndexLink } from 'react-router'; import { Login } from 'auth'; import { ErrorHandler } from 'error'; import { rendered } from 'lib/fetchData'; export default class App extends React.Component { static propTypes = { children: PropTypes.object, }; comp...
Add comment as to how important the call to render() is
Add comment as to how important the call to render() is
JavaScript
mit
terribleplan/isomorphic-redux-plus,isogon/isomorphic-redux-plus
ffeca8d1b1e312864f75e859babbc3a5abb53d8f
web/gulpfile.babel.js
web/gulpfile.babel.js
import bg from 'gulp-bg'; import eslint from 'gulp-eslint'; import gulp from 'gulp'; import runSequence from 'run-sequence'; import webpackBuild from './webpack/build'; const runEslint = () => { return gulp.src([ 'gulpfile.babel.js', 'src/**/*.js', 'webpack/*.js' // '!**/__tests__/*.*' ]) .pipe(e...
import bg from 'gulp-bg'; import eslint from 'gulp-eslint'; import gulp from 'gulp'; import runSequence from 'run-sequence'; import webpackBuild from './webpack/build'; import os from 'os'; const runEslint = () => { return gulp.src([ 'gulpfile.babel.js', 'src/**/*.js', 'webpack/*.js' // '!**/__tests_...
Fix gulp nodemon commang for windows environments
Fix gulp nodemon commang for windows environments original fix by @mannro
JavaScript
mit
Brainfock/este
981d520b780cbe87d05bca2448d6495ee15650aa
js/console-notes.js
js/console-notes.js
/** * Handles writting the notes to the browser console in synchronization with the reveal.js */ var ConsoleNotes = (function() { function log(event) { // event.previousSlide, event.currentSlide, event.indexh, event.indexv var notes = event.currentSlide.querySelector(".notes"); if (not...
/** * Handles writting the notes to the browser console in synchronization with the reveal.js */ var ConsoleNotes = (function() { function log(event) { // event.previousSlide, event.currentSlide, event.indexh, event.indexv var notes = event.currentSlide.querySelector(".notes"); if (not...
Remove load event handler for browser console speaker notes plugin
Remove load event handler for browser console speaker notes plugin
JavaScript
mit
itkoren/revealular,itkoren/revealular
cd3230171aa42b3eb574da1d06c0488face95001
tests/dummy/app/snippets/config-bootstrap-v4.js
tests/dummy/app/snippets/config-bootstrap-v4.js
const ENV = { // ... "ember-validated-form": { label: { submit: "Go for it!" }, css: { // bootstrap classes group: "form-group", radio: "radio", control: "form-control", label: "col-form-label", help: "small form-text text-danger", hint: "small form-text t...
const ENV = { // ... "ember-validated-form": { label: { submit: "Go for it!" }, css: { // bootstrap classes group: "form-group", radio: "radio", control: "form-control", label: "col-form-label", help: "small form-text text-danger", hint: "small form-text t...
Update bootstrap 4 config error class
Update bootstrap 4 config error class The error class used in `error`, not `invalid`.
JavaScript
mit
adfinis-sygroup/ember-validated-form,adfinis-sygroup/ember-validated-form,adfinis-sygroup/ember-validated-form
66ce8257b0164f8618b53d2fbe15bda4fa73fb33
src/prototype/off.js
src/prototype/off.js
define([ 'jquery', 'var/eventStorage', 'prototype/var/EmojioneArea' ], function($, eventStorage, EmojioneArea) { EmojioneArea.prototype.off = function(events, handler) { if (events) { var id = this.id; $.each(events.toLowerCase().replace(/_/g, '.').split(' '), function(i,...
define([ 'jquery', 'var/eventStorage', 'prototype/var/EmojioneArea' ], function($, eventStorage, EmojioneArea) { EmojioneArea.prototype.off = function(events, handler) { if (events) { var id = this.id; $.each(events.toLowerCase().replace(/_/g, '.').split(' '), function(i,...
Fix typo which causes memory leak.
Fix typo which causes memory leak.
JavaScript
mit
mervick/emojionearea
45255860bc78e5a90d7f6b3938c213628d8d6609
lib/bin.js
lib/bin.js
#!/usr/bin/env node var argv = require('argv'); var polyjuice = require('./polyjuice'); var options = [ { name: 'jshint', type: 'string', description: 'Defines the source file for jshint', example: '\'polyjuice --jshint .jshintrc\'' }, { name: 'jscs', type: 'string', description: 'De...
#!/usr/bin/env node var argv = require('argv'); var polyjuice = require('./polyjuice'); var options = [ { name: 'jshint', type: 'string', description: 'Defines the source file for jshint', example: '\'polyjuice --jshint=.jshintrc\'' }, { name: 'jscs', type: 'string', description: 'De...
Fix --help examples to include '='
Fix --help examples to include '=' Fixes #9
JavaScript
mit
brenolf/polyjuice
07059d2cc11db8cdddedc82de931c2c80d4faff4
lib/cli.js
lib/cli.js
'use strict'; const _ = require('lodash'); const updateNotifier = require('update-notifier'); /** * Expose a CLI with given actions as subcommands * @param {Array} actions Array of subclasses of Action * @param {Object} pkg The package.json contents * @returns {Array} */ module.exports = function (a...
'use strict'; const _ = require('lodash'); const updateNotifier = require('update-notifier'); /** * Expose a CLI with given actions as subcommands * @param {Array} actions Array of subclasses of Action * @param {Object} pkg The package.json contents * @returns {Array} */ module.exports = function (a...
Fix error caused by aliasing "v" to "version" on yargs
Fix error caused by aliasing "v" to "version" on yargs
JavaScript
mit
launchdeckio/shipment
0785140b62ddd655c4f472a157022b2c5a11164d
lib/git.js
lib/git.js
const spawn = require("./spawn"); module.exports = function(workDir, isDebug){ function git() { var len = arguments.length; var args = new Array(len); for (var i = 0; i < len; i++) { args[i] = arguments[i]; } return spawn('git', args, { cwd: workDir...
const spawn = require("./spawn"); module.exports = function(workDir, isDebug){ function git() { var len = arguments.length; var args = new Array(len); for (var i = 0; i < len; i++) { args[i] = arguments[i]; } return spawn('git', args, { cwd: workDir...
Remove force as it may overwrite somthing unwanted.
Remove force as it may overwrite somthing unwanted.
JavaScript
bsd-3-clause
NoahDragon/update-forked-repo
554d3977a180989956124761c4178fc01f69ed78
lib/client/hooks.js
lib/client/hooks.js
Router.hooks = { dataNotFound: function (pause) { var data = this.data(); var tmpl; if (data === null || typeof data === 'undefined') { tmpl = this.lookupProperty('notFoundTemplate'); if (tmpl) { this.render(tmpl); this.renderRegions(); pause(); } } }, ...
Router.hooks = { dataNotFound: function (pause) { var data = this.data(); var tmpl; if (!this.ready()) return; if (data === null || typeof data === 'undefined') { tmpl = this.lookupProperty('notFoundTemplate'); if (tmpl) { this.render(tmpl); this.renderRegions(); ...
Make dataNotFoundHook return if data not ready.
Make dataNotFoundHook return if data not ready.
JavaScript
mit
firdausramlan/iron-router,Aaron1992/iron-router,TechplexEngineer/iron-router,abhiaiyer91/iron-router,tianzhihen/iron-router,ecuanaso/iron-router,DanielDornhardt/iron-router-2,Aaron1992/iron-router,jg3526/iron-router,assets1975/iron-router,leoetlino/iron-router,TechplexEngineer/iron-router,Sombressoul/iron-router,appoet...
37b8b0c2a0c887b942653eaa832c5c4d15e3b205
test/Client.connect.js
test/Client.connect.js
var Client = require('../index').Client; var Transport = require('./mock/Transport'); var OutgoingFrameStream = require('./mock/OutgoingFrameStream'); var assert = require('assert'); describe('Client.connect', function() { var client, transport, framesOut, framesIn; beforeEach(function() { transport = new ...
var Client = require('../index').Client; var Transport = require('./mock/Transport'); var OutgoingFrameStream = require('./mock/OutgoingFrameStream'); var assert = require('assert'); describe('Client.connect', function() { var client, transport, framesOut, framesIn; beforeEach(function() { transport = new ...
Test for heart-beat header handling
Test for heart-beat header handling
JavaScript
mit
gdaws/node-stomp
fa6f1f516775a84db71769b07f11fd23d5b39f7e
addon/helpers/-ui-component-class.js
addon/helpers/-ui-component-class.js
import Ember from 'ember'; export default Ember.Helper.helper(function ([prefix, ...classNames]) { var classString = ''; classNames.forEach(function(name) { if (!name) return; var trimmedName = name.replace(/\s/g, ''); if (trimmedName === '') return; if (trimmedName === ':component') { cla...
import Ember from 'ember'; const FONT_SIZE_PATTERN = /font-size/; export default Ember.Helper.helper(function ([prefix, ...classNames]) { return classNames.reduce(function(string, name) { if (!name) return string; let trimmedName = name.replace(/\s/g, ''); if (trimmedName === '') return string; sw...
Whitelist font-size classes from prefixing
Whitelist font-size classes from prefixing
JavaScript
mit
prototypal-io/untitled-ui,prototypal-io/untitled-ui,prototypal-io/ui-base-theme,prototypal-io/ui-base-theme
f0aad1536f204a108876fea8bbda7aa8ba102749
server/mappings/windowslive.js
server/mappings/windowslive.js
module.exports = profile => { return { uid: profile.username || profile.id, mail: profile.emails && profile.emails[0] && profile.emails[0].value, cn: profile.displayName, displayName: profile.displayName, givenName: profile.name.familyName, sn: profile.name.givenName } }
module.exports = profile => { return { uid: profile.username || profile.id, mail: profile.emails && profile.emails[0] && profile.emails[0].value, cn: profile.displayName, displayName: profile.displayName, givenName: profile.name.givenName, sn: profile.name.familyName } }
Fix typo in windows live mapping
Fix typo in windows live mapping
JavaScript
apache-2.0
GluuFederation/gluu-passport,GluuFederation/gluu-passport
3617df199a77a9758b391615ec12e6ab0ae6362e
content.js
content.js
// Obtain ALL anchors on the page. var links = document.links; // The previous/next urls if they exist. var prev = findHref("prev"); var next = findHref("next"); /** * Find the href for a given name. * @param {String} The name of the anchor to search for. * @return {String} The href for a given tag, otherwise an e...
// Obtain ALL anchors on the page. var links = document.links; // The previous/next urls if they exist. var prev = findHref("prev"); var next = findHref("next"); /** * Find the href for a given name. * @param {String} name - The name of the anchor to search for. * @return {String} The href for a given tag, otherwi...
Refactor repeated checking to a helper method.
Refactor repeated checking to a helper method.
JavaScript
mit
jawrainey/leftyrighty
394ccb91c645cab13fbd2681cfdac3dd3bbaa602
app/contentModule.js
app/contentModule.js
app.module("ContentModule", function(ContentModule, app){ ContentModule.listTemplate = "<div>List</div>"; ContentModule.showTemplate = "<div>Show <%= id %></div>"; ContentModule.ListView = Marionette.ItemView.extend({ template: _.template(ContentModule.listTemplate), className: 'content list' }); ...
app.module("ContentModule", function(ContentModule, app){ ContentModule.itemTemplate = "Item"; ContentModule.listTemplate = "<div>List</div><ul></ul>"; ContentModule.showTemplate = "<div>Show <%= id %></div>"; ContentModule.ItemView = Marionette.ItemView.extend({ template: _.template(ContentModule.itemT...
Change list view to be a composite view
Change list view to be a composite view
JavaScript
mit
Gerg/marionette-boilerplate
e7fba0907c173ee96a277f3d75e894e886f38c5b
markovChain.js
markovChain.js
'use strict'; function randomIntFromInterval(min,max){return Math.floor(Math.random()*(max-min+1)+min);}; var markovGenerator = { order: 2, table:{}, load:function(text){ text = text.toLowerCase(); //text.replace(/[^a-z ]/, ''); for (var i = this.settings.order; i < text.length; i++){ var entry = text.sl...
'use strict'; function randomIntFromInterval(min,max){return Math.floor(Math.random()*(max-min+1)+min);}; var markovGenerator = { order: 2, table:{}, load:function(text){ text = text.toLowerCase(); //text.replace(/[^a-z ]/, ''); for (var i = this.order; i < text.length; i++){ var entry = text.slice(i-thi...
Fix for a wrongly named variable introduced when cleaning up
Fix for a wrongly named variable introduced when cleaning up
JavaScript
bsd-3-clause
Albertoni/JavascriptMarkovChain,Albertoni/JavascriptMarkovChain
1a8061be07063cb673b603ada0e2742e0b3cfa0c
Gruntfile.js
Gruntfile.js
module.exports = function(grunt) { grunt.initConfig({ connect: { server: { options: { port: 8000, useAvailablePort: true, hostname: '*', keepalive: true } } }, uglify: { dist: { files: { 'dist/angular-local-storag...
module.exports = function(grunt) { grunt.initConfig({ connect: { server: { options: { port: 8000, useAvailablePort: true, hostname: '*', keepalive: true } } }, uglify: { dist: { files: { 'dist/angular-local-storag...
Change config uglify task grunt
Change config uglify task grunt
JavaScript
mit
krescruz/angular-local-storage
a40f8e8464462e96cf78314098122bef99b2479f
client/src/components/ArticleCard.js
client/src/components/ArticleCard.js
import React from 'react' import {Link} from 'react-router-dom' function setArticleUrl(title) { var sanitizedTitle = title.replace(/%/g, "[percent]") debugger return encodeURIComponent(sanitizedTitle) } const ArticleCard = ({channel, article}) => { return ( <Link to={`/newsfeed/${channel.source_id}/${setA...
import React from 'react' import {Link} from 'react-router-dom' const ArticleCard = ({channel, article, setArticleUrl}) => { return ( <Link to={`/newsfeed/${channel.source_id}/${setArticleUrl(article.title)}`} className="article-link"> <div className="card"> <h3>{article.title}</h3> <img ...
Move setUrl functoin to parent
Move setUrl functoin to parent
JavaScript
mit
kevinladkins/newsfeed,kevinladkins/newsfeed,kevinladkins/newsfeed
cb839f6dd5000d1acfb62332344cf4d36e4df676
config/http-get-param-interceptor.js
config/http-get-param-interceptor.js
'use strict'; angular.module('gc.ngHttpGetParamInterceptor', [ 'gc.utils' ]).factory('httpGetParamInterceptor', [ 'utils', function httpGetParamInterceptor(utils) { return { request: function(config) { // Manually build query params using custom logic because Angular and // Rails do not...
'use strict'; angular.module('gc.ngHttpGetParamInterceptor', [ 'gc.utils' ]).factory('httpGetParamInterceptor', [ 'utils', function httpGetParamInterceptor(utils) { function deleteUndefinedValues(obj) { _.keys(obj).forEach(function(key) { if (_.isUndefined(obj[key])) { delete obj[key...
Revert "Revert "delete undefined properties from http config params""
Revert "Revert "delete undefined properties from http config params"" This reverts commit f2875d45257f892607df8a460b253cd35fb0900a.
JavaScript
mit
gocardless-ng/ng-gc-base-app-service
08b96b29e385b58fb09e8c5bc197c17492f1c9d4
examples/test-runner/mocha-controls.js
examples/test-runner/mocha-controls.js
"use strict"; var exampleTests = require('../example-tests'); function Controls(mochaRunner) { this._mochaRunner = mochaRunner; } Controls.prototype = { connectButtons: function(passingButtonId, failingButtonId, manyButtonId) { function connect(id, fn) { document.getElementById(id).addEventListener('cl...
"use strict"; var exampleTests = require('../example-tests'); function Controls(mochaRunner) { this._mochaRunner = mochaRunner; } Controls.prototype = { connectButtons: function(passingButtonId, failingButtonId, manyButtonId) { function connect(id, fn) { document.getElementById(id).addEventListener('cl...
Use the proper test code.
Use the proper test code.
JavaScript
mit
tddbin/tddbin-frontend,tddbin/tddbin-frontend,tddbin/tddbin-frontend
d804e831b659c5ad23b398df1f7d9198026d32d6
src/main/webapp/components/BuildSnapshotContainer.js
src/main/webapp/components/BuildSnapshotContainer.js
import * as React from "react"; import {BuildSnapshot} from "./BuildSnapshot"; /** * Container Component for BuildSnapshots. * * @param {*} props input property containing an array of build data to be * rendered through BuildSnapshot. */ export const BuildSnapshotContainer = React.memo((props) => { const S...
import * as React from "react"; import {BuildSnapshot} from "./BuildSnapshot"; /** * Container Component for BuildSnapshots. * * @param {*} props input property containing an array of build data to be * rendered through BuildSnapshot. */ export const BuildSnapshotContainer = React.memo((props) => { const N...
Update fetch source, add parameters
Update fetch source, add parameters
JavaScript
apache-2.0
googleinterns/step240-2020,googleinterns/step240-2020,googleinterns/step240-2020,googleinterns/step240-2020
bb0c2f4f9f7a227820308f0802c062520b0f6a00
stockflux-launcher/src/app-shortcuts/AppShortcuts.js
stockflux-launcher/src/app-shortcuts/AppShortcuts.js
import React, { useEffect, useState } from 'react'; import { OpenfinApiHelpers } from 'stockflux-core'; import Components from 'stockflux-components'; import './AppShortcuts.css'; export default () => { const [apps, setApps] = useState([]); useEffect(() => { const options = { method: 'GET' }; O...
import React, { useEffect, useState } from 'react'; import { OpenfinApiHelpers } from 'stockflux-core'; import Components from 'stockflux-components'; import './AppShortcuts.css'; export default () => { const [apps, setApps] = useState([]); useEffect(() => { const options = { method: 'GET' }; O...
Rename stockflux-search to stockflux-launcher in package.json and remove console.log
Rename stockflux-search to stockflux-launcher in package.json and remove console.log
JavaScript
mit
owennw/OpenFinD3FC,owennw/OpenFinD3FC,ScottLogic/bitflux-openfin,ScottLogic/StockFlux,ScottLogic/StockFlux,ScottLogic/bitflux-openfin
7e019de783a757fdeb5fc5babb05b297defb6b46
src/client/es6/controller/cart-blog-create.js
src/client/es6/controller/cart-blog-create.js
import CartBlogEditorCtrl from './base/cart-blog-editor.js'; class CartBlogCreateCtrl extends CartBlogEditorCtrl { constructor(...args) { super(...args); this.logInit('CartBlogCreateCtrl'); this.init(); } init() { this.apiService.postDefaultCategory().then( (category) => { this.ca...
import CartBlogEditorCtrl from './base/cart-blog-editor.js'; class CartBlogCreateCtrl extends CartBlogEditorCtrl { constructor(...args) { super(...args); this.logInit('CartBlogCreateCtrl'); this.init(); } init() { this.apiService.postDefaultCategory().then( (category) => { this.ca...
Remove uuid in constructor, since strong loop server will see null as value provided, there won't be any defaultFn called. Otherwise you can give uuid "undefined", it's OK.
Remove uuid in constructor, since strong loop server will see null as value provided, there won't be any defaultFn called. Otherwise you can give uuid "undefined", it's OK.
JavaScript
mit
agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart,agreatfool/Cart
e6fd0e7eb621d549d231b9435ed3f7974f368f10
notifications/content.js
notifications/content.js
var baseUrl = process.env.BASE_URI || "localdocker:4000"; module.exports = { approveFeed: function(message, recipient, group) { return "<p>" + message["user"]["userName"] + " has approved the feed for their " + message["election"].date.substring(0,10) + " " + message["election"].election_type + " election ...
var baseUrl = process.env.BASE_URI || "localdocker:4000"; module.exports = { approveFeed: function(message, recipient, group) { return "<p>" + message["user"]["userName"] + " has approved the feed for their " + message["election"].date.substring(0,10) + " " + message["election"].election_type + " election ...
Add missing space in email template.
[CS] Add missing space in email template.
JavaScript
bsd-3-clause
votinginfoproject/Metis,votinginfoproject/Metis,votinginfoproject/Metis
ee12708d43ff22bc9d9c9ea5a36011ee66fdd69a
tasks/autoprefixer.js
tasks/autoprefixer.js
/* * grunt-autoprefixer * * * Copyright (c) 2013 Dmitry Nikitenko * Licensed under the MIT license. */ 'use strict'; module.exports = function (grunt) { var autoprefixer = require('autoprefixer'); grunt.registerMultiTask('autoprefixer', 'Parse CSS and add prefixed properties and values by Can I Use d...
/* * grunt-autoprefixer * * * Copyright (c) 2013 Dmitry Nikitenko * Licensed under the MIT license. */ 'use strict'; module.exports = function (grunt) { var autoprefixer = require('autoprefixer'); grunt.registerMultiTask('autoprefixer', 'Parse CSS and add vendor prefixes to CSS rules using values fro...
Update the description of the task.
Update the description of the task.
JavaScript
mit
nqdy666/grunt-autoprefixer,nDmitry/grunt-autoprefixer,yuhualingfeng/grunt-autoprefixer
7645de616768d37c3589609d347e1566be48634a
plugins/index.js
plugins/index.js
'use strict'; let telegram = require( './telegram.js' ); let urlchecker = require( './urlchecker.js' ); let github = require( './github.js' ); let rss = require( './rss.js' ); let dagensmix = require( './dagensmix.js' ); let pushbullet = require( './pushbullet.js' ); let httpcat = require( './httpcat.js' ); module.ex...
'use strict'; let telegram = require( './telegram.js' ); let urlchecker = require( './urlchecker.js' ); let github = require( './github.js' ); let rss = require( './rss.js' ); let dagensmix = require( './dagensmix.js' ); // let pushbullet = require( './pushbullet.js' ); let httpcat = require( './httpcat.js' ); module...
Disable pushbullet because we don't use it anymore :D
Disable pushbullet because we don't use it anymore :D
JavaScript
mit
kokarn/KokBot
a5440e93f7550b2c107ffbf831a616938d90cbe7
desktop/reactified/client/src/App.js
desktop/reactified/client/src/App.js
import React, { Component } from 'react'; import { Route, BrowserRouter as Router } from 'react-router-dom'; import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider'; import getMuiTheme from 'material-ui/styles/getMuiTheme'; import injectTapEventPlugin from 'react-tap-event-plugin'; import { blue500 } from...
import React, { Component } from 'react'; import { Redirect, Route, BrowserRouter as Router } from 'react-router-dom'; import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider'; import getMuiTheme from 'material-ui/styles/getMuiTheme'; import injectTapEventPlugin from 'react-tap-event-plugin'; import { blue...
Add default route from / to /tasks
Add default route from / to /tasks
JavaScript
mit
mkermani144/wanna,mkermani144/wanna
0369aa8e1381c1d98f7049268f6275342017b9e0
src/components/with-drag-and-drop/item-target/item-target.js
src/components/with-drag-and-drop/item-target/item-target.js
import React from 'react'; import ReactDOM from 'react-dom'; const ItemTarget = { hover(props, monitor, component) { const dragIndex = monitor.getItem().index; const hoverIndex = props.index; // Don't replace items with themselves if (dragIndex === hoverIndex) { console.log(1); return; ...
import ReactDOM from 'react-dom'; const ItemTarget = { hover(props, monitor, component) { const dragIndex = monitor.getItem().index; const hoverIndex = props.index; // Don't replace items with themselves if (dragIndex === hoverIndex) { return; } // Determine rectangle on screen co...
Remove unused var and console statements
Remove unused var and console statements
JavaScript
apache-2.0
Sage/carbon,Sage/carbon,Sage/carbon
042737ff4aad71ec237b8565e59a1fb988c1b7f3
lib/node_modules/@stdlib/random/base/improved-ziggurat/lib/ratio_array.js
lib/node_modules/@stdlib/random/base/improved-ziggurat/lib/ratio_array.js
/** * @license Apache-2.0 * * Copyright (c) 2018 The Stdlib Authors. * * 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 a...
/** * @license Apache-2.0 * * Copyright (c) 2018 The Stdlib Authors. * * 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 a...
Fix example and dynamically resize array
Fix example and dynamically resize array
JavaScript
apache-2.0
stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib
0ff964092fda25483633ce0fd4494b1bdf0858b0
public/js/app.js
public/js/app.js
$(".up-button").mousedown(function(){ $.get("/movecam/moveUp"); }).mouseup(function(){ $.get("/movecam/moveStop"); }); $(".left-button").mousedown(function(){ $.get("/movecam/moveLeft"); }).mouseup(function(){ $.get("/movecam/moveStop"); }); $(".right-button").mousedown(function(){ $.get("/movecam/moveRight...
$(".up-button").bind("mousedown touchstart", function(){ $.get("/movecam/moveUp"); }).bind("mouseup touchend", function(){ $.get("/movecam/moveStop"); }); $(".left-button").bind("mousedown touchstart", function(){ $.get("/movecam/moveLeft"); }).bind("mouseup touchend", function(){ $.get("/movecam/moveStop"); }...
Enable touch use with jQuery element.
Enable touch use with jQuery element.
JavaScript
mit
qrila/khvidcontrol,qrila/khvidcontrol
f336097b6a75ac819d934dbc0db0f6901c4ad464
randombytes.js
randombytes.js
var assert = require('nanoassert') var randombytes = (function () { var QUOTA = 65536 // limit for QuotaExceededException var crypto = typeof window !== 'undefined' ? (window.crypto || window.msCrypto) : null function windowBytes (out, n) { for (var i = 0; i < n; i += QUOTA) { crypto.getRandomValues(ou...
var assert = require('nanoassert') var randombytes = (function () { var QUOTA = 65536 // limit for QuotaExceededException var crypto = typeof global !== 'undefined' ? crypto = (global.crypto || global.msCrypto) : null function browserBytes (out, n) { for (var i = 0; i < n; i += QUOTA) { crypto.getRando...
Fix bug with undefined window in web workers
Fix bug with undefined window in web workers Fixes #8
JavaScript
mit
sodium-friends/sodium-javascript
d14f4976cba654e91753d4f290c339fd11891c88
frontend/common/directives/competition-infos/competitionInfos.controller.js
frontend/common/directives/competition-infos/competitionInfos.controller.js
'use strict'; angular.module('konehuone.competitionInfos') .controller('CompetitionInfosCtrl', function ($scope, lodash, apiService) { var _ = lodash; // # Variables $scope.uiClosed = { jj1: true, jj2: true, rc: true }; $scope.compData = {}; $scope.igImages = []; ...
'use strict'; angular.module('konehuone.competitionInfos') .controller('CompetitionInfosCtrl', function ($scope, lodash, apiService) { var _ = lodash; // # Variables $scope.uiClosed = { jj1: false, jj2: false, rc: false }; $scope.compData = {}; $scope.igImages = []; ...
Set comp info boxes opened as default
Set comp info boxes opened as default
JavaScript
mit
miro/konehuone,miro/konehuone
446458ad0ea88c40f6b0ebffe083c509a4fddb0c
resources/titleManager.js
resources/titleManager.js
/* * Title module displaying title tag based on current view */ var EngineJS_titleManager = { content: {}, titleDefault: "", titleSuffix: "", init: function(content, titleDefault, titleSuffix) { this.content = content; this.titleDefault = titleDefault; this.titleSuffix = titleSuffix...
/* * Title module displaying title tag based on current view */ var EngineJS_titleManager = { content: {}, titleDefault: "", titleSuffix: "", init: function(content, titleDefault, titleSuffix) { this.content = content; this.titleDefault = titleDefault; this.titleSuffix = titleSuffix...
Fix typo from previous commit
Fix typo from previous commit
JavaScript
mit
enginejs/libs
b2e9a173ccf695fceed5a2689e0b7dfce4d5f810
package.js
package.js
Package.describe({ summary: "Ravelry OAuth flow", name: "amschrader:ravelry", git: "git@github.com:amschrader/meteor-ravelry.git", version: "0.1.0" }); Package.onTest(function(api) { api.use('tinytest'); api.use('amschrader:ravelry'); api.addFiles('ravelry-tests.js'); }); Package.on_use(function(api) { ...
Package.describe({ summary: "Ravelry OAuth flow", name: "amschrader:ravelry", git: "https://github.com/amschrader/meteor-ravelry.git", version: "0.1.2" }); Package.onTest(function(api) { api.use('tinytest'); api.use('amschrader:ravelry'); api.addFiles('ravelry-tests.js'); }); Package.onUse(function(api)...
Update git url, formatting nits
Update git url, formatting nits
JavaScript
mit
amschrader/meteor-ravelry
56e32f674d211ab1d94afd97660c0c28a82a621f
step_definitions/lib/navigation/link/index.js
step_definitions/lib/navigation/link/index.js
module.exports = { validateAnchorText: validateAnchorText, click: click, }; /** * * @param {WebdriverIO} browser Instance of web driver * @param {String} anchorText The anchor text to target by */ function click (browser, anchorText) { return browser.click('a=' + anchorText); } /** * Sets the client's ...
var interaction = require('../../interaction'); module.exports = { validateAnchorText: validateAnchorText, click: click, }; /** * Clicks an anchor element with the given anchor text * @param {WebdriverIO} browser Instance of web driver * @param {String} anchorText The anchor text to target by */ function ...
Refactor click link to use click element method
Refactor click link to use click element method
JavaScript
mit
sudokrew/krewcumber,sudokrew/krewcumber
2d311ac85665a5edef7a4aab7c8efaac43426201
lab10/public/js/l10.js
lab10/public/js/l10.js
/** * Created by curtis on 3/28/16. */ angular.module('clusterApp', []) .controller('MainCtrl', [ '$scope', '$http', function($scope, $http) { var completed = 0, timesToQuery = 100, pids = []; $scope.cluster = []; $scope.b...
/** * Created by curtis on 3/28/16. */ angular.module('clusterApp', []) .controller('MainCtrl', [ '$scope', '$http', function($scope, $http) { var completed = 0, timesToQuery = 100; $scope.cluster = []; $scope.busy = false; $...
Clean up the lab10 code a bit.
Clean up the lab10 code a bit.
JavaScript
mit
chocklymon/CS360,chocklymon/CS360,chocklymon/CS360,chocklymon/CS360
1890cfca8065635ced6755524d468614dead23f5
src/services/GetCharityData.js
src/services/GetCharityData.js
class GetCharityData { getData(){ var CHARITY_DATA = [ {amount: '41,234', month: 'January', year: '2015', name: 'Charity:Water', description: 'Cool description that was so hard to come up with. Hence I ended up writing some random text that dosent make much text' ,imageSource: 'https://s3.amazonaws.com/moveit-mul...
class GetCharityData { getData(){ var CHARITY_DATA_ARRAY = []; var spreadsheetID = "1f1tFr7y62QS7IRWOC2nNR5HWsTO99Bna3d0Xv1PTPiY"; var url = "https://spreadsheets.google.com/feeds/list/" + spreadsheetID + "/od6/public/values?alt=json"; fetch(url).then((response) => response.json()) .then((respon...
Implement service to fetch charity data from spreadsheet
Implement service to fetch charity data from spreadsheet https://trello.com/c/wjthoHP0/28-user-sbat-view-the-charity-contributions-done-per-month-by-the-company
JavaScript
mit
multunus/moveit-mobile,multunus/moveit-mobile,multunus/moveit-mobile
ad44e79d9f69feea484f72c44c55853f144fb6b8
lib/get-youtube-url.js
lib/get-youtube-url.js
const Request = require('sdk/request').Request; const qs = require('sdk/querystring'); const baseURL = 'http://www.youtube.com/get_video_info'; module.exports = getYouTubeUrl; function getYouTubeUrl(videoId, cb) { Request({ url: baseURL + '?' + qs.stringify({video_id: videoId}), onComplete: function (resp)...
const Request = require('sdk/request').Request; const qs = require('sdk/querystring'); const baseURL = 'https://www.youtube.com/get_video_info'; module.exports = getYouTubeUrl; function getYouTubeUrl(videoId, cb) { Request({ url: baseURL + '?' + qs.stringify({video_id: videoId}), onComplete: function (resp...
Convert YouTube link to HTTPS
Convert YouTube link to HTTPS
JavaScript
mpl-2.0
meandavejustice/min-vid,meandavejustice/min-vid,meandavejustice/min-vid
74aa179b5e16f5456a7529326820aba1a97bbb1e
server/middleware/auth.js
server/middleware/auth.js
const session = require('express-session'); const RedisStore = require('connect-redis')(session); const redisClient = require('redis').createClient(); module.exports.verify = (req, res, next) => { if (req.isAuthenticated()) { return next(); } res.redirect('/login'); }; module.exports.profileRedirect = (req,...
const session = require('express-session'); const RedisStore = require('connect-redis')(session); const redisClient = require('redis').createClient(process.env.REDIS_URL) || require('redis').createClient; module.exports.verify = (req, res, next) => { if (req.isAuthenticated()) { return next(); } res.redirect...
Add REDIS_URL to createClient as an argument
Add REDIS_URL to createClient as an argument
JavaScript
mit
FuriousFridges/FuriousFridges,FuriousFridges/FuriousFridges
9960f49700f7793c93295240481ef1fcb7080a93
troposphere/static/js/stores/HelpLinkStore.js
troposphere/static/js/stores/HelpLinkStore.js
import Dispatcher from "dispatchers/Dispatcher"; import BaseStore from "stores/BaseStore"; import HelpLinkCollection from "collections/HelpLinkCollection"; var HelpLinkStore = BaseStore.extend({ collection: HelpLinkCollection, queryParams: { page_size: 100 }, }); var store = new HelpLinkStore();...
import _ from "underscore"; import Dispatcher from "dispatchers/Dispatcher"; import BaseStore from "stores/BaseStore"; import HelpLinkCollection from "collections/HelpLinkCollection"; var HelpLinkStore = BaseStore.extend({ collection: HelpLinkCollection, queryParams: { page_size: 100 }, }); var ...
Fix error when updateImageAttributes dispatched
Fix error when updateImageAttributes dispatched An uncaught error has been occurring when an image creator saves any changes to image attributes: ``` Uncaught TypeError: Cannot read property 'silent' of undefined ``` It turns out that the HelpLinkStore is performing check for an option, `option.silent`, to determine...
JavaScript
apache-2.0
CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend,CCI-MOC/GUI-Frontend
0393c02cf549c8ee3bc09278153208702ec2b25a
lib/app/store/geoip.js
lib/app/store/geoip.js
module.exports = function geoip (ip) { return (state, emitter) => { state.geoip = { ip: ip, isLoading: false } emitter.on('geoip:fetch', () => { if (state.geoip.isLoading) return state.geoip.isLoading = true window.fetch('//api.ipify.org?format=json') .then(body => ...
module.exports = function geoip (ip) { return (state, emitter) => { state.geoip = { ip: ip, isLoading: false } emitter.on('geoip:fetch', () => { if (state.geoip.isLoading) return state.geoip.isLoading = true window.fetch('https://freegeoip.net/json/').then(body => { ...
Remove use of ipify.org service
Remove use of ipify.org service
JavaScript
apache-2.0
CIVIS-project/BRFApp
d34142022ccee2c72cf99430bba1ad3446061294
public/js/script.js
public/js/script.js
//Client-side JS goes here. (function () { var locale = APP.intl.locale, baseUrl = 'http://yui.yahooapis.com/combo?platform/intl/0.1.2/Intl.min.js&platform/intl/0.1.2/locale-data/jsonp/', comboUrl = baseUrl + locale + '.js'; yepnope({ test : !!window.Intl, nope : comboUrl ...
//Client-side JS goes here. (function () { var locale = APP.intl.locale, // TODO: expose these URLs through Express State instead baseUrl = 'http://yui.yahooapis.com/combo?platform/intl/0.1.2/Intl.min.js&platform/intl/0.1.2/locale-data/jsonp/', comboUrl = baseUrl + locale + '.js', ...
Load in `intl-messageformat` after Intl
Load in `intl-messageformat` after Intl
JavaScript
bsd-3-clause
okuryu/formatjs-site,ericf/formatjs-site,ericf/formatjs-site
6f7ef8765f1919c1ad9471d031bd3d6cb1f6937f
lib/middleware/cors.js
lib/middleware/cors.js
/** * Adds CORS headers to the response * * ####Example: * * app.all('/api*', keystone.middleware.cors); * * @param {app.request} req * @param {app.response} res * @param {function} next * @api public */ // The exported function returns a closure that retains // a reference to the keystone instance, so ...
/** * Adds CORS headers to the response * * ####Example: * * app.all('/api*', keystone.middleware.cors); * * @param {app.request} req * @param {app.response} res * @param {function} next * @api public */ // The exported function returns a closure that retains // a reference to the keystone instance, so ...
Add OPTIONS to CORS allowed methods
Add OPTIONS to CORS allowed methods
JavaScript
mit
creynders/keystone,creynders/keystone
53db1031477a5f159feeb90dfb30a51a83093840
components/layout/layout-panel-header.directive.js
components/layout/layout-panel-header.directive.js
export default ['config', 'Core', function (config, Core) { return { template: require('components/layout/partials/panel-header.directive.html'), transclude: { 'extraButtons': '?extraButtons', 'extraTitle': '?extraTitle' }, scope: { panelName: "@",...
export default ['config', 'Core', function (config, Core) { return { template: require('components/layout/partials/panel-header.directive.html'), transclude: { 'extraButtons': '?extraButtons', 'extraTitle': '?extraTitle' }, scope: { panelName: "@",...
Fix incorrect injection of $scope for minification
Fix incorrect injection of $scope for minification
JavaScript
mit
hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng
84e900f20bc6738ca5f71d9346254a5f8322f5eb
examples/node-browser/tracer-init.js
examples/node-browser/tracer-init.js
/* * Copyright 2015-2016 Red Hat, Inc. and/or its affiliates * and other contributors as indicated by the @author tags. * * 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://w...
/* * Copyright 2015-2016 Red Hat, Inc. and/or its affiliates * and other contributors as indicated by the @author tags. * * 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://w...
Add deployment meta data to example app
Add deployment meta data to example app
JavaScript
apache-2.0
hawkular/hawkular-apm-opentracing-javascript
523cdd46d039ad2a581a08f6da6438e7c72df472
bi-platform-v2-plugin/cdf/js/components/simpleautocomplete.js
bi-platform-v2-plugin/cdf/js/components/simpleautocomplete.js
var SimpleAutoCompleteComponent = BaseComponent.extend({ ph: undefined, completionCallback: undefined, update: function() { this.ph = $("#" + this.htmlObject).empty(); this.input = $("<input type='text'>").appendTo(this.ph); this.query = new Query(this.queryDefinition); var myself...
var SimpleAutoCompleteComponent = BaseComponent.extend({ ph: undefined, completionCallback: undefined, update: function() { var myself = this; this.ph = $("#" + this.htmlObject).empty(); this.input = $("<input type='text'>").appendTo(this.ph); this.query = new Query(this.queryDefi...
Fix some bugs with simple autocomplete
Fix some bugs with simple autocomplete
JavaScript
mpl-2.0
Tiger66639/cdf,pamval/cdf,krivera-pentaho/cdf,davidmsantos90/cdf,diogofscmariano/cdf,eliofreitas/cdf,jvelasques/cdf,Aliaksandr-Kastenka/cdf,pedrofvteixeira/cdf,pamval/cdf,jvelasques/cdf,diogofscmariano/cdf,diogofscmariano/cdf,Tiger66639/cdf,e-cuellar/cdf,afrjorge/cdf,afrjorge/cdf,webdetails/cdf,eliofreitas/cdf,scottyas...
77cd76c4e97c2cdc895e0fba1f1207f4c6c7623d
lib/transport/index.js
lib/transport/index.js
'use strict'; var EventEmitter = require('events').EventEmitter; var AbstractTransport = require('./abstract_transport.js'); var NetTransport = require('./net_transport.js'); var TlsTransport = require('./tls_transport.js'); function TransportProvider() { this._transports = {}; } TransportProvider.prototype.regist...
'use strict'; var EventEmitter = require('events').EventEmitter; var AbstractTransport = require('./abstract_transport.js'); var NetTransport = require('./net_transport.js'); var TlsTransport = require('./tls_transport.js'); function TransportProvider() { this._transports = {}; } TransportProvider.prototype.regist...
Fix jshint errors in transport
Fix jshint errors in transport
JavaScript
mit
noodlefrenzy/node-amqp10
f60c3859905ed939366800d3adf71ec7e1da3a4b
eloquent_js/chapter12/ch12_ex03.js
eloquent_js/chapter12/ch12_ex03.js
function skipSpace(string) { let toRemove = string.match(/^(?:\s|#.*)*/); return string.slice(toRemove[0].length); }
function skipSpace(string) { let match = string.match(/^(\s+|#.*)*/); return string.slice(match[0].length); }
Add chapter 12, exercise 3
Add chapter 12, exercise 3
JavaScript
mit
bewuethr/ctci
f98cf367c1d9fa9ca2516ab0d2dead2b80f7848a
test/test-issue-85.js
test/test-issue-85.js
var common = require("./common") , odbc = require("../") , db = new odbc.Database() , assert = require("assert") , util = require('util') , count = 0 ; var sql = (common.dialect == 'sqlite' || common.dialect =='mysql') ? 'select cast(-1 as signed) as test;' : 'select cast(-1 as int) as test;' ; db....
var common = require("./common") , odbc = require("../") , db = new odbc.Database() , assert = require("assert") , util = require('util') , count = 0 ; var sql = (common.dialect == 'sqlite' || common.dialect =='mysql') ? 'select cast(-1 as signed) as test, cast(-2147483648 as signed) as test2, cast(2147...
Update test to include min and max of integer range
Update test to include min and max of integer range
JavaScript
mit
jbaxter0810/node-odbc,gmahomarf/node-odbc,dfbaskin/node-odbc,bzuillsmith/node-odbc,Papercloud/node-odbc,bustta/node-odbc,gmahomarf/node-odbc,Papercloud/node-odbc,bzuillsmith/node-odbc,wankdanker/node-odbc,wankdanker/node-odbc,jbaxter0810/node-odbc,gmahomarf/node-odbc,dfbaskin/node-odbc,bustta/node-odbc,Papercloud/node-...
32912d1ef7ede8ffc7722a15fa7eeba0751319a0
example/app/models/post.js
example/app/models/post.js
module.exports = function () { this.string('name', { required: true, minLength: 5 }); this.string('title', { required: true, minLength: 5 }); this.string('content'); this.timestamps(); this.filter('all', { map: function (doc) { if (doc.resource === 'Post') { var x = ...
module.exports = function () { this.string('name', { required: true, minLength: 5 }); this.string('title', { required: true, minLength: 5 }); this.string('content'); this.timestamps(); this.filter('all', { map: function (doc) { if (doc.resource === 'Post') { emit(doc...
Change view based on fixes in resourceful
Change view based on fixes in resourceful
JavaScript
mit
pksunkara/bullet
92254b47944a101e37444aa4aea7f2ddb840cf38
waltz-ng/client/extensions/extensions.js
waltz-ng/client/extensions/extensions.js
// extensions initialisation import {registerComponents} from '../common/module-utils'; import {dynamicSections, dynamicSectionsByKind} from "../dynamic-section/dynamic-section-definitions"; import dbChangeInitiativeBrowser from './components/change-initiative/change-initiative-browser/db-change-initiative-browser'; ...
// extensions initialisation import _ from "lodash"; import {registerComponents} from '../common/module-utils'; import {dynamicSections, dynamicSectionsByKind} from "../dynamic-section/dynamic-section-definitions"; import dbChangeInitiativeBrowser from './components/change-initiative/change-initiative-browser/db-chan...
Fix change initiative section - Override GH section with DB specific one
Fix change initiative section - Override GH section with DB specific one CTCTOWALTZ-706
JavaScript
apache-2.0
davidwatkins73/waltz-dev,kamransaleem/waltz,khartec/waltz,rovats/waltz,rovats/waltz,rovats/waltz,khartec/waltz,kamransaleem/waltz,khartec/waltz,rovats/waltz,davidwatkins73/waltz-dev,kamransaleem/waltz,kamransaleem/waltz,khartec/waltz,davidwatkins73/waltz-dev,davidwatkins73/waltz-dev
8a779ce56482ab429172aa05c49d36d500bfea16
public/backbone-marionette/js/router.js
public/backbone-marionette/js/router.js
/*global BackboneWizard, Backbone*/ BackboneWizard.Routers = BackboneWizard.Routers || {}; (function () { 'use strict'; BackboneWizard.Routers.WizardRouter = Backbone.Router.extend({ routes: { '': 'index', 'verify': 'showVerify', 'payment': 'showPayment', ...
/*global BackboneWizard, Marionette*/ BackboneWizard.Routers = BackboneWizard.Routers || {}; (function () { 'use strict'; BackboneWizard.Routers.WizardRouter = Marionette.AppRouter.extend({ appRoutes: { '': 'index', 'verify': 'showVerify', 'payment': 'showPayment',...
Use Marionette.AppRouter for the Router.
Use Marionette.AppRouter for the Router.
JavaScript
mit
jonkemp/wizard-mvc
8ca18ff251f2f44b93ebb9050931c542628fc8d1
app/assets/javascripts/representativeSelector.js
app/assets/javascripts/representativeSelector.js
var HDO = HDO || {}; (function (H, $) { H.representativeSelector = { init: function (opts) { var districtSelect, representativeSelect, representatives, selectedRepresentatives; districtSelect = opts.districtSelect; representativeSelect = opts.representativeSelect; representatives ...
var HDO = HDO || {}; (function (H, $) { H.representativeSelector = { init: function (opts) { var districtSelect, representativeSelect, representatives, selectedRepresentatives; districtSelect = opts.districtSelect; representativeSelect = opts.representativeSelect; representatives ...
Disable district search + use contains filter for representatives.
Disable district search + use contains filter for representatives.
JavaScript
bsd-3-clause
holderdeord/hdo-site,holderdeord/hdo-site,holderdeord/hdo-site,holderdeord/hdo-site
728693fbf3fbad513fec2d1bee6aeabe4e5caf91
frontend/src/components/ViewActivities/activityday.js
frontend/src/components/ViewActivities/activityday.js
import React from 'react'; import Accordion from 'react-bootstrap/Accordion'; import Card from 'react-bootstrap/Card'; import Activity from './activity'; import * as activityFns from './activityfns'; import * as utils from '../Utils/utils.js' class ActivityDay extends React.Component { /** @inheritdoc */ construct...
import React from 'react'; import Accordion from 'react-bootstrap/Accordion'; import Card from 'react-bootstrap/Card'; import Activity from './activity'; import * as activityFns from './activityfns'; import * as utils from '../Utils/utils.js' class ActivityDay extends React.Component { /** @inheritdoc */ construct...
Remove state variable where it can be removed.
Remove state variable where it can be removed.
JavaScript
apache-2.0
googleinterns/SLURP,googleinterns/SLURP,googleinterns/SLURP
1649c411366e12bc338b3486b82b0d109f97d6f0
src/modules/unit/components/UnitsOnMap.js
src/modules/unit/components/UnitsOnMap.js
import React from 'react'; import isEmpty from 'lodash/isEmpty'; import SingleUnitOnMap from './SingleUnitOnMap'; import {sortByCondition} from '../helpers'; export const UnitsOnMap = ({units, selectedUnitId, openUnit}) => { let unitsInOrder = units.slice(); // Draw things in condition order unitsInOrder = sort...
import React from 'react'; import isEmpty from 'lodash/isEmpty'; import SingleUnitOnMap from './SingleUnitOnMap'; import {sortByCondition} from '../helpers'; export const UnitsOnMap = ({units, selectedUnitId, openUnit}) => { let unitsInOrder = units.slice(); // Draw things in condition order unitsInOrder = sort...
Add comment to fix a bug
Add comment to fix a bug
JavaScript
mit
nordsoftware/outdoors-sports-map,nordsoftware/outdoors-sports-map,nordsoftware/outdoors-sports-map
d6090f49d653d76a65696e3c5fe8417c673c398a
auto-bind.js
auto-bind.js
'use strict'; var copy = require('es5-ext/object/copy') , map = require('es5-ext/object/map') , callable = require('es5-ext/object/valid-callable') , validValue = require('es5-ext/object/valid-value') , bind = Function.prototype.bind, defineProperty = Object.defineProperty , hasOwnProperty = ...
'use strict'; var copy = require('es5-ext/object/copy') , ensureCallable = require('es5-ext/object/valid-callable') , map = require('es5-ext/object/map') , callable = require('es5-ext/object/valid-callable') , validValue = require('es5-ext/object/valid-value') , bind = Functio...
Reconfigure bindTo support into options.resolveContext
Reconfigure bindTo support into options.resolveContext
JavaScript
isc
medikoo/d
79e5bd95684823ee41af1d35474cb29a627328d2
example/index.js
example/index.js
var express = require('express'), app = express(), kaching = require('kaching'); app.set('views', __dirname); app.set('view engine', 'jade'); app.use(express.logger('dev')); app.use(express.bodyParser()); app.use(express.methodOverride()); app.use(express.cookieParser()); app.use(express.session({ secret: 'se...
var express = require('express'), app = express(), PaypalStrategy = require('kaching-paypal'), kaching = require('kaching'); app.set('views', __dirname); app.set('view engine', 'jade'); /** * Test account: kaching@gmail.com * Password: kachingtest */ kaching.use(new PaypalStrategy({ 'client_id': 'AVN...
Use paypal strategy for testing.
Use paypal strategy for testing.
JavaScript
mit
gregwym/kaching
d769d4b6df913d6b4e32e1e4b44d4f69d9f926ca
bin/cli.js
bin/cli.js
var program = require('commander'); program .description('Generate random documents, numbers, names, address, etc.') .version('0.0.1') .option('-f, --cpf', 'Select CPF') .option('-j, --cnpj', 'Select CNPJ') .option('-n, --name [gender]', 'Select Name') .option('-c, --creditCard <type>', 'Select...
var program = require('commander'); program .description('Generate random documents, numbers, names, address, etc.') .version('0.0.1') .option('-f, --cpf', 'Select CPF') .option('-j, --cnpj', 'Select CNPJ') .option('-c, --creditCard <type>', 'Select Credit Card. Types: maestro, dinersclub, laser, j...
Remove --name feature as it's not working at the moment
Remove --name feature as it's not working at the moment
JavaScript
mit
lvendrame/dev-util-cli,lagden/dev-util-cli
c553b7303421701a87f84d506643e88dafab7798
client/app/pages/admin/outdated-queries/index.js
client/app/pages/admin/outdated-queries/index.js
import moment from 'moment'; import { Paginator } from '@/lib/pagination'; import template from './outdated-queries.html'; function OutdatedQueriesCtrl($scope, $http, $timeout) { $scope.autoUpdate = true; this.queries = new Paginator([], { itemsPerPage: 50 }); const refresh = () => { if ($scope.autoUpdat...
import moment from 'moment'; import { Paginator } from '@/lib/pagination'; import template from './outdated-queries.html'; function OutdatedQueriesCtrl($scope, $http, $timeout) { $scope.autoUpdate = true; this.queries = new Paginator([], { itemsPerPage: 50 }); const refresh = () => { if ($scope.autoUpdate...
Test line end carriages redo.
Test line end carriages redo.
JavaScript
bsd-2-clause
moritz9/redash,moritz9/redash,moritz9/redash,moritz9/redash
764061b8b87ff137633089f17f14e954f995cd8d
bin/cli.js
bin/cli.js
var program = require('commander'); var pkg = require('../package.json'); program .version(pkg.version) .description('Gitter bot for evaluating expressions') .usage('<room-name>') .parse(process.argv); if (!program.args[0]) { throw new Error('You must supply room'); }
var program = require('commander'); var pkg = require('../package.json'); program .version(pkg.version) .description('Gitter bot for evaluating expressions') .usage('[options] <room-name>') .option('-k, --key', 'Override API key by default') .parse(process.argv);
Add option for override default API key
Add option for override default API key
JavaScript
mit
ghaiklor/uwcua-vii
8102b934e3aa9386d2dd68acb7cb5985c68684b8
test/promises-tests.js
test/promises-tests.js
var path = require('path'); var fs = require('fs'); global.adapter = require('./adapter-a'); describe('promises-tests', function () { var testsDir = path.join(path.dirname(require.resolve('promises-aplus-tests/lib/programmaticRunner.js')), 'tests'); var testFileNames = fs.readdirSync(testsDir); testFileNames.f...
var tests = require('promises-aplus-tests'); var adapter = require('./adapter-a'); tests.mocha(adapter);
Use newer system for programatic runner
Use newer system for programatic runner
JavaScript
mit
nodegit/promise,slang800/promise,then/promise,vigetlabs/promise,taylorhakes/promise,JoshuaWise/jellypromise,implausible/promise,ljharb/promise,npmcomponent/then-promise,astorije/promise,Bacra/promise,cpojer/promise
ec3d29cdb3231abc1bed89d5fc5a02f29addb392
examples/todo/webpack.config.js
examples/todo/webpack.config.js
var path = require('path'); module.exports = { entry: path.resolve(__dirname, 'lib', 'client.js'), output: { filename: 'app.js', path: path.resolve(__dirname, 'lib'), }, };
var path = require('path'); module.exports = { entry: [ 'babel-core/polyfill', path.resolve(__dirname, 'lib', 'client.js'), ], output: { filename: 'app.js', path: path.resolve(__dirname, 'lib'), }, };
Load babel-core/polyfill in the example (thanks to @DylanSale)
Load babel-core/polyfill in the example (thanks to @DylanSale)
JavaScript
bsd-2-clause
AndriyShepitsen/react-relay-cbi,denvned/isomorphic-relay-router