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
bc19de3950abae46adf992dfa77ee890e8ed6aa9
src/DELETE/sanitizeArguments/index.js
src/DELETE/sanitizeArguments/index.js
const is = require('is'); const url = require('url'); /** * Returns an object containing the required properties to make an * http request. * @module DELETE/sanitizeArguments * @param {array} a - Arguments * @return {object} args - "Sanitized" arguments */ module.exports = function sanitizeArguments(a = []) { c...
const is = require('is'); const url = require('url'); /** * Returns an object containing the required properties to make an * http request. * @module DELETE/sanitizeArguments * @param {array} a - Arguments * @return {object} args - "Sanitized" arguments */ module.exports = function sanitizeArguments(a = []) { c...
DELETE correct options object + protocol handling
DELETE correct options object + protocol handling
JavaScript
mit
opensoars/ezreq
93fa682de8cd2ed950432c64c32c352579cfa7cd
views/board.js
views/board.js
import React from 'react'; import Invocation from './invocation'; import StatusLine from './status_line'; export default React.createClass({ getInitialState() { return {vcsData: { isRepository: true, branch: 'name', status: 'clean' }}; }, componentWillMou...
import React from 'react'; import Invocation from './invocation'; import StatusLine from './status_line'; export default React.createClass({ getInitialState() { return {vcsData: { isRepository: true, branch: 'name', status: 'clean' }}; }, componentWillMou...
Add a shortcut to toggle debug mode.
Add a shortcut to toggle debug mode.
JavaScript
mit
Young55555/black-screen,rocky-jaiswal/black-screen,over300laughs/black-screen,rocky-jaiswal/black-screen,smaty1/black-screen,drew-gross/black-screen,noikiy/black-screen,toxic88/black-screen,AnalogRez/black-screen,RyanTech/black-screen,alessandrostone/black-screen,mzgnr/black-screen,jbhannah/black-screen,jassyboy/black-...
74eed05c7175e7fe96d54286f7feaaf68fcc3085
addon/services/ember-ambitious-forms.js
addon/services/ember-ambitious-forms.js
import Ember from 'ember' import AFField, { DEFAULT_CONFIG as FIELD_DEFAULT_CONFIG } from '../components/af-field' import i18n from '../mixins/i18n' import loc from '../mixins/loc' import restless from '../mixins/restless' import validations from '../mixins/validations' const AF_FIELD_MIXINS = { i18n, loc, restless,...
import Ember from 'ember' import { DEFAULT_CONFIG as FIELD_DEFAULT_CONFIG } from '../components/af-field' import i18n from '../mixins/i18n' import loc from '../mixins/loc' import restless from '../mixins/restless' import validations from '../mixins/validations' const AF_FIELD_MIXINS = { i18n, loc, restless, validati...
Load addons into resolver AFField instead of global AFField
Load addons into resolver AFField instead of global AFField
JavaScript
mit
dough-com/ember-ambitious-forms,dough-com/ember-ambitious-forms
11c687b1d5bb1eb5a09c7efb6086ee6d3f536d0e
tests/test-files/preserve-simple-binary-expressions/input.js
tests/test-files/preserve-simple-binary-expressions/input.js
a * b; 10*5; 10 * 5; 10e5*5; 10 * (5 + 10); 10*(5 + 10);
a * b; a*b; 10*5; 10 * 5; 10e5*5; 10 * (5 + 10); 10*(5 + 10);
Add test for two variables being multiplied who lack a space in between.
Add test for two variables being multiplied who lack a space in between.
JavaScript
mit
Mark-Simulacrum/attractifier,Mark-Simulacrum/pretty-generator
29de57f99e6946e6db7257d650b860eaf2f58a7d
app/assets/javascripts/carnival/advanced_search.js
app/assets/javascripts/carnival/advanced_search.js
$(document).ready(function(){ $("#advanced_search_toggler").click(function(e){ $('body').append('<div class="as-form-overlay">') $("#advanced_search_toggler").toggleClass('is-opened') $("#advanced_search_form").toggle(); $(".as-form-overlay").click(function(e){ $(".as-form-overlay").remove(); ...
$(document).ready(function(){ $("#advanced_search_toggler").click(function(e){ $('body').append('<div class="as-form-overlay">') $("#advanced_search_toggler").toggleClass('is-opened') $("#advanced_search_form").toggle(); $('#advanced_search_form').find('input').focus(); $(".as-form-overlay").clic...
Set focus on the first advanced search field
Set focus on the first advanced search field
JavaScript
mit
cartolari/carnival,dsakuma/carnival,dsakuma/carnival,Vizir/carnival,dsakuma/carnival,cartolari/carnival,dsakuma/carnival,Vizir/carnival,cartolari/carnival,Vizir/carnival,cartolari/carnival,Vizir/carnival,cartolari/carnival,Vizir/carnival,dsakuma/carnival
bebd287f6a3552fcd0eabfa28afd522da32a6478
etc/protractorConfSauce.js
etc/protractorConfSauce.js
var pr = process.env.TRAVIS_PULL_REQUEST; var souceUser = process.env.SAUCE_USERNAME || "liqd"; var sauceKey = process.env.SAUCE_ACCESS_KEY; var name = ((pr === "false") ? "" : "#" + pr + " ") + process.env.TRAVIS_COMMIT; var common = require("./protractorCommon.js"); var local = { sauceUser: souceUser, sauce...
var pr = process.env.TRAVIS_PULL_REQUEST; var souceUser = process.env.SAUCE_USERNAME || "liqd"; var sauceKey = process.env.SAUCE_ACCESS_KEY; var name = ((pr === "false") ? "" : "#" + pr + " ") + process.env.TRAVIS_COMMIT; var common = require("./protractorCommon.js"); var local = { sauceUser: souceUser, sauce...
Disable direct connect for sauce labs
Disable direct connect for sauce labs
JavaScript
agpl-3.0
liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator
d718fa64b1b3ab4fc0aa9c678faf15477a205dce
app/assets/javascripts/views/components/Editor/fields/virtualKeyboard.js
app/assets/javascripts/views/components/Editor/fields/virtualKeyboard.js
import React, {Component, PropTypes} from 'react'; import t from 'tcomb-form'; function renderInput(locals) { const onChange = function (event) { locals.onChange(event.target.value); }; const triggerRealInputChange = function (event) { locals.onChange(document.getElementById('virtual-keyboard-helper-' +...
import React, {Component, PropTypes} from 'react'; import t from 'tcomb-form'; function renderInput(locals) { const onChange = function (event) { locals.onChange(event.target.value); }; const triggerRealInputChange = function (event) { locals.onChange(document.getElementById('virtual-keyboard-helper-' +...
Fix bug with moving up and down
Fix bug with moving up and down
JavaScript
apache-2.0
First-Peoples-Cultural-Council/fv-web-ui,First-Peoples-Cultural-Council/fv-web-ui,First-Peoples-Cultural-Council/fv-web-ui,First-Peoples-Cultural-Council/fv-web-ui,First-Peoples-Cultural-Council/fv-web-ui
49500617b9ffe668dd4883c9190cac4c1ca15781
indico/htdocs/js/utils/i18n.js
indico/htdocs/js/utils/i18n.js
(function(global) { "use strict"; var default_i18n = new Jed({ locale_data: TRANSLATIONS, domain: "indico" }); global.i18n = default_i18n; global.$T = _.bind(default_i18n.gettext, default_i18n); ['gettext', 'ngettext', 'pgettext', 'npgettext', 'translate'].forEach(function(met...
(function(global) { "use strict"; var default_i18n = new Jed({ locale_data: global.TRANSLATIONS, domain: "indico" }); global.i18n = default_i18n; global.$T = _.bind(default_i18n.gettext, default_i18n); ['gettext', 'ngettext', 'pgettext', 'npgettext', 'translate'].forEach(funct...
Make it more obvious that TRANSLATIONS is global
Make it more obvious that TRANSLATIONS is global
JavaScript
mit
ThiefMaster/indico,OmeGak/indico,mvidalgarcia/indico,indico/indico,ThiefMaster/indico,DirkHoffmann/indico,pferreir/indico,DirkHoffmann/indico,mvidalgarcia/indico,ThiefMaster/indico,pferreir/indico,indico/indico,mic4ael/indico,pferreir/indico,mic4ael/indico,mic4ael/indico,DirkHoffmann/indico,OmeGak/indico,mvidalgarcia/i...
0939f9e32aa620132b444799f864056a097ead2d
test/e2e/main.js
test/e2e/main.js
'use strict'; describe('Sign up page', function () { var watchButton; beforeEach(function () { watchButton = element('.btn-primary'); }); it('should have Watch/Unwatch disabled by default', function() { expect(watchButton.attr('disabled')).toBeTruthy(); }); it('should enable Watch/Unwatch button', functi...
'use strict'; describe('Sign up page', function () { var watchButton; beforeEach(function () { watchButton = element('.btn-primary'); }); it('should have Watch enabled by default', function() { expect(watchButton.attr('disabled')).toBeFalsy(); }); it('should enable Watch/Unwatch button', function() { i...
Update default behavior of Watch button
Update default behavior of Watch button
JavaScript
mit
seriema/npmalerts-web,seriema/npmalerts-web
59745c5117613e7822056fe75ceb502ef702853d
example/user/controller.js
example/user/controller.js
var users = require('./user-dump'), Promise = require('bluebird') module.exports = { get : Get, add : Add }; function Get(request,reply) { setTimeout(function() { reply.data = users; reply.continue(); },500); } function Add(request,reply) { setTimeout(function() { users.push({name : request.payload....
var users = require('./stub'), Promise = require('bluebird') module.exports = { get : Get, add : Add }; function Get(request,reply) { setTimeout(function() { reply.data = users; reply.continue(); },500); } function Add(request,reply) { setTimeout(function() { users.push({name : request.payload.name,...
Use correct file name for db stub
Use correct file name for db stub
JavaScript
mit
Pranay92/hapi-next
7a7a6905f01aa99f5ff2c75cee165cf691dde8eb
ui/src/shared/components/FancyScrollbar.js
ui/src/shared/components/FancyScrollbar.js
import React, {Component, PropTypes} from 'react' import classnames from 'classnames' import {Scrollbars} from 'react-custom-scrollbars' class FancyScrollbar extends Component { constructor(props) { super(props) } static defaultProps = { autoHide: true, autoHeight: false, } render() { const...
import React, {Component, PropTypes} from 'react' import classnames from 'classnames' import {Scrollbars} from 'react-custom-scrollbars' class FancyScrollbar extends Component { constructor(props) { super(props) } static defaultProps = { autoHide: true, autoHeight: false, } handleMakeDiv = clas...
Update FancyScrollBar to use arrow properties
Update FancyScrollBar to use arrow properties
JavaScript
mit
mark-rushakoff/influxdb,nooproblem/influxdb,influxdb/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,influxdata/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,li-ang/influxdb,nooproblem/influxdb,li-ang/influxdb,mark-rushakoff/influxdb,nooproblem...
eca69d314c990f7523742277cd104ef5371a49d2
test/dummy/app/assets/javascripts/application.js
test/dummy/app/assets/javascripts/application.js
// This is a manifest file that'll be compiled into including all the files listed below. // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically // be included in the compiled file accessible from http://example.com/assets/application.js // It's not advisable to add code directl...
// This is a manifest file that'll be compiled into including all the files listed below. // Add new JavaScript/Coffee code in separate files in this directory and they'll automatically // be included in the compiled file accessible from http://example.com/assets/application.js // It's not advisable to add code directl...
Remove jQuery from the assets
Remove jQuery from the assets
JavaScript
mit
Soluciones/kpi,Soluciones/kpi,Soluciones/kpi
1c84ae2c3ebe985ed1e5348cd4ee2cdb4aee1be3
test/mriTests.js
test/mriTests.js
"use strict" const mocha = require('mocha'); const expect = require('chai').expect; const fs = require('fs'); const mri = require('../src/mri'); describe("Detect CSharp functions", function(){ it("should detect functions", function(){ const expected = ["DiscoverTestsToExecute", "GetTestsThatCall", "GetTes...
"use strict" const mocha = require('mocha'); const expect = require('chai').expect; const fs = require('fs'); const mri = require('../src/mri'); describe("Detect CSharp functions", function(){ it("should detect functions", function(){ this.timeout(5000); const expected = ["DiscoverTestsTo...
Add timeout to mri tests
Add timeout to mri tests
JavaScript
mit
vgaltes/CrystalGazer,vgaltes/CrystalGazer
ad3279b9d7642dbe53e951ea7d7131e637c4e589
tests/lib/rules/no-const-outside-module-scope.js
tests/lib/rules/no-const-outside-module-scope.js
'use strict'; //------------------------------------------------------------------------------ // Requirements //------------------------------------------------------------------------------ var rule = require('../../../lib/rules/no-const-outside-module-scope'); var RuleTester = require('eslint').RuleTester; //---...
'use strict'; //------------------------------------------------------------------------------ // Requirements //------------------------------------------------------------------------------ var rule = require('../../../lib/rules/no-const-outside-module-scope'); var RuleTester = require('eslint').RuleTester; //---...
Add output returned by the fixer
Test: Add output returned by the fixer
JavaScript
mit
Turbo87/eslint-plugin-ember-internal
fa126551f8dafa5171aca253e6add5ecc7b928b5
src/docs/components/SpinningDoc.js
src/docs/components/SpinningDoc.js
// (C) Copyright 2014-2016 Hewlett Packard Enterprise Development LP import React, { Component } from 'react'; import Spinning from 'grommet/components/icons/Spinning'; import DocsArticle from '../../components/DocsArticle'; import Code from '../../components/Code'; export default class SpinningDoc extends Component ...
// (C) Copyright 2014-2016 Hewlett Packard Enterprise Development LP import React, { Component } from 'react'; import Spinning from 'grommet/components/icons/Spinning'; import DocsArticle from '../../components/DocsArticle'; import Code from '../../components/Code'; export default class SpinningDoc extends Component ...
Fix import path of Spinning usage
Fix import path of Spinning usage
JavaScript
apache-2.0
grommet/grommet-docs,grommet/grommet-docs
b2403270ce82fdae09db5e07b07ea6f92bb955d6
core-plugins/shared/1/as/webapps/project-viewer/html/js/config/config.js
core-plugins/shared/1/as/webapps/project-viewer/html/js/config/config.js
/** * This is the default (fallback) configuration file for the web application. */ // Create empty CONFIG object as fallback if it does not exist. var CONFIG = CONFIG || {}; // Default configuration. var DEFAULT_CONFIG = {};
/** * This is the default (fallback) configuration file for the web application. */ // Default configuration. var DEFAULT_CONFIG = {};
Remove duplicate declaration of CONFIG.
Remove duplicate declaration of CONFIG.
JavaScript
apache-2.0
aarpon/obit_shared_core_technology,aarpon/obit_shared_core_technology,aarpon/obit_shared_core_technology
02f49e650e067a9dac49998bf2ddfdcf38b23eb8
Resources/lib/Como/Models.js
Resources/lib/Como/Models.js
module.exports = function (Como) { var models = {}, // include underscore utility-belt _ = require('/lib/Underscore/underscore.min'); _.each(Como.config.models, function (m) { var _m = require('/app/models/' + m.name), mName = m.name.toLowerCase(); models[mName] = n...
module.exports = function (Como) { var models = {}, // include underscore utility-belt _ = require('/lib/Underscore/underscore.min'); _.each(Como.config.models, function (m) { var _m = require('/app/models/' + m.name), mName = m.name.toLowerCase(); models[mName] = n...
Truncate during app start causing error, disable it for now.
Truncate during app start causing error, disable it for now.
JavaScript
apache-2.0
geekzy/tiapp-como
ce7365ee16191777ad76d4009e2e0d21cde204fe
app/initializers/session.js
app/initializers/session.js
export default { name: 'app.session', initialize(container, application) { application.inject('controller', 'session', 'service:session'); application.inject('route', 'session', 'service:session'); } };
export default { name: 'app.session', initialize(application) { application.inject('controller', 'session', 'service:session'); application.inject('route', 'session', 'service:session'); } };
Fix a deprecation warning about `initialize` arguments
Fix a deprecation warning about `initialize` arguments This shows up in the browser console. Fixed as suggested at: http://emberjs.com/deprecations/v2.x/#toc_initializer-arity
JavaScript
apache-2.0
Susurrus/crates.io,achanda/crates.io,achanda/crates.io,steveklabnik/crates.io,achanda/crates.io,rust-lang/crates.io,steveklabnik/crates.io,Susurrus/crates.io,steveklabnik/crates.io,rust-lang/crates.io,rust-lang/crates.io,achanda/crates.io,steveklabnik/crates.io,Susurrus/crates.io,rust-lang/crates.io,Susurrus/crates.io
41abdbad1fc8af309a852770478a0a517c0a6395
DebugGlobals.js
DebugGlobals.js
/** * Globals we expose on the window object for manual debugging with the Chrome * console. * * TODO: Consider disabling this for release builds. * * @flow */ import * as actions from './actions' import store from './store' import parseExpression from './parseExpression' /** * Parse the given expression text...
/** * Globals we expose on the window object for manual debugging with the Chrome * console. * * @flow */ import {NativeModules} from 'react-native' import * as actions from './actions' import store from './store' import parseExpression from './parseExpression' /** * Parse the given expression text and place t...
Update debug globals code to allow modifications from the Chrome console
Update debug globals code to allow modifications from the Chrome console Previously, refreshes wouldn't happen until the next call from native code. Now, we run a setInterval that runs all the time to force any Chrome-triggered events to get flushed.
JavaScript
mit
alangpierce/LambdaCalculusPlayground,alangpierce/LambdaCalculusPlayground,alangpierce/LambdaCalculusPlayground
0e91b9b2a063a22bf1033777452c8c87cb399829
src/app/index.route.js
src/app/index.route.js
function routerConfig ($stateProvider, $urlRouterProvider) { 'ngInject'; $stateProvider // Holding page .state('holding-page', { url: '/', views: { 'content': { templateUrl: 'app/holding-page/holding-page.html' } } }) // Home page .state('home', { ...
function routerConfig ($stateProvider, $urlRouterProvider) { 'ngInject'; $stateProvider // Holding page .state('holding-page', { url: '/', views: { 'content': { templateUrl: 'app/holding-page/holding-page.html' } } }) // Home page .state('home', { ...
Add routing for EUFN and Lancastrians projects
Add routing for EUFN and Lancastrians projects
JavaScript
mit
RobEasthope/lazarus,RobEasthope/lazarus
657ea31a8373be43b33d80cfe58915e294ec21ea
index.js
index.js
var persist = require('./lib/persist'); module.exports = persist;
var persist = require('./lib/persist'); /** * @param String db MongoDB connection string * @param Array data * @return promise * This module makes use of the node-promise API. * Operate on the singular result argument passed to a `then` callback, as follows: * * persist(db, data).then(function (result) { * /...
Add a more useful comment
Add a more useful comment
JavaScript
mit
imgges/persist
0e3db15aa1c142c5028a0da35f0da42a237aa306
index.js
index.js
'use strict'; module.exports = function(prompts) { // This method will only show prompts that haven't been supplied as options. This makes the generator more composable. const filteredPrompts = []; const props = new Map(); prompts.forEach(function prompts(prompt) { this.option(prompt.name); const opti...
'use strict'; module.exports = function(prompts) { // This method will only show prompts that haven't been supplied as options. This makes the generator more composable. const filteredPrompts = []; const props = new Map(); prompts.forEach(function prompts(prompt) { const option = this.options[prompt.name]...
Fix to allow non boolean options
Fix to allow non boolean options
JavaScript
mit
artefact-group/yeoman-option-or-prompt
c631ca483da85d04ef13afcf9e9c0f78a74cfc61
index.js
index.js
exports.register = function(plugin, options, next) { // Wait 10 seconds for existing connections to close then exit. var stop = function() { plugin.servers[0].stop({ timeout: 10 * 1000 }, function() { process.exit(); }); }; process.on('SIGTERM', stop); process.on('SIGINT', stop); ...
exports.register = function(server, options, next) { // Wait 10 seconds for existing connections to close then exit. var stop = function() { server.connections[0].stop({ timeout: 10 * 1000 }, function() { process.exit(); }); }; process.on('SIGTERM', stop); process.on('SIGINT', sto...
Upgrade for compatability with Hapi 8
Upgrade for compatability with Hapi 8
JavaScript
mit
KyleAMathews/hapi-death
8044a284695bb16567d50c4bb58a965f7d181bfe
index.js
index.js
var path = require('path'); module.exports = function (source) { if (this.cacheable) { this.cacheable(); } var filename = path.basename(this.resourcePath), matches = 0, processedSource; processedSource = source.replace(/React\.createClass\s*\(\s*\{/g, function (match) { matches++; ret...
var path = require('path'); module.exports = function (source) { if (this.cacheable) { this.cacheable(); } var filename = path.basename(this.resourcePath), matches = 0, processedSource; processedSource = source.replace(/[Rr]eact\.createClass\s*\(/g, function (match) { matches++; retur...
Allow lowercase React import and using an object reference
Allow lowercase React import and using an object reference
JavaScript
mit
gaearon/react-hot-loader,gaearon/react-hot-loader
f2bbd2ed9f3a7cac8075d1ddb1b294c5069b0589
prototype.spawn.js
prototype.spawn.js
module.exports = function () { StructureSpawn.prototype.createCustomCreep = function(energy, roleName) { var numberOfParts = Math.floor(energy / 350); var body = []; for (let i = 0; i < numberOfParts; i++) { body.push(WORK); } for (let i = 0; ...
module.exports = function () { StructureSpawn.prototype.createCustomCreep = function(energy, roleName) { var numberOfParts = Math.floor(energy / 350); var body = []; for (let i = 0; i < numberOfParts; i++) { body.push(WORK); } for (let i = 0; ...
WORK WORK CARRY CARRY MOVE MOVE MOVE
WORK WORK CARRY CARRY MOVE MOVE MOVE
JavaScript
mit
Raltrwx/Ralt-Screeps
7c3bcda4f834cfab2fdd4caa32b59ea6c8082176
release.js
release.js
var shell = require('shelljs') if (exec('git status --porcelain').stdout) { console.error('Git working directory not clean. Please commit all chances to release a new package to npm.') process.exit(2) } var versionIncrement = process.argv[process.argv.length - 1] var versionIncrements = ['major', 'minor', 'patch'...
var shell = require('shelljs') if (exec('git status --porcelain').stdout) { console.error('Git working directory not clean. Please commit all chances to release a new package to npm.') process.exit(2) } var versionIncrement = process.argv[process.argv.length - 1] var versionIncrements = ['major', 'minor', 'patch'...
Use === instead of == to please the standard
Use === instead of == to please the standard
JavaScript
mit
mafintosh/mongojs
29aae66080fcdff0fe62486d445c6a3a9aeff406
app/assets/javascripts/forest/admin/partials/forest_tables.js
app/assets/javascripts/forest/admin/partials/forest_tables.js
// Forest tables $(document).on('mouseenter', '.forest-table tbody tr', function() { var $row = $(this); $row.addClass('active'); $(document).one('turbolinks:before-cache.forestTables', function() { $row.removeClass('active'); }); }); $(document).on('mouseleave', '.forest-table tbody tr', function() { ...
// Forest tables $(document).on('mouseenter', '.forest-table tbody tr', function() { var $row = $(this); $row.addClass('active'); $(document).one('turbolinks:before-cache.forestTables', function() { $row.removeClass('active'); }); }); $(document).on('mouseleave', '.forest-table tbody tr', function() { ...
Allow modifier key press when opening table rows
Allow modifier key press when opening table rows
JavaScript
mit
dylanfisher/forest,dylanfisher/forest,dylanfisher/forest
1d46cc1e616d64cdae5b29e9f777c309b3ea08f7
SPAWithAngularJS/module3/directives/controllersInsideDirective/js/app.shoppingListDirective.js
SPAWithAngularJS/module3/directives/controllersInsideDirective/js/app.shoppingListDirective.js
// app.shoppingListDirective.js (function() { "use strict"; angular.module("ShoppingListDirectiveApp") .directive("shoppingList", ShoppingList); function ShoppingList() { const templateUrl = "../templates/shoppingList.view.html"; const ddo = { restrict: "E", templateUrl, scope: { ...
// app.shoppingListDirective.js (function() { "use strict"; angular.module("ShoppingListDirectiveApp") .directive("shoppingList", ShoppingList); function ShoppingList() { const templateUrl = "../templates/shoppingList.view.html"; const ddo = { restrict: "E", templateUrl, scope: { ...
Edit controllerAs label for ShoppingListDirectiveController
Edit controllerAs label for ShoppingListDirectiveController
JavaScript
mit
var-bin/angularjs-training,var-bin/angularjs-training,var-bin/angularjs-training,var-bin/angularjs-training
446503cb5c27964f693b0d931b52ff18f862b159
assets/js/external-links.js
assets/js/external-links.js
//// External Links // Open external links in a new tab. $(function () { $('a').each(function () { if ( $(this).href.indexOf(window.location.host) == -1 ) { $(this).attr('target', '_blank'); } }); });
//// External Links // Open external links in a new tab. $(function () { $('a').each(function () { if ( $(this).href.indexOf(window.location.host) === -1 ) { $(this).attr('target', '_blank'); } }); });
Fix "Expected '===' and instead saw '=='."
Fix "Expected '===' and instead saw '=='."
JavaScript
mit
eustasy/puff-core,eustasy/puff-core,eustasy/puff-core
5b7eda2be2c50e4aab45b862c2f9cde0d31c2dfe
gulpfile.js
gulpfile.js
var gulp = require('gulp'); var clean = require('gulp-clean'); var zip = require('gulp-zip'); var bases = { root: 'dist/' }; var paths = [ 'core/actions/*', 'core/common/**', 'admin/**', '!admin/config/*', 'boxoffice/**', '!boxoffice/config/*', 'customer/**', '!customer/config/*',...
var gulp = require('gulp'); var clean = require('gulp-clean'); var zip = require('gulp-zip'); var bases = { root: 'dist/' }; var paths = [ 'core/actions/*', 'core/common/**', 'admin/**', '!admin/config/*', 'boxoffice/**', '!boxoffice/config/*', 'customer/**', '!customer/config/*',...
Copy core .htaccess file to dist
Copy core .htaccess file to dist
JavaScript
mit
ssigg/ticketbox-server-php,ssigg/ticketbox-server-php,ssigg/ticketbox-server-php
77726d201de27f48485de497ff706ccea11becc2
src/config/config.default.js
src/config/config.default.js
// TODO Just add fallbacks to config.js var path = require('path') module.exports = { port: 8080, address: '127.0.0.1', session_secret: 'asdf', database: { host: 'mongodb://127.0.0.1/', // MongoDB host name: 'vegosvar', // MongoDB database name }, facebook: { app_id: '', app_secret: '', ...
// TODO Just add fallbacks to config.js var path = require('path') module.exports = { port: 8080, address: '127.0.0.1', session_secret: 'asdf', database: { host: 'mongodb://127.0.0.1/', // MongoDB host name: 'vegosvar', // MongoDB database name }, facebook: { app_id: '', app_secret: '', ...
Add config for instagram authentication
Add config for instagram authentication
JavaScript
unlicense
Vegosvar/Vegosvar,Vegosvar/Vegosvar,Vegosvar/Vegosvar
e4e9561be08162dc7d00ce5cf38f55b52cad5863
src/models/interact.js
src/models/interact.js
var _ = require("lodash"); var Bacon = require("baconjs"); var Interact = module.exports; Interact.ask = function (question) { var readline = require("readline").createInterface({ input: process.stdin, output: process.stdout }); return Bacon.fromCallback(_.partial(readline.question.bind(readline), ques...
var _ = require("lodash"); var Bacon = require("baconjs"); var Interact = module.exports; Interact.ask = function (question) { var readline = require("readline").createInterface({ input: process.stdin, output: process.stdout }); return Bacon.fromCallback(_.partial(readline.question.bind(readline), ques...
Make Interact.confirm use configurable acceptance strings
Make Interact.confirm use configurable acceptance strings
JavaScript
apache-2.0
CleverCloud/clever-tools,CleverCloud/clever-tools,CleverCloud/clever-tools
8695e857ae870b1e991cd511ffd70101969876cc
api/feed/pending/matchExec.js
api/feed/pending/matchExec.js
(function () { var cogClass = function () {}; cogClass.prototype.exec = function (params, request, response) { var oops = this.sys.apiError; var sys = this.sys; var userID = params.id; var userKey = params.key; var pages = sys.pages; pages.reset(); ...
(function () { var cogClass = function () {}; cogClass.prototype.exec = function (params, request, response) { var oops = this.sys.apiError; var sys = this.sys; var userID = params.id; var userKey = params.key; var pages = sys.pages; pages.reset(); ...
Set short delay for demo
Set short delay for demo
JavaScript
unlicense
fbennett/newswriter
7cf8e87de3aac94d6371799c1bc23c117df06b8d
ti_mocha_tests/modules/commonjs/commonjs.legacy.index_json/1.0.0/commonjs.legacy.index_json.js
ti_mocha_tests/modules/commonjs/commonjs.legacy.index_json/1.0.0/commonjs.legacy.index_json.js
module.exports = { name: 'commonjs.legacy.index_json/commonjs.legacy.index_js.js' };
module.exports = { name: 'commonjs.legacy.index_json/commonjs.legacy.index_json.js' };
Fix test input file with incorrect contets
Fix test input file with incorrect contets
JavaScript
apache-2.0
mano-mykingdom/titanium_mobile,ashcoding/titanium_mobile,cheekiatng/titanium_mobile,mano-mykingdom/titanium_mobile,mano-mykingdom/titanium_mobile,cheekiatng/titanium_mobile,ashcoding/titanium_mobile,cheekiatng/titanium_mobile,cheekiatng/titanium_mobile,ashcoding/titanium_mobile,ashcoding/titanium_mobile,ashcoding/titan...
dda231347aeba1e692ddbf31d10897d6499cd44b
src/fn/fn-buckets-quantiles.js
src/fn/fn-buckets-quantiles.js
'use strict'; require('es6-promise').polyfill(); var debug = require('../helper/debug')('fn-quantiles'); var LazyFiltersResult = require('../model/lazy-filters-result'); var fnBuckets = require('./fn-buckets'); module.exports = function (datasource) { return function fn$quantiles (numBuckets) { debug('fn$quant...
'use strict'; var createBucketsFn = require('./fn-buckets').createBucketsFn; var FN_NAME = 'quantiles'; module.exports = function (datasource) { return createBucketsFn(datasource, FN_NAME, '>'); }; module.exports.fnName = FN_NAME;
Migrate quantiles to buckets creation
Migrate quantiles to buckets creation
JavaScript
bsd-3-clause
CartoDB/turbo-cartocss
2fa1bad5ac36807f47c184c31c36f0ecc050cea9
draft-js-inline-toolbar-plugin/src/components/Toolbar/__test__/Toolbar.js
draft-js-inline-toolbar-plugin/src/components/Toolbar/__test__/Toolbar.js
import React, { Component } from 'react'; import { expect } from 'chai'; import { mount } from 'enzyme'; import Toolbar from '../index'; describe('Toolbar', () => { it('allows children to override the content', (done) => { const structure = [class Child extends Component { componentDidMount() { set...
import React, { Component } from 'react'; import { expect } from 'chai'; import { mount } from 'enzyme'; import Toolbar from '../index'; describe('Toolbar', () => { it('allows children to override the content', (done) => { const structure = [class Child extends Component { componentDidMount() { set...
Fix test for inline toolbar
Fix test for inline toolbar
JavaScript
mit
draft-js-plugins/draft-js-plugins,dagopert/draft-js-plugins,nikgraf/draft-js-plugin-editor,nikgraf/draft-js-plugin-editor,draft-js-plugins/draft-js-plugins,dagopert/draft-js-plugins,nikgraf/draft-js-plugin-editor,draft-js-plugins/draft-js-plugins,dagopert/draft-js-plugins,draft-js-plugins/draft-js-plugins
9034a21f2762b6b01d6dc45a9f049e60cf3d7439
addon/components/course-publicationcheck.js
addon/components/course-publicationcheck.js
/* eslint-disable ember/no-computed-properties-in-native-classes */ import Component from '@glimmer/component'; import { inject as service } from '@ember/service'; export default class CoursePublicationCheckComponent extends Component { @service router; get showUnlinkIcon() { if (!this.args.course.courseObjec...
/* eslint-disable ember/no-computed-properties-in-native-classes */ import Component from '@glimmer/component'; import { inject as service } from '@ember/service'; import { use } from 'ember-could-get-used-to-this'; import ResolveAsyncValue from 'ilios-common/classes/resolve-async-value'; export default class CoursePu...
Resolve objectives in course publication check
Resolve objectives in course publication check We can also use the length value of the relationship to check if there are parents which engages auto tracking.
JavaScript
mit
ilios/common,ilios/common
5d9f0dbd9e287ad320f020238ab6d3e66ffb2f49
addon/components/floating-mobile-buttons.js
addon/components/floating-mobile-buttons.js
import Ember from 'ember'; import layout from '../templates/components/floating-mobile-buttons'; export default Ember.Component.extend({ layout, tagName: 'ul', classNames: ['floating-buttons'], classNameBindings: ['active:active', 'bottom:bottom', 'top:top', 'left:left', 'right:right'], active: false, chil...
import Ember from 'ember'; import layout from '../templates/components/floating-mobile-buttons'; export default Ember.Component.extend({ layout, tagName: 'ul', classNames: ['floating-buttons'], classNameBindings: ['active:active', 'bottom:bottom', 'top:top', 'left:left', 'right:right'], active: false, chil...
Use the afterRender run loop to check if has children
Use the afterRender run loop to check if has children
JavaScript
mit
yontxu/ember-floating-mobile-buttons,yontxu/ember-floating-mobile-buttons
bf5b8c20974dfe7d16dde885aa02ec39471e652a
great/static/js/models/artist.js
great/static/js/models/artist.js
"use strict"; great.Artist = Backbone.Model.extend({ }); great.ArtistsCollection = Backbone.PageableCollection.extend({ model: great.Artist, comparator: "name", url: "/great/music/artists/", mode: "client", });
"use strict"; great.Artist = Backbone.Model.extend({ urlRoot: "/great/music/artists/", }); great.ArtistsCollection = Backbone.PageableCollection.extend({ model: great.Artist, comparator: "name", url: "/great/music/artists/", mode: "client", });
Add a urlRoot to allow use outside of a collection.
Add a urlRoot to allow use outside of a collection.
JavaScript
mit
Julian/Great,Julian/Great,Julian/Great
8f0b0267da395ce2824122496408b4c3ac014a3d
src/camel-case.js
src/camel-case.js
import R from 'ramda'; import uncapitalize from './uncapitalize.js'; import pascalCase from './pascal-case.js'; // a -> a const camelCase = R.compose(uncapitalize, pascalCase); export default camelCase;
import R from 'ramda'; import compose from './util/compose.js'; import uncapitalize from './uncapitalize.js'; import pascalCase from './pascal-case.js'; // a -> a const camelCase = compose(uncapitalize, pascalCase); export default camelCase;
Refactor camelCase function to use custom compose function
Refactor camelCase function to use custom compose function
JavaScript
mit
restrung/restrung-js
6a5598ed7f1cf85502d58e7a9b774d31419ff79c
js/kamfu.js
js/kamfu.js
$(document).ready(function() { console.log( "ready!" ); var gameForeground = $('#gameForeground')[0]; var gameFront = $('#gameFront')[0]; var gameBack = $('#gameBack')[0]; var gameText = $('#gameText')[0]; gameCommon.setup(gameForeground, gameFront, gameBack, gameText); var video = documen...
$(document).ready(function() { console.log( "ready!" ); var gameForeground = $('#gameForeground')[0]; var gameFront = $('#gameFront')[0]; var gameBack = $('#gameBack')[0]; var gameText = $('#gameText')[0]; gameCommon.setup(gameForeground, gameFront, gameBack, gameText); var video = documen...
Remove reset camera click event
Remove reset camera click event
JavaScript
apache-2.0
pabloalba/kam-fu,pabloalba/kam-fu
0ca2b8e525a81eedb21af53b1ac2213b8efa4dd8
web/src/store.js
web/src/store.js
import { compose, createStore, applyMiddleware } from 'redux' import persistState from 'redux-localstorage' import thunk from 'redux-thunk' import RootReducer from 'reducers/RootReducer' export default createStore( RootReducer, compose( applyMiddleware(thunk), persistState(['user']), window.__REDUX_DE...
import { compose, createStore, applyMiddleware } from 'redux' import persistState from 'redux-localstorage' import thunk from 'redux-thunk' import RootReducer from 'reducers/RootReducer' const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose export default createStore( RootReducer, compo...
Fix Redux DevTools for mobile
Fix Redux DevTools for mobile
JavaScript
mit
RailsRoading/wissle,RailsRoading/wissle,RailsRoading/wissle
dc5f805dcea6d0c1dd27a98cadbf2290a323ea87
javascript/staticsearch.js
javascript/staticsearch.js
jQuery(function($) { $('#tipue_search_input').tipuesearch({ 'mode': 'static', 'contentLocation': '/search_index' }); $("form.no-pageload input").keypress(function(e){ var k = e.keyCode || e.which; if(k == 13){ e.preventDefault(); } }); $("form.button-submit input.submit-button").click(function(e){ ...
jQuery(function($) { //prevent undeclared variable var tipuesearch = {"pages": [ {"title": "", "text":"", "tags":"", "loc":""} ]}; $('#tipue_search_input').tipuesearch({ 'mode': 'static', 'contentLocation': '/search_index' }); $("form.no-pageload input").keypress(function(e){ var k = e.keyCode || e.wh...
Fix undefined error when no search file found
BUG: Fix undefined error when no search file found
JavaScript
bsd-3-clause
adrexia/silverstripe-staticsearch,adrexia/silverstripe-staticsearch
5c2e5defbe12f099b627ac83302e1caa818d0093
lib/Post.js
lib/Post.js
var config = require('../config.json'); var modIDs = config.modIDs; /** * A single Facebook post or comment. * @class */ var Post = module.exports = function (id) { /** @member {string} */ this.id = id; /** @member {string} */ this.from = ''; /** @member {string} */ this.message = ''; }; /** * Con...
var config = require('../config.json'); var modIDs = config.modIDs; /** * A single Facebook post or comment. * @class */ var Post = module.exports = function (id) { /** @member {string} */ this.id = id; /** @member {string} */ this.from = ''; /** @member {string} */ this.message = ''; }; /** * Con...
Fix message processing for sticker comments.
Fix message processing for sticker comments.
JavaScript
bsd-3-clause
HHDesign/hackbot,rhallie15/hackbot,kern/hackbot,kern/hackbot,samuelcouch/hackbot,rubinovitz/hackbot
48b850d5ba1cdda06a55b8ae5d2727c5c8b4bde4
lib/deck.js
lib/deck.js
var _ = require("lodash"); var EventEmitter = require("events").EventEmitter; var util = require("util"); var ItemCollection = require("./itemcollection"); function Deck(options) { if (!(this instanceof Deck)) { return new Deck(options); } EventEmitter.call(this); this.itemCollection = options.itemCollection ||...
var _ = require("lodash"); var EventEmitter = require("events").EventEmitter; var util = require("util"); var ItemCollection = require("./itemcollection"); var ItemRenderer = require("./itemrenderer"); function Deck(options) { if (!(this instanceof Deck)) { return new Deck(options); } EventEmitter.call(this); t...
Create ItemRenderer from options passed to Deck
Create ItemRenderer from options passed to Deck
JavaScript
mit
pellucidanalytics/decks,pellucidanalytics/decks
0ffa589122d21ab32099ec377ddbab6be15a593a
lib/exec.js
lib/exec.js
'use strict'; var shell = require('shelljs'); var cmd = require('./cmd'); // Execute msbuild.exe with passed arguments module.exports = function exec(args) { process.exit(shell.exec(cmd(args)).code); }
'use strict'; var shell = require('shelljs'); var cmd = require('./cmd'); // Execute nuget.exe with passed arguments module.exports = function exec(args) { const result = shell.exec(cmd(args)).code; if (result !== 0) { console.log(); console.log(`NuGet failed. ERRORLEVEL '${result}'.'`) ...
Fix handling of NuGet errors
Fix handling of NuGet errors
JavaScript
mit
TimMurphy/npm-nuget
bc80e82a05c0a7b19e538ff3773f8966e1bf28f8
lib/main.js
lib/main.js
'use babel' const FS = require('fs') const Path = require('path') const {View} = require('./view') const callsite = require('callsite') import {guessName, installPackages, packagesToInstall} from './helpers' // Renamed for backward compatibility if (typeof window.__steelbrain_package_deps === 'undefined') { window._...
'use babel' const FS = require('fs') const Path = require('path') const {View} = require('./view') const callsite = require('callsite') import {guessName, installPackages, packagesToInstall} from './helpers' // Renamed for backward compatibility if (typeof window.__steelbrain_package_deps === 'undefined') { window._...
Handle failure in name guessing
:art: Handle failure in name guessing
JavaScript
mit
steelbrain/package-deps,openlawlibrary/package-deps,steelbrain/package-deps
763e147ba669365e5f38f5b27c0dc1367087c031
lib/util.js
lib/util.js
"use strict"; var Class = require("./Class"); var CompileError = exports.CompileError = Class.extend({ initialize: function () { switch (arguments.length) { case 2: // token, text this._filename = arguments[0].filename; this._pos = arguments[0].pos; this._message = arguments[1]; break; case 3: // ...
"use strict"; var Class = require("./Class"); var CompileError = exports.CompileError = Class.extend({ initialize: function () { switch (arguments.length) { case 2: // token, text this._filename = arguments[0].filename; this._pos = arguments[0].pos; this._message = arguments[1]; break; case 3: // ...
Fix error handling in lexer
Fix error handling in lexer
JavaScript
mit
mattn/JSX,jsx/JSX,jsx/JSX,dj31416/JSX,dj31416/JSX,mattn/JSX,jsx/JSX,jsx/JSX,dj31416/JSX,dj31416/JSX,jsx/JSX,dj31416/JSX
581b1239c070873fbede643c04b654067d5468a5
src/redux/__tests__/random.test.js
src/redux/__tests__/random.test.js
import { expect } from 'chai'; import Immutable from 'immutable'; import { createReducer } from 'rook/lib/redux/createStore'; import reducers from '../modules'; const reducer = createReducer(reducers.random); describe('redux', () => { describe('reducers', () => { describe('random', () => { const initialSta...
import { expect } from 'chai'; import Immutable from 'immutable'; import createReducer from 'rook/lib/redux/createReducer'; import reducers from '../modules'; const reducer = createReducer(reducers.random); describe('redux', () => { describe('reducers', () => { describe('random', () => { const initialState...
Update path to createReducer function
Update path to createReducer function
JavaScript
mit
apazzolini/rook-starter
a92dcb2c0c3b6fb4f79de28c18b3b0dd357d139d
app/components/text-search.js
app/components/text-search.js
export default Ember.TextField.extend(Ember.TargetActionSupport, { change: function() { this.triggerAction({ action: 'search' }); }, insertNewline: function() { this.triggerAction({ action: 'search' }); } });
export default Ember.TextField.extend(Ember.TargetActionSupport, { change: function() { this.triggerAction({ action: 'search' }); } });
Fix for search not working when pressing the enter key.
Fix for search not working when pressing the enter key.
JavaScript
mit
HospitalRun/hospitalrun-frontend,HospitalRun/hospitalrun-frontend,HospitalRun/hospitalrun-frontend,HospitalRun/hospitalrun-frontend
35a6c36ed93b5e45026707925851c1792099aff6
test/commands/domains/index.js
test/commands/domains/index.js
'use strict'; let nock = require('nock'); let cmd = require('../../../commands/domains'); let expect = require('chai').expect; describe('domains', function() { beforeEach(() => cli.mockConsole()); it('shows the domains', function() { let api = nock('https://api.heroku.com:443') .get('/apps/myapp/d...
'use strict'; let nock = require('nock'); let cmd = require('../../../commands/domains'); let expect = require('chai').expect; describe('domains', function() { beforeEach(() => cli.mockConsole()); it('shows the domains', function() { let api = nock('https://api.heroku.com:443') .get('/apps/myapp/d...
Fix domains test after pull & npm install
Fix domains test after pull & npm install
JavaScript
isc
heroku/heroku-apps,heroku/heroku-apps
6772db0ad6d5b4733a9101537795f5fb9dfe3fe1
src/common/core.js
src/common/core.js
var d3 = window.d3; var previousD3ma = window.d3.ma; var d3ma = d3.ma = {}; d3ma.noConflict = function() { window.d3ma= previousD3ma; return d3ma; }; d3ma.assert = function(test, message) { if(test) { return; } throw new Error('[d3.ma] ' + message); }; d3ma.assert(d3, 'd3.js is required'); d3ma.assert( typeof...
var d3 = window.d3; var previousD3ma = window.d3.ma; var d3ma = d3.ma = {}; d3ma.noConflict = function() { window.d3ma= previousD3ma; return d3ma; }; d3ma.assert = function(test, message) { if(test) { return; } throw new Error('[d3.ma] ' + message); }; d3ma.assert(d3, 'd3.js is required'); d3ma.assert( typeof...
Update the d3ma var, make it more global like d3.ma
Update the d3ma var, make it more global like d3.ma
JavaScript
mit
mattma/d3.ma.js
0483e4269e66992329f0c451d2188a2230f7b81c
static/js/components/CourseList.js
static/js/components/CourseList.js
import React from 'react'; import { makeCourseStatusDisplay } from '../util/util'; class CourseList extends React.Component { render() { const { dashboard, courseList } = this.props; let dashboardLookup = {}; for (let course of dashboard.courses) { dashboardLookup[course.id] = course; } l...
import React from 'react'; import _ from 'lodash'; import { makeCourseStatusDisplay } from '../util/util'; class CourseList extends React.Component { render() { const { dashboard } = this.props; let sortedCourses = _.sortBy(dashboard.courses, 'position_in_program'); let table = sortedCourses.map(cours...
Use only information from dashboard API for dashboard display.
Use only information from dashboard API for dashboard display. This fixes a problem with course run ids which may not exist
JavaScript
bsd-3-clause
mitodl/micromasters,mitodl/micromasters,mitodl/micromasters,mitodl/micromasters
1505e4cae9730677d513c81d4cd66df1017e09e5
src/elementType.js
src/elementType.js
import React from 'react'; import createChainableTypeChecker from './utils/createChainableTypeChecker'; function elementType(props, propName, componentName, location, propFullName) { const propValue = props[propName]; const propType = typeof propValue; if (React.isValidElement(propValue)) { return new Erro...
import React from 'react'; import createChainableTypeChecker from './utils/createChainableTypeChecker'; function elementType(props, propName, componentName, location, propFullName) { const propValue = props[propName]; const propType = typeof propValue; if (React.isValidElement(propValue)) { return new Er...
Update for new React types, context, forwardRef, etc
Update for new React types, context, forwardRef, etc
JavaScript
mit
react-bootstrap/prop-types-extra
bf6234ad7030b45fe2ae70c67d720b6fd1898fe9
src/lib/Twilio.js
src/lib/Twilio.js
require('dotenv').config(); export const sendSMS = (message) => { const formData = new FormData() formData.append('body', encodeURIComponent(message)) formData.append('to', encodeURIComponent(process.env.TO_PHONE)) formData.append('from', encodeURIComponent(process.env.FROM_PHONE)) const options = { ...
require('dotenv').config() const twilio = require('twilio') const client = new twilio(process.env.SID, process.env.TOKEN) const sendSMS = (message) => { client.api.messages.create({ body: message, to: process.env.TO_PHONE, from: process.env.FROM_PHONE }) .then((mes) => { console.log(mes.sid) ...
Add sendSMS method and confirm that it works
Add sendSMS method and confirm that it works
JavaScript
mit
severnsc/brewing-app,severnsc/brewing-app
5ca0961dbd3c171a248452726e9f283a955babb8
src/App.js
src/App.js
import React, { Component } from 'react'; import logo from './logo.svg'; import './App.css'; class App extends Component { render() { return ( <div className="App"> <div className="App-header"> <img src={logo} className="App-logo" alt="logo" /> <h2>Welcome to React</h2> ...
import React, { Component } from 'react'; import logo from './logo.svg'; import './App.css'; class App extends Component { render() { return ( <div className="App"> <div className="App-header"> <img src={logo} className="App-logo" alt="logo" /> <h2>Welcome to React</h2> ...
Add leading to zeros to single digit
Add leading to zeros to single digit
JavaScript
mit
cauldyclark15/pomodoro,cauldyclark15/pomodoro
fb083580920b89bda2cbfc0d3be5ad5c2a0ca074
src/jwt-request.js
src/jwt-request.js
var JWTHelper = require('./jwt-helper'); var JWTConfig = require('./jwt-config'); var JWTRequest = { setAuthorizationHeader(options, token) { if (!options.headers) options.headers = {}; options.headers[JWTConfig.authHeader] = `${JWTConfig.authPrefix} ${token}`; return options; }, ...
var JWTHelper = require('./jwt-helper'); var JWTConfig = require('./jwt-config'); var JWTRequest = { setAuthorizationHeader(options, token) { if (!options.headers) options.headers = {}; options.headers[JWTConfig.authHeader] = `${JWTConfig.authPrefix} ${token}`; return options; }, ...
Add skipAuthorization to options instead of a variable in our method
Add skipAuthorization to options instead of a variable in our method
JavaScript
mit
iDay/react-native-http,iktw/react-native-http
bb89d991e9495f15d6fabed5be9441177003b716
bin/bin-executor.js
bin/bin-executor.js
'use strict'; const yarpm = require('../lib'); const argv = process.argv.slice(2); exports.run = function run(options) { yarpm(argv, Object.assign({stdin: process.stdin, stdout: process.stdout, stderr: process.stderr}, options || {})) // Not sure why, but sometimes the process never exits on Git Bash (MINGW64) ...
'use strict'; const yarpm = require('../lib'); const argv = process.argv.slice(2); exports.run = function run(options) { yarpm(argv, Object.assign({stdin: process.stdin, stdout: process.stdout, stderr: process.stderr}, options || {})) // Not sure why, but sometimes the process never exits on Git Bash (MINGW64) ...
Make it work on Node 4
Make it work on Node 4 Node 4 does not support destructuring.
JavaScript
mit
BendingBender/yarpm,BendingBender/yarpm
3f7dba1f6063671e1a0ec6f9b547c7aa05b85260
src/js/directives/textfit.js
src/js/directives/textfit.js
'use strict'; // Directive for using http://www.jacklmoore.com/autosize/ angular.module('Teem') .directive('textfit',[ '$timeout', function($timeout) { return { link: function(scope, element, attrs) { textFit(element); scope.$watch(attrs.ngBind, function() { $timeout(() => { ...
'use strict'; // Directive for using http://www.jacklmoore.com/autosize/ angular.module('Teem') .directive('textfit',[ '$timeout', function($timeout) { return { link: function(scope, element, attrs) { scope.$watch(attrs.ngBind, function() { $timeout(() => { textFit(element);...
Remove first call to textFit
Remove first call to textFit
JavaScript
agpl-3.0
P2Pvalue/teem,P2Pvalue/teem,P2Pvalue/pear2pear,Grasia/teem,P2Pvalue/teem,Grasia/teem,P2Pvalue/pear2pear,Grasia/teem
115a2e1b9c0cad8c5a05c13a73569daff11c76a3
root/test/spec/controllers/action.js
root/test/spec/controllers/action.js
'use strict'; describe('Controller: ActionCtrl', function () { // load the controller's module beforeEach(module('nameApp')); var ActionCtrl, scope; // Initialize the controller and a mock scope beforeEach(inject(function ($controller, $rootScope) { scope = $rootScope.$new(); ActionCtrl = $con...
'use strict'; describe('Controller: ActionCtrl', function () { // load the controller's module beforeEach(module('geboHai')); var ActionCtrl, scope; // Initialize the controller and a mock scope beforeEach(inject(function ($controller, $rootScope) { scope = $rootScope.$new(); ActionCtrl = $con...
Correct app name in ActionCtrl tests
Correct app name in ActionCtrl tests
JavaScript
mit
RaphaelDeLaGhetto/grunt-init-gebo-hai
1c0597d51a0ff4646bff7ffe895cd7ac8c1e77c2
client/components/Loading.js
client/components/Loading.js
import React from 'react'; import { CircularProgress } from 'material-ui/Progress'; import Text from './Text'; const Loading = ({ message }) => ( <div className="loading"> <CircularProgress size={300} thickness={7} mode="indeterminate" /> <Text>{message}</Text> <style jsx>{` ....
import React from 'react'; import { CircularProgress } from 'material-ui/Progress'; import Text from './Text'; const Loading = ({ message }) => ( <div className="loading"> <CircularProgress size={300} mode="indeterminate" /> <Text>{message}</Text> <style jsx>{` .loading { width: 100%; ...
Remove obsolete prop from CircularProgress.
client: Remove obsolete prop from CircularProgress.
JavaScript
mit
u-wave/hub
ae3c0d72e26ec037aac7290fbb248386e35a04c9
scripts/get-latest-platform-tests.js
scripts/get-latest-platform-tests.js
"use strict"; if (process.env.NO_UPDATE) { process.exit(0); } const path = require("path"); const fs = require("fs"); const request = require("request"); // Pin to specific version, reflecting the spec version in the readme. // // To get the latest commit: // 1. Go to https://github.com/w3c/web-platform-tests/tree...
"use strict"; if (process.env.NO_UPDATE) { process.exit(0); } const path = require("path"); const fs = require("fs"); const request = require("request"); // Pin to specific version, reflecting the spec version in the readme. // // To get the latest commit: // 1. Go to https://github.com/w3c/web-platform-tests/tree...
Update to include latest web platform tests
Update to include latest web platform tests Includes https://github.com/w3c/web-platform-tests/pull/5146.
JavaScript
mit
jsdom/whatwg-url,jsdom/whatwg-url,jsdom/whatwg-url
a2b90b5f99c4b4bf0b9049001b1288cc57128259
src/routes/index.js
src/routes/index.js
const router = require('express').Router() const nonUser = require('./non-user') const user = require('./user-only') router.use((req, res, next) => { let loggedIn = false if (req.session.user) { loggedIn = true } res.locals = {loggedIn} next() }) router.use('/', nonUser) router.use('/', user) module.ex...
const router = require('express').Router() const nonUser = require('./non-user') const user = require('./user-only') router.use((req, res, next) => { let loggedIn = false let userId = null if (req.session.user) { loggedIn = true userId = req.session.user.user_id } res.locals = {loggedIn, userId} co...
Add user id of logged in user to res.locals
Add user id of logged in user to res.locals
JavaScript
mit
Maighdlyn/phase-4-challenge,Maighdlyn/phase-4-challenge,Maighdlyn/phase-4-challenge
b23cdded1bd8067bbd6312dc38379bf7f22b5769
src/scripts/main.js
src/scripts/main.js
/*global jQuery:false*/ (function($) { function equalize() { var elements = $('.left, .right'); var max_height = Math.max.apply( null, elements.map(function(index, elt) { return $(elt).height(); }) ); elements.each(function(index, e...
/*global jQuery:false*/ (function($) { function equalize() { var elements = $('.left, .right'); var max_height = Math.max.apply( null, elements.map(function(index, elt) { return $(elt).height(); }) ); elements.each(function(index, e...
Disable column equalization before print.
Disable column equalization before print.
JavaScript
mit
NealRame/CV,NealRame/Blog,NealRame/Blog,NealRame/Blog,NealRame/CV
0e00766548766aa280a0a5410c4019745e20c46e
lib/transport/browser/websocket.js
lib/transport/browser/websocket.js
'use strict'; var Driver = global.WebSocket || global.MozWebSocket; if (Driver) { module.exports = function WebSocketBrowserDriver(url) { return new Driver(url); }; }
'use strict'; var Driver = global.WebSocket || global.MozWebSocket; if (Driver) { module.exports = function WebSocketBrowserDriver(url) { return new Driver(url); }; } else { module.exports = undefined; }
FIX error with webpack when WebSocket not exists
FIX error with webpack when WebSocket not exists When building with webpack and you didn't define module.exports it will default to an empty object {} So when transport.enabled test !!WebSocketDriver it returns true instead of false.
JavaScript
mit
sockjs/sockjs-client,sockjs/sockjs-client,sockjs/sockjs-client
8db5f375995f8b9f77679badab0e03beba9062c7
config/webpack/development.js
config/webpack/development.js
// Note: You must restart bin/webpack-watcher for changes to take effect const merge = require('webpack-merge') const common = require('./common.js') const { resolve } = require('path') const { devServer, publicPath, paths } = require('./configuration.js') module.exports = merge(common, { devtool: 'sourcemap', ...
// Note: You must restart bin/webpack-watcher for changes to take effect const merge = require('webpack-merge') const common = require('./common.js') const { resolve } = require('path') const { devServer, publicPath, paths } = require('./configuration.js') module.exports = merge(common, { devtool: 'sourcemap', ...
Use webpack dev server as proxy to rails
Use webpack dev server as proxy to rails
JavaScript
agpl-3.0
jgraichen/mnemosyne-server,jgraichen/mnemosyne-server,jgraichen/mnemosyne-server
94f16a05a78b2bf71c01f47e2bb575cc68db709a
config/webpack/loaders/vue.js
config/webpack/loaders/vue.js
const { dev_server: devServer } = require('@rails/webpacker').config; const isProduction = process.env.NODE_ENV === 'production'; const inDevServer = process.argv.find(v => v.includes('webpack-dev-server')); const extractCSS = !(inDevServer && (devServer && devServer.hmr)) || isProduction; module.exports = { test: ...
const { dev_server: devServer } = require('@rails/webpacker').config; const isProduction = process.env.NODE_ENV === 'production'; const inDevServer = process.argv.find(v => v.includes('webpack-dev-server')); const extractCSS = !(inDevServer && (devServer && devServer.hmr)) || isProduction; module.exports = { test: ...
Use new Vue whitespace optimization
Use new Vue whitespace optimization
JavaScript
agpl-3.0
harvard-lil/h2o,harvard-lil/h2o,harvard-lil/h2o,harvard-lil/h2o
575d973524bd2d953a9615c66dcf8e409e40bab9
console/server/node-server.js
console/server/node-server.js
const MONGOOSE_CONSOLE_DEFAULT_PORT = 8080; const PROMETHEUS_CONFIGURATION_PATH = '/configuration/prometheus.yml'; var express = require('express'); var bodyParser = require('body-parser'); var fs = require('fs'); var app = express(); var path = __dirname + ''; var port = process.env.CONSOLE_PORT || MONGOOSE_CONSOLE...
const MONGOOSE_CONSOLE_DEFAULT_PORT = 8080; const PROMETHEUS_CONFIGURATION_PATH = '/configuration/prometheus.yml'; var express = require('express'); var bodyParser = require('body-parser'); var fs = require('fs'); var cors = require('cors') var app = express(); var path = __dirname + ''; var port = process.env.CONSO...
Add CORS to node server.
Add CORS to node server.
JavaScript
mit
emc-mongoose/console,emc-mongoose/console,emc-mongoose/console
b30815c324d90e99bb3fca25eb6d00b5cdfef4e8
markup/components/header/header.js
markup/components/header/header.js
/* eslint-disable */ $('.nav-toggle').click(function (e) { $('.nav-menu').slideToggle(500); }); debounce(function(){ $(window).resize(function(){ if($(window).width() > 720){ $('.nav-menu').removeAttr('style'); } }); }, 200); /* eslint-enable */
/* eslint-disable */ $('.nav-toggle').click(function (e) { $('.nav-menu').slideToggle(500); }); $(window).resize(function(){ if($(window).width() > 720){ $('.nav-menu').removeAttr('style'); } }); /* eslint-enable */
FIX - поправлен JS для адаптива меню
FIX - поправлен JS для адаптива меню
JavaScript
mit
agolomazov/bouncy,agolomazov/bouncy
415b7d0250887764ee9836ee823be07d45708173
api/models/Y.js
api/models/Y.js
var keystone = require('keystone'); var Types = keystone.Field.Types; /** * Y Model * ========== */ var Y = new keystone.List('Y'); Y.add({ name: { type: Types.Name, required: true, index: true }, email: { type: Types.Email, initial: true, required: true, index: true }, password: { type: Types.Password, i...
var keystone = require('keystone'); var Types = keystone.Field.Types; /** * Y Model * ========== */ var Y = new keystone.List('Y'); Y.add({ name: { type: Types.Name, required: true, index: true }, email: { type: Types.Email, initial: true, required: true, index: true }, password: { type: Types.Password, ini...
Remove password as hidden field
Remove password as hidden field
JavaScript
mit
chrisslater/snapperfish
941c1565dbc89005b99b9302370028cbd5c820c1
components/LandingPageHero.js
components/LandingPageHero.js
import React from 'react'; import Helmet from 'react-helmet'; import Hero from './Hero'; const LandingPageHero = ({ title, headline }, { modals }) => { return ( <div> <Helmet title={title} /> <Hero headline={headline} textline={`Increase your productivity, focus on new features, and s...
import React from 'react'; import Helmet from 'react-helmet'; import Hero from './Hero'; const LandingPageHero = ({ title, headline }, { modals }) => { return ( <div> <Helmet title={title} /> <Hero headline={headline} textline={`Increase your productivity, focus on new features, and s...
Fix typo in "powerful apps"
[WEB-465] Fix typo in "powerful apps"
JavaScript
mit
Syncano/syncano.com,Syncano/syncano.com
3fe151d044e6a6f4ea957e3a75105a45a2865314
build/karma.base.js
build/karma.base.js
const buble = require('rollup-plugin-buble'); const nodeResolve = require('rollup-plugin-node-resolve'); const commonJS = require('rollup-plugin-commonjs'); module.exports = { frameworks: ['jasmine', 'sinon'], files: [ { pattern: '../src/**/*.js', watched: process.env.CI === 'true', include...
const buble = require('rollup-plugin-buble'); const nodeResolve = require('rollup-plugin-node-resolve'); const commonJS = require('rollup-plugin-commonjs'); module.exports = { frameworks: ['jasmine', 'sinon'], files: [ { pattern: '../src/**/*.js', watched: process.env.CI !== 'true', include...
Fix karma config. Watch files when not CI environment.
Fix karma config. Watch files when not CI environment.
JavaScript
mit
demiazz/lighty
7652f2b6ac6e0602d5d3746e9c42173cf3730622
templates/add-service/web-express-es6/app/index.js
templates/add-service/web-express-es6/app/index.js
// This is the main server file. // // It parses the command line and instantiates the two servers for this app: const async = require('async') const {cyan, dim, green, red} = require('chalk') const ExoRelay = require('exorelay'); const N = require('nitroglycerin'); const {name, version} = require('../package.json') co...
// This is the main server file. // // It parses the command line and instantiates the two servers for this app: const async = require('async') const {cyan, dim, green, red} = require('chalk') const ExoRelay = require('exorelay'); const N = require('nitroglycerin'); const {name, version} = require('../package.json') co...
Make the web port configurable
Make the web port configurable
JavaScript
mit
Originate/exosphere,Originate/exosphere,Originate/exosphere,Originate/exosphere
476b864d53a63fd211b2faa6c40f9be4b1454526
ui/src/shared/middleware/errors.js
ui/src/shared/middleware/errors.js
// import {replace} from 'react-router-redux' import {authReceived, meReceived} from 'shared/actions/auth' import {publishNotification as notify} from 'shared/actions/notifications' import {HTTP_FORBIDDEN} from 'shared/constants' const errorsMiddleware = store => next => action => { if (action.type === 'ERROR_THRO...
// import {replace} from 'react-router-redux' import {authExpired} from 'shared/actions/auth' import {publishNotification as notify} from 'shared/actions/notifications' import {HTTP_FORBIDDEN} from 'shared/constants' const errorsMiddleware = store => next => action => { if (action.type === 'ERROR_THROWN') { co...
Use authExpired action; fix session timeout notification logic
Use authExpired action; fix session timeout notification logic
JavaScript
agpl-3.0
brianbaker/chronograf,brianbaker/chronograf,brianbaker/chronograf,brianbaker/chronograf,brianbaker/chronograf
b5b6d9b04bec0c9e937441a60dcac34f30e0a041
dataprep-webapp/src/app/components/preparation/creator/datasets-filters/datasets-filters-controller.js
dataprep-webapp/src/app/components/preparation/creator/datasets-filters/datasets-filters-controller.js
/* ============================================================================ Copyright (C) 2006-2016 Talend Inc. - www.talend.com This source code is available under agreement available at https://github.com/Talend/data-prep/blob/master/LICENSE You should have received a copy of the agreement along with thi...
/* ============================================================================ Copyright (C) 2006-2016 Talend Inc. - www.talend.com This source code is available under agreement available at https://github.com/Talend/data-prep/blob/master/LICENSE You should have received a copy of the agreement along with thi...
Fix unit test following merge of maintenance/1.2.0 changes.
[Test] Fix unit test following merge of maintenance/1.2.0 changes.
JavaScript
apache-2.0
Talend/data-prep,Talend/data-prep,Talend/data-prep
0b5f74f9d0a3ab08b742a537e1e900765f8f52d8
packages/resourceful-redux/src/utils/get-resources.js
packages/resourceful-redux/src/utils/get-resources.js
// Returns a list of resources by IDs or label export default function(state, resourceName, idsOrLabel) { const resourceSlice = state[resourceName]; if (!resourceSlice) { return []; } const resources = resourceSlice.resources; let idsList; // This conditional handles the situation where `idsOrLabel` i...
// Returns a list of resources by IDs or list name export default function(state, resourceName, idsOrList) { const resourceSlice = state[resourceName]; if (!resourceSlice) { return []; } const resources = resourceSlice.resources; let idsList; // This conditional handles the situation where `idsOrList`...
Update getResources to support lists, not labels
Update getResources to support lists, not labels
JavaScript
mit
jmeas/resourceful-redux,jmeas/resourceful-redux
77749a3cc52eb8ebabbdb0f13a58338fd543b6bd
src/environment-settings-template.js
src/environment-settings-template.js
// Here you can add settings which change per environment. This file will be also used by the buildserver to inject environment specific values. // Settings are made available through the configService. var environmentSettings = { host: 'localhost', port: 8001 } // Leave line below untouched. This how gulp file is a...
// Here you can add settings which change per environment. This file will be also used by the buildserver to inject environment specific values. // Settings are made available through the configService. var environmentSettings = { host: 'localhost', port: 8001 } // Leave lines below untouched. This how gulp file is ...
Fix for module error in console.
Fix for module error in console.
JavaScript
mit
robinvanderknaap/SkaeleFrontend,robinvanderknaap/SkaeleFrontend
a5bc2b05f6a2d948d596cb562796be98cfbd1d49
packages/ember-model/lib/adapter.js
packages/ember-model/lib/adapter.js
Ember.Adapter = Ember.Object.extend({ find: function(record, id) { throw new Error('Ember.Adapter subclasses must implement find'); }, findQuery: function(record, id) { throw new Error('Ember.Adapter subclasses must implement findQuery'); }, findMany: function(record, id) { throw new Error('Embe...
Ember.Adapter = Ember.Object.extend({ find: function(record, id) { throw new Error('Ember.Adapter subclasses must implement find'); }, findQuery: function(klass, records, params) { throw new Error('Ember.Adapter subclasses must implement findQuery'); }, findMany: function(klass, records, ids) { ...
Update Adapter to match API
Update Adapter to match API
JavaScript
mit
greyhwndz/ember-model,juggy/ember-model,gmedina/ember-model,sohara/ember-model,ipavelpetrov/ember-model,asquet/ember-model,ebryn/ember-model,GavinJoyce/ember-model,zenefits/ember-model,c0achmcguirk/ember-model,asquet/ember-model,ipavelpetrov/ember-model,CondeNast/ember-model,Swrve/ember-model,ckung/ember-model,julkiewi...
0ede5818a3dd1d087ef4a01511d83a76390a35e3
app/scripts/directives/help-icon.js
app/scripts/directives/help-icon.js
'use strict'; (function() { angular.module('ncsaas') .directive('helpicon', ['$document', helpicon]); function helpicon($document) { return { restrict: 'E', templateUrl: "views/directives/help-icon.html", replace: true, scope: { helpText: '@' }, link: function (...
'use strict'; (function() { angular.module('ncsaas') .directive('helpicon', ['$document', helpicon]); function helpicon($document) { return { restrict: 'E', templateUrl: "views/directives/help-icon.html", replace: true, scope: { helpText: '@' }, link: function (...
Hide help text if click outside element.
Hide help text if click outside element. – SAAS-457
JavaScript
mit
opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport
266e31e911e1337589aa5134efd194de6b124551
src/scripts/content/toggl.js
src/scripts/content/toggl.js
'use strict'; var userData, offlineUser; offlineUser = localStorage.getItem('offline_users'); if (offlineUser) { userData = JSON.parse(localStorage.getItem('offline_users-' + offlineUser)); if (userData && userData.offlineData) { chrome.extension.sendMessage({ type: 'userToken', apiToken: userData...
'use strict'; var userData, offlineUser; offlineUser = localStorage.getItem('offline_users'); if (offlineUser) { userData = JSON.parse(localStorage.getItem('offline_users-' + offlineUser)); if (userData && userData.offlineData) { chrome.extension.sendMessage({ type: 'userToken', apiToken: userData...
Fix process undefined in content script
Fix process undefined in content script Fixes #1113.
JavaScript
bsd-3-clause
glensc/toggl-button,glensc/toggl-button,glensc/toggl-button
94a9e274fa01e834bd88e9b03dcba8a1c643120d
build/tasks/durandal.js
build/tasks/durandal.js
var gulp = require('gulp'); //var gutil = require('gulp-util'); var fs = require('fs'); var durandal = require('gulp-durandal'); var header = require('gulp-header'); var paths = require('../paths'); gulp.task('durandal', function() { var pkg = JSON.parse(fs.readFileSync('./package.json', 'utf-8')); var banner = ['/...
var gulp = require('gulp'); var fs = require('fs'); var durandal = require('gulp-durandal'); var header = require('gulp-header'); var paths = require('../paths'); gulp.task('durandal', function() { var pkg = JSON.parse(fs.readFileSync('./package.json', 'utf-8')); var banner = ['/**', ' * Copyright (c) <%= new Dat...
Add banner to built version
Add banner to built version
JavaScript
mit
mryellow/durandal-gulp-boilerplate,mryellow/durandal-gulp-boilerplate
ebd672e35424298de480a1e19c7ac57bd0b78e67
app/utils/socketIO.js
app/utils/socketIO.js
'use strict'; /* * Socket.io related things go ! */ import { log, LOG_TYPES } from './log'; import { decodeJWT } from './JWT'; const EVENT_TYPES = { DISCONNECT : 'disconnect', CONNECTION : 'connection', TOKEN_VALID : 'token_valid', TOKEN_INVALID : 'token_invalid', CONTACT_O...
'use strict'; /* * Socket.io related things go ! */ import { log, LOG_TYPES } from './log'; import { decodeJWT } from './JWT'; import models from '../models'; const User = models.User; const EVENT_TYPES = { DISCONNECT : 'disconnect', CONNECTION : 'connection', TOKEN_VALID ...
Update last seen date when connecting through socket.io
Update last seen date when connecting through socket.io
JavaScript
mit
learning-layers/sardroid-server,learning-layers/sardroid-server
f34ad58342958656ec4b15a828349af931ea2dc3
firefox/lib/main.js
firefox/lib/main.js
var self = require("sdk/self"); var panel = require("sdk/panel"); var initToolbar = function(freedom) { // create toolbarbutton var tbb = require("pathfinder/ui/toolbarbutton").ToolbarButton({ id: "UProxyItem", label: "UProxy", image: self.data.url("common/ui/icons/uproxy-19.png"), panel: initPan...
var self = require("sdk/self"); var panel = require("sdk/panel"); var initToolbar = function(freedom) { // create toolbarbutton var tbb = require("pathfinder/ui/toolbarbutton").ToolbarButton({ id: "UProxyItem", label: "UProxy", image: self.data.url("common/ui/icons/uproxy-19.png"), panel: initPan...
Increase delay for loading toolbarbutton so that other components have a chance to load.
Increase delay for loading toolbarbutton so that other components have a chance to load.
JavaScript
apache-2.0
chinarustin/uproxy,jpevarnek/uproxy,jpevarnek/uproxy,uProxy/uproxy,itplanes/uproxy,dhkong88/uproxy,qida/uproxy,jpevarnek/uproxy,itplanes/uproxy,dhkong88/uproxy,chinarustin/uproxy,MinFu/uproxy,chinarustin/uproxy,chinarustin/uproxy,qida/uproxy,jpevarnek/uproxy,jpevarnek/uproxy,roceys/uproxy,IveWong/uproxy,itplanes/uproxy...
0717d0940e525eb17831cac42093c6a67fc658f0
src/space-case.js
src/space-case.js
import R from 'ramda'; // a -> a const spaceCase = R.compose( R.trim, R.replace(/([a-z])([A-Z])/g, '$1 $2'), R.replace(/(\.|-|_)/g, ' ') ); export default spaceCase;
import R from 'ramda'; import compose from './util/compose.js'; // a -> a const spaceCase = compose( R.trim, R.replace(/([a-z])([A-Z])/g, '$1 $2'), R.replace(/(\.|-|_)/g, ' ') ); export default spaceCase;
Refactor spaceCase function to use custom compose function
Refactor spaceCase function to use custom compose function
JavaScript
mit
restrung/restrung-js
ddd5cae6fb518d8ea6c073ecbf90a20fc4bec8dd
src/components/box/boxProps.js
src/components/box/boxProps.js
import omit from 'lodash.omit'; import pick from 'lodash.pick'; const boxProps = [ 'alignContent', 'alignItems', 'alignSelf', 'borderWidth', 'borderBottomWidth', 'borderColor', 'borderLeftWidth', 'borderRightWidth', 'borderTint', 'borderTopWidth', 'boxSizing', 'className', 'display', 'eleme...
import omit from 'lodash.omit'; import pick from 'lodash.pick'; const boxProps = [ 'alignContent', 'alignItems', 'alignSelf', 'borderWidth', 'borderBottomWidth', 'borderColor', 'borderLeftWidth', 'borderRightWidth', 'borderTint', 'borderTopWidth', 'borderRadius', 'boxSizing', 'className', '...
Add borderRadius to the box prop list
Add borderRadius to the box prop list
JavaScript
mit
teamleadercrm/teamleader-ui
35cabf1fcf225e7d7168f12a52baca7c5728aa4a
frontend/app/js/containers/project/index.js
frontend/app/js/containers/project/index.js
import ServerboardView from 'app/components/project' import store from 'app/utils/store' import { projects_update_info } from 'app/actions/project' var Project=store.connect({ state(state){ if (state.project.current != "/" && localStorage.last_project != state.project.current){ localStorage.last_project = ...
import ServerboardView from 'app/components/project' import store from 'app/utils/store' import { projects_update_info } from 'app/actions/project' var Project=store.connect({ state(state){ if (state.project.current != "/" && localStorage.last_project != state.project.current){ localStorage.last_project = ...
Fix goto simple sections at sidebar
Fix goto simple sections at sidebar
JavaScript
apache-2.0
serverboards/serverboards,serverboards/serverboards,serverboards/serverboards,serverboards/serverboards,serverboards/serverboards
1b565f867fc123d54cb54c96fdb2e188ff71227a
renderer.js
renderer.js
// This file is required by the index.html file and will // be executed in the renderer process for that window. // All of the Node.js APIs are available in this process. const {clipboard} = require('electron') alert(clipboard.readText("String")) module.exports = function demoClipboard() { var text = clipboard.read...
// This file is required by the index.html file and will // be executed in the renderer process for that window. // All of the Node.js APIs are available in this process. const {clipboard} = require('electron') module.exports = function demoClipboard() { var text = clipboard.readText("String"); alert(text); }
Remove alert for testing purpose
Remove alert for testing purpose
JavaScript
cc0-1.0
weitalu/awesome-answering-machine,weitalu/awesome-answering-machine
466017c706bf782d868c621b4d535047b3a05259
app/config-debug.js
app/config-debug.js
var juju_config = { // These are blacklisted config items not passed into subapps mounted into // the main App. serverRouting: false, html5: true, container: '#main', viewContainer: '#main', // FIXME: turn off transitions until they are fixed. transitions: false, // These are the main application con...
var juju_config = { // These are blacklisted config items not passed into subapps mounted into // the main App. serverRouting: false, html5: true, container: '#main', viewContainer: '#main', // FIXME: turn off transitions until they are fixed. transitions: false, // These are the main application con...
Revert local change to config.
Revert local change to config.
JavaScript
agpl-3.0
jrwren/juju-gui,bac/juju-gui,mitechie/juju-gui,mitechie/juju-gui,jrwren/juju-gui,bac/juju-gui,bac/juju-gui,mitechie/juju-gui,CanonicalJS/juju-gui,mitechie/juju-gui,jrwren/juju-gui,CanonicalJS/juju-gui,bac/juju-gui,jrwren/juju-gui,CanonicalJS/juju-gui
b52cc64da7f2ecf037c5b3226a4c6641fe4c4b73
eloquent_js_exercises/chapter06/chapter06_ex01.js
eloquent_js_exercises/chapter06/chapter06_ex01.js
function Vector(x, y) { this.x = x; this.y = y; } Vector.prototype.plus = function(vec) { return new Vector(this.x + vec.x, this.y + vec.y); } Vector.prototype.minus = function(vec) { return new Vector(this.x - vec.x, this.y - vec.y); } Object.defineProperty(Vector.prototype, "length", { get: fun...
class Vec { constructor(x, y) { this.x = x; this.y = y; } plus(v) { return new Vec(this.x + v.x, this.y + v.y); } minus(v) { return new Vec(this.x - v.x, this.y - v.y); } get length() { return Math.sqrt(this.x**2 + this.y**2); } toString() ...
Add Chapter 06, exercise 1
Add Chapter 06, exercise 1
JavaScript
mit
bewuethr/ctci
3073499ecb1147986f6164688a5b8e4e1700ef44
eloquent_js_exercises/chapter09/chapter09_ex03.js
eloquent_js_exercises/chapter09/chapter09_ex03.js
var number = /^(\+|-)?(\d+(\.\d*)?|\.\d+)([Ee](\+|-)?\d+)?$/;
let number = /^[+-]?\d*(\d\.|\.\d)?\d*([eE][+-]?\d+)?$/;
Add Chapter 09, exercise 3
Add Chapter 09, exercise 3
JavaScript
mit
bewuethr/ctci
73b4e1dee95f584129f03bad8c5a7448eee31b3a
handlers/awsJobs.js
handlers/awsJobs.js
// dependencies ------------------------------------------------------------ import aws from '../libs/aws'; // handlers ---------------------------------------------------------------- /** * Jobs * * Handlers for job actions. */ let handlers = { /** * Describe Job Definitions */ describeJobDef...
// dependencies ------------------------------------------------------------ import aws from '../libs/aws'; import scitran from '../libs/scitran'; // handlers ---------------------------------------------------------------- /** * Jobs * * Handlers for job actions. */ let handlers = { /** * Create J...
Add stub for creating job definitions. Add back snapshot uploading prior to job submission
Add stub for creating job definitions. Add back snapshot uploading prior to job submission
JavaScript
mit
poldracklab/crn_server,poldracklab/crn_server
bbb6168aef0478fae75da18410a90dd12a9d3fd5
Gruntfile.js
Gruntfile.js
'use strict'; module.exports = function (grunt) { grunt.initConfig({ mochacli: { options: { ui: 'bdd', reporter: 'spec', require: [ 'espower_loader_helper.js' ] }, all: ['test/*Test.js'] }, jshint: { ...
'use strict'; module.exports = function (grunt) { grunt.initConfig({ mochacli: { options: { ui: 'bdd', reporter: 'spec', require: [ 'espower_loader_helper.js' ] }, all: ['test/*Test.js'] }, jshint: { ...
Watch and run tests on lib change too.
Watch and run tests on lib change too.
JavaScript
mit
takas-ho/tddbc-201411-js,takas-ho/tddbc-201411-js
d62e85df1a66f6cd6a8d7df237147164f5320190
Gruntfile.js
Gruntfile.js
'use strict'; module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), concat: { dist: { src: ['src/**/*.js'], dest: 'dist/<%= pkg.name %>.js' } }, uglify: { dist: { files: { 'dist/<%= pkg.name %>.min.js': ['<...
'use strict'; module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), concat: { dist: { src: ['src/**/*.js'], dest: 'dist/<%= pkg.name %>.js' } }, uglify: { dist: { files: { 'dist/<%= pkg.name %>.min.js': ['<...
Fix in publish to example folder
Fix in publish to example folder
JavaScript
bsd-3-clause
infrabel/gnap-map,infrabel/gnap-map
ff0e9e0c7aee05422b63e9cf5516eb9fbcfdd1d1
src/mmw/js/src/core/filters.js
src/mmw/js/src/core/filters.js
"use strict"; var nunjucks = require('nunjucks'); var utils = require('./utils'); var _ = require('lodash'); nunjucks.env = new nunjucks.Environment(); var basicFormatter = new Intl.NumberFormat('en'); var specificFormatter = function(sigFig) { return new Intl.NumberFormat('en',{minimumFractionDigits: sigFig});...
"use strict"; var nunjucks = require('nunjucks'); var utils = require('./utils'); var _ = require('lodash'); nunjucks.env = new nunjucks.Environment(); if (window.hasOwnProperty('Intl')) { // Intl is available, we should use the faster NumberFormat var basicFormatter = new Intl.NumberFormat('en'), mi...
Support older browsers that lack Intl
Support older browsers that lack Intl While Intl.NumberFormat is a much more performant implementation (see #1566), and is supported by all modern browsers, there are still older browsers in the wild that lack support for it. Most notably, Safari 9 and the Android built-in browser do not support it, leaving many users...
JavaScript
apache-2.0
kdeloach/model-my-watershed,WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed,kdeloach/model-my-watershed,kdeloach/model-my-watershed,WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed,kdeloach/model-my-watershed,WikiWatershed/model-my-watershed,kdeloach/model-my-watershed
6f1262a480b7d37093e1367e21a26a41ed95181e
app/assets/javascripts/switch_meter.js
app/assets/javascripts/switch_meter.js
$(document).on("turbolinks:load", function() { $(".first-date-picker").datepicker( { dateFormat: 'DD, d MM yy', altFormat: 'yy-mm-dd', altField: "#first_date", // minDate: -42, maxDate: -1, orientation: 'bottom', changeMonth: true, changeYear: true...
$(document).on("turbolinks:load", function() { $(".first-date-picker").datepicker( { dateFormat: 'DD, d MM yy', altFormat: 'yy-mm-dd', altField: $(".first-date-picker").parents("form:first").find("#first_date"), // minDate: -42, maxDate: -1, orientation: 'bottom',...
Fix issue with switching when there is dual supply
Fix issue with switching when there is dual supply
JavaScript
mit
BathHacked/energy-sparks,BathHacked/energy-sparks,BathHacked/energy-sparks,BathHacked/energy-sparks
7cc81eb68da50a7b505a8669885af646e4a45241
app/containers/HomePage/Login/index.js
app/containers/HomePage/Login/index.js
import ActionExitToApp from 'material-ui/svg-icons/action/exit-to-app'; import { defaultProps, setDisplayName, setPropTypes } from 'recompose'; import RaisedButton from 'material-ui/RaisedButton'; import React from 'react'; import R from 'ramda'; const Login = () => <RaisedButton label="login with imgur" fu...
import ActionExitToApp from 'material-ui/svg-icons/action/exit-to-app'; import { bindActionCreators } from 'redux'; import { connect } from 'react-redux'; import { defaultProps, setDisplayName, setPropTypes } from 'recompose'; import RaisedButton from 'material-ui/RaisedButton'; import React from 'react'; import R from...
Add onClick function to `Login`
Add onClick function to `Login` Use a suffix for `getImgurToken` to solve the no-shadow linting conflict. Although the prop types for `getImgurToken` are defined through a recompose function, the linter indicates a false error.
JavaScript
mit
romy/personal-imgur-gallery,romy/personal-imgur-gallery
94ed33ff52d90b3b153f5fd09069e09b29d530d1
xmlToJson/index.js
xmlToJson/index.js
var fs = rquire('fs'); module.exports = function (context, xmlZipBlob) { context.log('Node.js blob trigger function processed blob:', xmlZipBlob); console.log(`typeof xmlZipBlob:`, typeof xmlZipBlob); fs.writeFile('xmlZip.zip', xmlZipBlob, (err) => { if (err) { throw err; } ...
var fs = require('fs'); module.exports = function (context, xmlZipBlob) { context.log('Node.js blob trigger function processed blob:', xmlZipBlob); context.log(`typeof xmlZipBlob:`, typeof xmlZipBlob); fs.writeFile('xmlZip.zip', xmlZipBlob, (err) => { if (err) { throw err; } ...
Fix typos and use context instead of console
Fix typos and use context instead of console
JavaScript
mit
mattmazzola/sc2iq-azure-functions
d53860ae453ed40e410af32ac5d1b7baa84f5950
Gruntfile.js
Gruntfile.js
module.exports = function (grunt) { 'use strict'; grunt.initConfig({ jshint: { options: grunt.file.readJSON('.jshintrc'), gruntfile: 'Gruntfile.js', bin: { src: [ 'bin/*.js', 'bin/yo' ] }, test: { options: { globals: { ...
module.exports = function (grunt) { 'use strict'; grunt.initConfig({ jshint: { options: grunt.file.readJSON('.jshintrc'), gruntfile: 'Gruntfile.js', bin: [ 'cli.js', 'yoyo.js' ], test: { options: { globals: { describe: true, it: true, ...
Fix linting paths to match previous refactor
Fix linting paths to match previous refactor
JavaScript
bsd-2-clause
yeoman/yo
7efd2e90aa25f7ded66d2c69d78a285825d02f2d
Gruntfile.js
Gruntfile.js
module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), run: { app: { options: { wait: false }, cmd: 'node', args: ['app.js'] } }, simplemocha: { control: { src: ['specs/sandbox-control.spec.js'] }, ...
module.exports = function(grunt) { grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), run: { app: { options: { wait: false }, cmd: 'node', args: ['app.js'] } }, simplemocha: { control: { src: ['specs/sandbox-control.spec.js'] }, ...
Add grep argument to run tests with a filter
Add grep argument to run tests with a filter
JavaScript
agpl-3.0
ether-camp/ethereum-sandbox
e7e7da9fac092e06d6a234d2be0fc522da5585a5
Gruntfile.js
Gruntfile.js
module.exports = function(grunt) { var attache = { buildDir: 'dist' }; // Project configuration. grunt.initConfig({ appConfig: attache, pkg: grunt.file.readJSON('package.json'), jsdoc : { dist : { src: ['attache.js', 'attache-jquery.js'], options: { ...
module.exports = function(grunt) { var attache = { buildDir: 'dist' }; // Project configuration. grunt.initConfig({ appConfig: attache, pkg: grunt.file.readJSON('package.json'), jsdoc : { dist : { src: ['attache.js', 'attache-jquery.js'], options: { ...
Exclude private functions from documentation
Exclude private functions from documentation
JavaScript
mit
janfoeh/attachejs,janfoeh/attachejs,janfoeh/attachejs