commit stringlengths 40 40 | old_file stringlengths 4 236 | new_file stringlengths 4 236 | old_contents stringlengths 1 3.26k | new_contents stringlengths 16 4.43k | subject stringlengths 16 624 | message stringlengths 17 3.29k | lang stringclasses 5
values | license stringclasses 13
values | repos stringlengths 5 91.5k |
|---|---|---|---|---|---|---|---|---|---|
6b50213eb96d21c15336733f6d47e4c156bbc179 | lib/protocol/packets/Field.js | lib/protocol/packets/Field.js | var Types = require('../constants/types');
module.exports = Field;
function Field(options) {
options = options || {};
this.parser = options.parser;
this.db = options.packet.db;
this.table = options.packet.table;
this.name = options.packet.name;
this.type = typeToString(options.packet.type);
thi... | var Types = require('../constants/types');
module.exports = Field;
function Field(options) {
options = options || {};
this.parser = options.parser;
this.packet = options.packet;
this.db = options.packet.db;
this.table = options.packet.table;
this.name = options.packet.name;
this.type = typeToSt... | Allow access to the packet object | Allow access to the packet object
I'm trying to use some field packet information in my custom "typeCast" function, but right now the Field object don't have access to it.
"RowDataPacket.prototype._typeCast" function have access to it, and I need to check the field "charsetNr" property in my custom "typeCast" funct... | JavaScript | mit | AshWilliams/node-mysql,acorbi/node-mysql,NikosEfthias/node-mysql,teng2015/node-mysql,yulongge/node-mysql,WY08271/node-mysql,bORm/node-mysql,apathyjade/node-mysql,ashwinks/node-mysql,yourcaptain/node-mysql,danidomi/node-mysql,lukw00/node-mysql,seangarner/node-mysql,yanninho/node-mysql,wxkdesky/node-mysql,tempbottle/node... |
0a3fb4c0ac06e47df3800ace7822675c3bbf74da | bin/elementExplorerClient.js | bin/elementExplorerClient.js | var net = require('net');
var EventEmitter = require('events').EventEmitter;
var q = require('q');
/**
*
* @constructor
*/
var ElementExplorerClient = function() {
this.client_ = null;
this.eventEmitter_ = new EventEmitter();
this.connect_();
};
ElementExplorerClient.prototype.connect_ = function() {
var ... | var net = require('net');
var q = require('q');
var runCommand = function(cmd) {
var deferred = q.defer();
// Terminate with ENTER.
cmd= "browser.get('http://angular.github.io/protractor/#/');\r\n";
//cmd += '\r\n';
var client = net.connect({port: 6969}, function() {
console.log('Connected. Sending co... | Migrate from class to function | Migrate from class to function
| JavaScript | mit | andresdominguez/elementor,andresdominguez/elementor |
f4c664bd44b0920e2bbab3b9fdc9cbd2b14db351 | packages/vulcan-voting/lib/containers/withVote.js | packages/vulcan-voting/lib/containers/withVote.js | import React, { PropTypes, Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';
import { performVoteClient } from '../modules/vote.js';
import { VoteableCollections } from '../modules/make_voteable.js';
export const withVote = component => {
return graphql(gql`
mutati... | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';
import { performVoteClient } from '../modules/vote.js';
import { VoteableCollections } from '../modules/make_voteable.js';
export const withVote = component => {
retur... | Use prop-types package in vulcan-voting | Use prop-types package in vulcan-voting
| JavaScript | mit | Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope,Discordius/Lesswrong2,VulcanJS/Vulcan,Discordius/Telescope,Discordius/Lesswrong2,Discordius/Telescope,VulcanJS/Vulcan |
9c82e343c08f6117c38448d3eaeb5edcc0eed601 | generators/polymer-app/index.js | generators/polymer-app/index.js | const generators = require('yeoman-generator');
const path = require('path');
const util = require('../util.js');
const generator = generators.Base.extend({
// Cannot use arrow notation due to this object not referencing the correct object.
constructor: function () {
generators.Base.apply(this, arguments);
th... | const generators = require('yeoman-generator');
const path = require('path');
const util = require('../util.js');
const generator = generators.Base.extend({
// Cannot use arrow notation due to this object not referencing the correct object.
constructor: function () {
generators.Base.apply(this, arguments);
uti... | Refactor polymer-app-generator to use helper functions. | Refactor polymer-app-generator to use helper functions.
| JavaScript | bsd-2-clause | KK578/generator-kk578,KK578/generator-kk578 |
7ffa11096d24275563e11ab748a7864a0b650722 | lib/EnvironmentPlugin.js | lib/EnvironmentPlugin.js | /*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Simen Brekken @simenbrekken
*/
var DefinePlugin = require("./DefinePlugin");
function EnvironmentPlugin(keys) {
this.keys = Array.isArray(keys) ? keys : Array.prototype.slice.call(arguments);
}
module.exports = EnvironmentPlugin;
EnvironmentP... | /*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Simen Brekken @simenbrekken
*/
var DefinePlugin = require("./DefinePlugin");
function EnvironmentPlugin(keys, silent) {
this.keys = Array.isArray(keys) ? keys : Array.prototype.slice.call(arguments);
this.silent = silent
}
module.exports = En... | Add option to silence warnings from environment plugin | Add option to silence warnings from environment plugin
If a process.env variable is is added to the EnvironmentPlugin but not defined, it is reported in the terminal as:
`WARNING in NODE_ENV environment variable is undefined.`
This pull request adds an option as the second argument to EnvironmentPlugin to silence the... | JavaScript | mit | ts-webpack/webpack,g0ddish/webpack,ts-webpack/webpack,rlugojr/webpack,jescalan/webpack,g0ddish/webpack,NekR/webpack,SimenB/webpack,webpack/webpack,SimenB/webpack,rlugojr/webpack,jescalan/webpack,webpack/webpack,webpack/webpack,rlugojr/webpack,g0ddish/webpack,jescalan/webpack,ts-webpack/webpack,EliteScientist/webpack,El... |
caf2efc0883502cf22ce95d3ca586afe63618f21 | src/js/components/ui/ToolBar.js | src/js/components/ui/ToolBar.js | import React, { PropTypes, Component } from 'react';
import { Link } from 'react-router';
import shouldPureComponentUpdate from '../../../../node_modules/react-pure-render/function';
export default class ToolBar extends Component {
static propTypes = {
links: PropTypes.array.isRequired,
activeLinkI... | import React, { PropTypes, Component } from 'react';
import { Link } from 'react-router';
import shouldPureComponentUpdate from '../../../../node_modules/react-pure-render/function';
export default class ToolBar extends Component {
static propTypes = {
links : PropTypes.array.isRequired,
a... | Fix all items needs key | Fix all items needs key
| JavaScript | agpl-3.0 | nekuno/client,nekuno/client |
d00b257e7880d1f7c4a8c4198c73d718cf3bebd1 | src/api/define.js | src/api/define.js | import { name as $name } from '../util/symbols';
import Component from './component';
import uniqueId from '../util/unique-id';
export default function (name, opts) {
const { customElements } = window;
if (!customElements) {
throw new Error('Skate requires native custom element support or a polyfill.');
}
... | import { name as $name } from '../util/symbols';
import Component from './component';
import uniqueId from '../util/unique-id';
export default function (name, opts) {
const { customElements } = window;
if (!customElements) {
throw new Error('Skate requires native custom element support or a polyfill.');
}
... | Remove added code to go back to the simpler approach for now, at least for this PR. | refactor: Remove added code to go back to the simpler approach for now, at least for this PR.
| JavaScript | mit | skatejs/skatejs,skatejs/skatejs,chrisdarroch/skatejs,chrisdarroch/skatejs,skatejs/skatejs |
fdc8bf54eb6ec00b3cc00edc8eae22f240148779 | app/assets/javascripts/views/experiences/send_create_experience.js | app/assets/javascripts/views/experiences/send_create_experience.js | function createExperience(form){
formData = $(form).serialize();
var request = $.ajax({
method: 'post',
url: '/experiences',
data: formData
})
request.done(function(response){
var experienceID = response
addImageToExperienceForm(experienceID) // This file doesn't know which experience to add... | function createExperience(form){
formData = $(form).serialize();
var request = $.ajax({
method: 'post',
url: '/experiences',
data: formData
})
request.done(function(response){
var experienceID = response
clearMainFrame().done(function() {
addImageToExperienceForm(experienceID)
});
... | Add smooth transition between create and image upload forms | Add smooth transition between create and image upload forms
| JavaScript | mit | dma315/ambrosia,dma315/ambrosia,dma315/ambrosia |
62e7e47ff9f7d5dd8ff66f8d011b05a419f9d07b | src/js/components/ui/ToolBar.js | src/js/components/ui/ToolBar.js | import React, { PropTypes, Component } from 'react';
import connectToStores from '../../utils/connectToStores';
import shouldPureComponentUpdate from '../../../../node_modules/react-pure-render/function';
import LoginStore from '../../stores/LoginStore';
function getState() {
const isGuest = LoginStore.isGuest();
... | import React, { PropTypes, Component } from 'react';
import connectToStores from '../../utils/connectToStores';
import shouldPureComponentUpdate from '../../../../node_modules/react-pure-render/function';
import LoginStore from '../../stores/LoginStore';
function getState() {
const isGuest = LoginStore.isGuest();
... | Replace history state when clicking on toolbar links | QS-1249: Replace history state when clicking on toolbar links
| JavaScript | agpl-3.0 | nekuno/client,nekuno/client |
53455e7b7eb559fbbff8c46053f35a03a3298535 | test/unit/default-config-test.js | test/unit/default-config-test.js | var fs = require('fs');
var path = require('path');
var assert = require('power-assert');
var rules = require('../../lib/rules');
var DEFAULT_CONFIG_PATH = path.join(__dirname, '..', '..', 'lib', 'config');
describe('default configurations', function() {
describe('use valid rules', function() {
var configFiles ... | var fs = require('fs');
var path = require('path');
var assert = require('power-assert');
var rules = require('../../lib/rules');
var DEFAULT_CONFIG_PATH = path.join(__dirname, '..', '..', 'lib', 'config');
describe('default configurations', function() {
var configFiles = fs.readdirSync(DEFAULT_CONFIG_PATH);
con... | Add describe() block per config file | test/unit/default-config: Add describe() block per config file
| JavaScript | mit | rwjblue/ember-template-lint |
f359bd81b4764b394025af1322575fc3b2ea3837 | src/main/web/florence/js/functions/_checkPathParsed.js | src/main/web/florence/js/functions/_checkPathParsed.js | function checkPathParsed (uri) {
if (uri.charAt(0) !== '/') {
uri = '/' + uri;
}
var safeUrl;
var myUrl = parseURL(uri);
if (myUrl.pathname.charAt(myUrl.pathname.length-1) === '/') {
myUrl.pathname = myUrl.pathname.slice(0, -1);
safeUrl = myUrl.pathname;
}
return safeUrl;
}
| function checkPathParsed (uri) {
if (uri.charAt(0) !== '/') {
uri = '/' + uri;
}
var myUrl = parseURL(uri);
var safeUrl = myUrl.pathname;
if (safeUrl.charAt(safeUrl.length-1) === '/') {
safeUrl = safeUrl.slice(0, -1);
}
return safeUrl;
}
| Check path for safe uri | Check path for safe uri
| JavaScript | mit | ONSdigital/florence,ONSdigital/florence,ONSdigital/florence,ONSdigital/florence |
cea7c7de97ddf87a1a4d592e236a5291b6b64510 | src/coordinate.js | src/coordinate.js | import { List, is } from 'immutable';
import { isUndefined } from 'lodash';
export function nextCoordsFrom({
path,
alternate,
switchCoord,
fromCoord,
next
}, list = List()) {
if(next === 0) {
return list;
}
let p = path;
let nextCoord;
// switch the path to the alternate path if the fromCoord... | import { List, is } from 'immutable';
import { isUndefined } from 'lodash';
export function nextCoordsFrom({
path,
alternate,
switchCoord,
fromCoord,
next
}, list = List()) {
if(next === 0) {
return list;
}
let p = path;
let nextCoord;
// switch the path to the alternate path if the fromCoord... | Refactor the nextCoordsFrom function to use less if statements | Refactor the nextCoordsFrom function to use less if statements
| JavaScript | mit | kenrick/ludo.js |
ffc798525509e452eb7a58b025605be5f629f727 | src/middleware/hidden-fields.js | src/middleware/hidden-fields.js | "use strict";
var _ = require('underscore');
/**
* Hidden fields middleware.
*
* This piece of middleware handles field visibility on the models. It looks for
* documents that match the current collection and if it finds any field specs then
* it exposes them on `req.fields`.
*
* The fields spec is passed dire... | "use strict";
var _ = require('underscore');
var async = require('async');
/**
* Hidden fields middleware.
*
* This piece of middleware handles field visibility on the models. It looks for
* documents that match the current collection and if it finds any field specs then
* it exposes them on `req.fields`.
*
* ... | Handle hidden fields on individual documents | Handle hidden fields on individual documents
This handles hiding fields on individual documents as opposed to doing
it collection-wide. Currently it only works for `/:collection/:id`
routes, I foresee a potential issue with the `/:collection` urls because
there will be multiple individual documents in the response, so... | JavaScript | agpl-3.0 | Sinar/popit-api,mysociety/popit-api,Sinar/popit-api,mysociety/popit-api,ciudadanointeligente/popit-api |
b42d12c40223f19c0c26d4ec7c64f3ab6e144c6c | src/model/mixin/colorPalette.js | src/model/mixin/colorPalette.js | import {makeInner} from '../../util/model';
var inner = makeInner();
export default {
clearColorPalette: function () {
inner(this).colorIdx = 0;
inner(this).colorNameMap = {};
},
getColorFromPalette: function (name, scope) {
scope = scope || this;
var scopeFields = inner(s... | import {makeInner, normalizeToArray} from '../../util/model';
var inner = makeInner();
export default {
clearColorPalette: function () {
inner(this).colorIdx = 0;
inner(this).colorNameMap = {};
},
getColorFromPalette: function (name, scope) {
scope = scope || this;
var sco... | Support string value for color. | Support string value for color.
| JavaScript | apache-2.0 | chenfwind/echarts,ecomfe/echarts,apache/incubator-echarts,100star/echarts,ecomfe/echarts,chenfwind/echarts,100star/echarts,apache/incubator-echarts |
3d8632740e0f8b84abf5134b7876e135f50b1faf | server/devServer.js | server/devServer.js | var webpack = require('webpack')
var WebpackDevServer = require('webpack-dev-server')
var config = require('../webpack.config.dev.js')
new WebpackDevServer(webpack(config), {
contentBase: './src',
hot: true,
historyApiFallback: true,
stats: {
colors: true
},
quiet: true
}).listen(3000, 'localhost', fun... | const webpack = require('webpack')
const WebpackDevServer = require('webpack-dev-server')
const config = require('../webpack.config.dev.js')
new WebpackDevServer(webpack(config), {
contentBase: './src',
hot: true,
historyApiFallback: true,
stats: {
colors: true
},
quiet: true
}).listen(3000, 'localhost... | Use const instead of var. | Use const instead of var.
| JavaScript | mit | andreiconstantinescu/project-viper,andreiconstantinescu/project-viper |
57d728e3ea7b2d500cf1dbd5e6182abf9b2a85c0 | src/main/resources/com/sandbox/runtime/js/sandbox-execute.js | src/main/resources/com/sandbox/runtime/js/sandbox-execute.js | var wrappedRequest = {}
_.each(_currentRequest._getAccessibleProperties(), function(property){
if(typeof _currentRequest[property] == 'function'){
wrappedRequest[property] = function(){
return _currentRequest[property](Array.prototype.slice.call(arguments))
}
}else{
wrappedRe... | var wrappedRequest = {}
_.each(_currentRequest._getAccessibleProperties(), function(property){
if(typeof _currentRequest[property] == 'function'){
wrappedRequest[property] = function(){
return _currentRequest[property](Array.prototype.slice.call(arguments))
}
}else{
wrappedRe... | Add error checking for missing json schema | Add error checking for missing json schema
| JavaScript | mit | luisrpp/sandbox,luisrpp/sandbox,luisrpp/sandbox |
486454192e9e6abb9fd25e59e81891212aa8ea1c | web/public/js/directives/cd-application-card/status/index.js | web/public/js/directives/cd-application-card/status/index.js | ;(function() {
'use strict';
angular
.module('cpZenPlatform')
.component('cdApplicationCardStatus', {
bindings: {
id: '<leadId',
date: '<',
completed : '<',
},
restrict: 'E',
templateUrl: '/directives/tpl/cd-application-card/status',
controller: ['intercom... | ;(function() {
'use strict';
angular
.module('cpZenPlatform')
.component('cdApplicationCardStatus', {
bindings: {
id: '<leadId',
date: '<',
completed : '<',
},
restrict: 'E',
templateUrl: '/directives/tpl/cd-application-card/status',
});
}());
| Remove IntercomService from application card status | Remove IntercomService from application card status
| JavaScript | mit | CoderDojo/cp-zen-platform,CoderDojo/cp-zen-platform |
1ed3f6907c8daaf76a32e432433e9863675d3b5c | test/opentypeSpec.js | test/opentypeSpec.js | 'use strict';
var assert = require('assert');
var mocha = require('mocha');
var describe = mocha.describe;
var it = mocha.it;
var opentype = require('../src/opentype.js');
describe('OpenType.js', function() {
it('can load a TrueType font', function() {
var font = opentype.loadSync('./fonts/Roboto-Black.tt... | 'use strict';
var assert = require('assert');
var mocha = require('mocha');
var describe = mocha.describe;
var it = mocha.it;
var opentype = require('../src/opentype.js');
describe('OpenType.js', function() {
it('can load a TrueType font', function() {
var font = opentype.loadSync('./fonts/Roboto-Black.tt... | Correct font format terminology; PostScript (a.k.a. Type 1) is a different thing. | Correct font format terminology; PostScript (a.k.a. Type 1) is a different thing.
| JavaScript | mit | luisbrito/opentype.js,brawer/opentype.js,mcanthony/opentype.js,byte-foundry/opentype.js,moyogo/opentype.js,fpirsch/opentype.js,moyogo/opentype.js,mcanthony/opentype.js,axkibe/opentype.js,jacobmarshall/opentype.js,fpirsch/opentype.js,byte-foundry/opentype.js,googlefonts/opentype.js,Jolg42/opentype.js,Jolg42/opentype.js,... |
923e2b447c434d63f76d95cb1d730ca496785119 | src/presence/presenceReducer.js | src/presence/presenceReducer.js | /* @flow strict-local */
import type { PresenceState, Action } from '../types';
import {
LOGOUT,
LOGIN_SUCCESS,
ACCOUNT_SWITCH,
EVENT_PRESENCE,
PRESENCE_RESPONSE,
REALM_INIT,
} from '../actionConstants';
import { NULL_OBJECT } from '../nullObjects';
import { getAggregatedPresence } from '../utils/presence';... | /* @flow strict-local */
import type { PresenceState, Action } from '../types';
import {
LOGOUT,
LOGIN_SUCCESS,
ACCOUNT_SWITCH,
EVENT_PRESENCE,
PRESENCE_RESPONSE,
REALM_INIT,
} from '../actionConstants';
import { NULL_OBJECT } from '../nullObjects';
import { getAggregatedPresence } from '../utils/presence';... | Drop any presence events with invalid data. | presence: Drop any presence events with invalid data.
| JavaScript | apache-2.0 | vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile,vishwesh3/zulip-mobile |
22c668bc821c098470200b5a4db78b20f9eed81d | textField.enchant.js | textField.enchant.js | enchant.TextField = enchant.Class.create(enchant.Group, {
initialize: function(width, height) {
enchant.Group.call(this);
this.width = width;
this.height = height;
this.sprite = new enchant.Sprite(width, height);
this.surface = new enchant.Surface(width, height);
this.surface.context.fillSty... | enchant.TextField = enchant.Class.create(enchant.Node, {
initialize: function(width, height) {
enchant.Node.call(this);
// Remove 37 (left-key), 39 (right-key) and 32 (space-key)
// from 'enchant.ENV.PREVENT_DEFAULT_KEY_CODES'
this._setPreventDefaultKeyCodes();
this._width = width;
this._hei... | Add _setPreventDefaultKeyCodes() and input element | Add _setPreventDefaultKeyCodes() and input element
| JavaScript | mit | 131e55/textField.enchant.js |
6bfb61556a51ea8c35dc341786dc44d2fadf7867 | client/views/pages/partials/paragraphs_edit/paragraphs_edit.js | client/views/pages/partials/paragraphs_edit/paragraphs_edit.js | /*****************************************************************************/
/* ParagraphsEdit: Event Handlers and Helpersss .js*/
/*****************************************************************************/
Template.ParagraphsEdit.events({
/*
* Example:
* 'click .selector': function (e, tmpl) {
*
... | /*****************************************************************************/
/* ParagraphsEdit: Event Handlers and Helpersss .js*/
/*****************************************************************************/
Template.ParagraphsEdit.events({
/*
* Example:
* 'click .selector': function (e, tmpl) {
*
... | Update edited paragraph into the database | Update edited paragraph into the database
| JavaScript | mit | bojicas/letterhead,bojicas/letterhead |
5478b5bc4bb98718bb04e3fd5d99caf122e47fbc | app/client/templates/projects/discussion_buttons/discussion_buttons.js | app/client/templates/projects/discussion_buttons/discussion_buttons.js | import { Projects } from '../../../../lib/collections/projects.js';
/*****************************************************************************/
/* DiscussionButtons: Event Handlers */
/*****************************************************************************/
Template.DiscussionButtons.events({
// Open the... | import { Projects } from '../../../../lib/collections/projects.js';
import { Discussions } from '../../../../lib/collections/discussions.js';
/*****************************************************************************/
/* DiscussionButtons: Event Handlers */
/********************************************************... | Fix discussion in modal from tabular | Fix discussion in modal from tabular
| JavaScript | agpl-3.0 | openp2pdesign/OpenMetaDesign,openp2pdesign/OpenMetaDesign,openp2pdesign/OpenMetaDesign |
259bc9840b061fa466b203035b2941efd5a8907f | app/javascript/flavours/glitch/features/ui/components/column_header.js | app/javascript/flavours/glitch/features/ui/components/column_header.js | import React from 'react';
import PropTypes from 'prop-types';
export default class ColumnHeader extends React.PureComponent {
static propTypes = {
icon: PropTypes.string,
type: PropTypes.string,
active: PropTypes.bool,
onClick: PropTypes.func,
columnHeaderId: PropTypes.string,
};
handleCli... | import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
export default class ColumnHeader extends React.PureComponent {
static propTypes = {
icon: PropTypes.string,
type: PropTypes.string,
active: PropTypes.bool,
onClick: PropTypes.func,
columnHeaderId... | Fix style of legacy column headers | [Glitch] Fix style of legacy column headers
Backports daefbd66a653b11a17be73b7b0a4ca200b466cec
| JavaScript | agpl-3.0 | im-in-space/mastodon,im-in-space/mastodon,glitch-soc/mastodon,Kirishima21/mastodon,glitch-soc/mastodon,glitch-soc/mastodon,Kirishima21/mastodon,Kirishima21/mastodon,im-in-space/mastodon,Kirishima21/mastodon,glitch-soc/mastodon,im-in-space/mastodon |
452e1c5c72e4d3e9cb285ee6669619ee782a5e9f | gulpfile.babel.js | gulpfile.babel.js | import gulp from 'gulp';
import babel from 'gulp-babel';
import nodemon from 'gulp-nodemon';
import mocha from 'gulp-mocha';
import istanbul from 'gulp-babel-istanbul';
import injectModules from 'gulp-inject-modules';
gulp.task('start', () => {
nodemon({
script: 'index.js',
env: { NODE_ENV: 'development' }
... | import gulp from 'gulp';
import babel from 'gulp-babel';
import nodemon from 'gulp-nodemon';
import mocha from 'gulp-mocha';
import istanbul from 'gulp-babel-istanbul';
import injectModules from 'gulp-inject-modules';
gulp.task('start', () => {
nodemon({
script: 'index.js',
env: { NODE_ENV: 'development' }
... | Refactor code using ES6 syntax | Refactor code using ES6 syntax
| JavaScript | mit | 3m3kalionel/PostIt,3m3kalionel/PostIt |
89d810fc3f654e56f8ca31f67800b051d921973a | installer/frontend/ui-tests/pages/awsCredentialsPage.js | installer/frontend/ui-tests/pages/awsCredentialsPage.js | const awsCredentialsPageCommands = {
enterAwsCredentials(region) {
const regionOption = `select#awsRegion option[value=${region}]`;
return this
.setValue('@awsAccessKey', process.env.AWS_ACCESS_KEY_ID)
.setValue('@secretAccesskey', process.env.AWS_SECRET_ACCESS_KEY)
.waitForElementPresent(re... | const awsCredentialsPageCommands = {
enterAwsCredentials(region) {
const regionOption = `select#awsRegion option[value=${region}]`;
this
.setField('@awsAccessKey', process.env.AWS_ACCESS_KEY_ID)
.setField('@secretAccesskey', process.env.AWS_SECRET_ACCESS_KEY)
.waitForElementPresent(regionOpt... | Clean up AWS Credentials page tests and add assertions | frontend/tests: Clean up AWS Credentials page tests and add assertions
| JavaScript | apache-2.0 | zbwright/tectonic-installer,kyoto/tectonic-installer,kyoto/tectonic-installer,hhoover/tectonic-installer,kalmog/tectonic-installer,hhoover/tectonic-installer,yifan-gu/tectonic-installer,colemickens/tectonic-installer,enxebre/tectonic-installer,cpanato/tectonic-installer,rithujohn191/tectonic-installer,justaugustus/tect... |
babfc82613508e619e5debf044e68eaeae03ba11 | lib/node_modules/@stdlib/math/base/dist/degenerate/logcdf/lib/logcdf.js | lib/node_modules/@stdlib/math/base/dist/degenerate/logcdf/lib/logcdf.js | 'use strict';
// MODULES //
var isnan = require( '@stdlib/math/base/utils/is-nan' );
var NINF = require( '@stdlib/math/constants/float64-ninf' );
// MAIN //
/**
* Evaluates the logarithm of the cumulative distribution function (CDF) for a degenerate distribution with a point mass at `mu`.
*
* @param {number} x - i... | 'use strict';
// MODULES //
var isnan = require( '@stdlib/math/base/utils/is-nan' );
var NINF = require( '@stdlib/math/constants/float64-ninf' );
// MAIN //
/**
* Evaluates the natural logarithm of the cumulative distribution function (logCDF) for a degenerate distribution with mean `mu`.
*
* @param {number} x - i... | Fix return type and add decimal points | Fix return type and add decimal points
| 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 |
a1fe3918544b1ebf0dc28ea9c518932b53f17744 | webpack/envs/productionConfig.js | webpack/envs/productionConfig.js | // @ts-check
const path = require("path")
const WebpackManifestPlugin = require("webpack-manifest-plugin")
const { HashedModuleIdsPlugin } = require("webpack")
const { getCSSManifest } = require("../utils/getCSSManifest")
const {
BUILD_SERVER,
NODE_ENV,
isProduction,
} = require("../../src/lib/environment")
co... | // @ts-check
const path = require("path")
const WebpackManifestPlugin = require("webpack-manifest-plugin")
const { HashedModuleIdsPlugin } = require("webpack")
const { getCSSManifest } = require("../utils/getCSSManifest")
const TerserPlugin = require("terser-webpack-plugin")
const {
BUILD_SERVER,
NODE_ENV,
isPr... | Disable parallelism, caching for terser | Disable parallelism, caching for terser
| JavaScript | mit | artsy/force-public,joeyAghion/force,oxaudo/force,cavvia/force-1,anandaroop/force,eessex/force,izakp/force,erikdstock/force,cavvia/force-1,joeyAghion/force,damassi/force,yuki24/force,eessex/force,oxaudo/force,artsy/force-public,yuki24/force,joeyAghion/force,izakp/force,yuki24/force,izakp/force,cavvia/force-1,anandaroop/... |
473d6d6e29d56f8ac54832240479558b2114ea1b | src/corrections/mainPracticeCorrection/components/dataFetcher.js | src/corrections/mainPracticeCorrection/components/dataFetcher.js | import * as React from 'react';
import PropTypes from 'prop-types';
const DataFetcher = ({children, getData, parameters}) => {
const [isLoading, setIsLoading] = React.useState(true);
const [data, setData] = React.useState(null);
const fetchData = parameters => {
if (parameters === null) return;
... | import * as React from 'react';
import PropTypes from 'prop-types';
const DataFetcher = ({children, getData, parameters}) => {
const [state, dispatch] = React.useReducer(
(state, action) => {
switch (action.type) {
case 'FETCH_DATA':
return {
... | Replace useState by useReducer in DataFetcher | Replace useState by useReducer in DataFetcher
| JavaScript | mit | AugustinLF/react-training,AugustinLF/react-training |
5e51a59c3150f5570d5c043f6403d31d9ea896cb | test/specs/parsing/functions/builtinFunctions.context.tests.js | test/specs/parsing/functions/builtinFunctions.context.tests.js | import * as slimdom from 'slimdom';
import {
evaluateXPathToBoolean,
evaluateXPathToString
} from 'fontoxpath';
let documentNode;
beforeEach(() => {
documentNode = new slimdom.Document();
});
describe('Context related functions', () => {
describe('fn:current-dateTime', () => {
it('returns the current dateTime'... | import * as slimdom from 'slimdom';
import {
evaluateXPathToBoolean,
evaluateXPathToString
} from 'fontoxpath';
let documentNode;
beforeEach(() => {
documentNode = new slimdom.Document();
});
describe('Context related functions', () => {
describe('fn:current-dateTime', () => {
it('returns the current dateTime'... | Fix test for dateTime inequality over time | Fix test for dateTime inequality over time
| JavaScript | mit | FontoXML/fontoxpath,FontoXML/fontoxpath,FontoXML/fontoxpath |
4adf60474fc8a5045b5ed8582a71cdcc22fd59ac | sencha-workspace/SlateAdmin/app/model/person/progress/NoteRecipient.js | sencha-workspace/SlateAdmin/app/model/person/progress/NoteRecipient.js | Ext.define('SlateAdmin.model.person.progress.NoteRecipient', {
extend: 'Ext.data.Model',
groupField: 'RelationshipGroup',
fields: [
{
name: 'PersonID',
type: 'integer'
},
{
name: 'FullName',
type: 'string'
},
{
... | Ext.define('SlateAdmin.model.person.progress.NoteRecipient', {
extend: 'Ext.data.Model',
groupField: 'RelationshipGroup',
fields: [
{
name: 'PersonID',
type: 'integer'
},
{
name: 'FullName',
type: 'string'
},
{
... | Use "Custom" as default recipient label | Use "Custom" as default recipient label
| JavaScript | mit | SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate-admin,SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate,SlateFoundation/slate,SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate-admin |
fa65fb5786ba129bdea3d3c8da4f9f972bc39660 | extension/keysocket-overcast.js | extension/keysocket-overcast.js | // not tested (account is needed)
keySocket.init(
"overcast.fm",
{
"play-pause": function () {
if (!player.paused) {
player.pause();
} else {
player.play();
}
}
// prev is skipped
// next is skipped
// s... | keySocket.init("overcast.fm", function (key) {
if (key === keySocket.NEXT) {
var seekForwardButton = document.getElementById("seekforwardbutton");
keySocket.simulateClick(seekForwardButton);
} else if (key === keySocket.PLAY) {
var playPauseButton = document.getElementById("playpausebutt... | Add proper, tested support for Overcast.fm. | Add proper, tested support for Overcast.fm.
| JavaScript | apache-2.0 | borismus/keysocket,borismus/keysocket |
a832e6da99435e417c850ad40e7ddf4fadc93d04 | app/imports/ui/components/queue-actions/queue-status-dropdown/queue-status-dropdown.js | app/imports/ui/components/queue-actions/queue-status-dropdown/queue-status-dropdown.js | import { Template } from 'meteor/templating';
import { openQueue, cutoffQueue, endQueue } from '/imports/api/queues/methods.js';
import './queue-status-dropdown.html';
Template.QueueStatusDropdown.events({
'click .js-open-queue'(event) {
event.preventDefault();
openQueue.call({
queueId: this.queue._... | import { Template } from 'meteor/templating';
import { openQueue, cutoffQueue, endQueue } from '/imports/api/queues/methods.js';
import './queue-status-dropdown.html';
Template.QueueStatusDropdown.events({
'click .js-open-queue'(event) {
event.preventDefault();
openQueue.call({
queueId: this.queue._... | Add confirm before ending queue | Add confirm before ending queue
| JavaScript | mit | gregcarlin/signmeup,athyuttamre/signmeup,athyuttamre/signmeup,etremel/signmeup,gregcarlin/signmeup,gregcarlin/signmeup,etremel/signmeup,signmeup/signmeup,etremel/signmeup,signmeup/signmeup |
6ba0e4a593b214f3cfdecdd5923e0e33f0b174f0 | server/src/pages/homepage/controller.js | server/src/pages/homepage/controller.js | /* globals Mozilla */
const page = require("./page").page;
let model;
exports.launch = function(m) {
model = m;
render();
};
function render() {
page.render(model);
}
document.addEventListener("addon-present", () => {
if (location.hash === "#hello") {
document.dispatchEvent(new CustomEvent("request-onbo... | /* globals Mozilla */
const page = require("./page").page;
let model;
exports.launch = function(m) {
model = m;
render();
};
function render() {
page.render(model);
}
document.addEventListener("addon-present", () => {
if (location.hash === "#hello") {
document.dispatchEvent(new CustomEvent("request-onbo... | Fix bug when UITour-lib.js loads after homepage-bundle.js | Fix bug when UITour-lib.js loads after homepage-bundle.js
The UITour-lib.js library is loaded async, and the homepage-bundle can potentially load and run before it (we saw this in Sentry). This puts in a 1 second retry when that happens.
| JavaScript | mpl-2.0 | mozilla-services/pageshot,mozilla-services/screenshots,mozilla-services/pageshot,mozilla-services/pageshot,mozilla-services/screenshots,mozilla-services/screenshots,mozilla-services/pageshot,mozilla-services/screenshots |
4e6eb92247ce2121f6345c4f4f93d541ccdf4723 | examples/api-usage/src/index.js | examples/api-usage/src/index.js | import React from 'react'
import ReactDOM from 'react-dom'
import ReactSVG from 'react-svg'
ReactDOM.render(
<ReactSVG
// Required props.
src="svg.svg"
// Optional props.
evalScripts="always"
onInjected={(error, svg) => {
if (error) {
console.error(error)
return
}
... | import React from 'react'
import ReactDOM from 'react-dom'
import ReactSVG from 'react-svg'
ReactDOM.render(
<ReactSVG
// Required props.
src="svg.svg"
// Optional props.
evalScripts="always"
fallback={<span>Error!</span>}
onInjected={(error, svg) => {
if (error) {
console.error... | Add fallback to api-usage example | Add fallback to api-usage example
| JavaScript | mit | atomic-app/react-svg |
3dafb8912787e891e80f05e0f224d01a904f364e | lib/assets/javascripts/neo/rails/scenarios/render_scenarios_list.js | lib/assets/javascripts/neo/rails/scenarios/render_scenarios_list.js | (function($){
var SEL = {
list : "neo-rails-scenarios-list",
open : "neo-rails-scenarios-list-open"
};
var url_param = function(name){
var results = new RegExp('[\\?&]' + name + '=([^&#]*)').exec(window.location.href);
return results[1] || null;
};
$(function(){
$("."+SEL.list).each(func... | (function($){
var SEL = {
list : "neo-rails-scenarios-list",
open : "neo-rails-scenarios-list-open"
};
var url_param = function(name){
var results = new RegExp('[\\?&]' + name + '=([^&#]*)').exec(window.location.href);
return results !== null && results[1];
};
$(function(){
$("."+SEL.lis... | Fix scenario rendering when no param matched. | Fix scenario rendering when no param matched.
| JavaScript | mit | neopoly/neo-rails,neopoly/neo-rails |
62fb49bf724f7b23403c075109c263f2c8249f24 | app/scripts/services/ConfCache.js | app/scripts/services/ConfCache.js | 'use strict';
angular.module('confRegistrationWebApp')
.service('ConfCache', function ConfCache($cacheFactory, $rootScope, $http, $q) {
var cache = $cacheFactory('conf');
var path = function (id) {
return 'conferences/' + (id || '');
};
var checkCache = function (path, callback) {
var c... | 'use strict';
angular.module('confRegistrationWebApp')
.service('ConfCache', function ConfCache($cacheFactory, $rootScope, $http, $q) {
var cache = $cacheFactory('conf');
var path = function (id) {
return 'conferences/' + (id || '');
};
var checkCache = function (path, callback) {
var c... | Create should return conference instead of $http response | Create should return conference instead of $http response
| JavaScript | mit | CruGlobal/conf-registration-web,CruGlobal/conf-registration-web,CruGlobal/conf-registration-web,CruGlobal/conf-registration-web |
0dbe3f9ada601f3ea6e1f521107aca9c2a5fffd8 | test/selenium-test/node_modules/driverFactory/driverFactory.js | test/selenium-test/node_modules/driverFactory/driverFactory.js | var webdriver = require('selenium-webdriver');
function loadAssets (driver) {
var s = '';
s += 'var s = document.createElement("script");';
s += 's.type = "text/javascript";'
s += 's.src = "http://localhost:7000/core.js";';
s += 'var domel = document.getElementsByTagName("script")[0];';
s += 'domel.parentN... | var webdriver = require('selenium-webdriver');
function loadAssets (driver) {
var s = '';
s += 'var s = document.createElement("script");';
s += 's.type = "text/javascript";'
s += 's.src = "http://localhost:7000/core.js";';
s += 'var domel = document.getElementsByTagName("head")[0];';
s += 'if (domel) dome... | Append scripts to the load page | Append scripts to the load page
| JavaScript | mit | legendvijay/quail,legendvijay/quail,quailjs/quail,quailjs/quail,quailjs/quail |
2d9796e0aa618dc2eb68a761d35ce905d1eef9f4 | packages/style/src/transform.js | packages/style/src/transform.js | /* @flow */
export default function() {
return {
visitor: {
ClassExpression(path: Object, state: Object) {
if (!path.node.decorators || !path.node.decorators.length) {
return
}
// Default to @style
const decoratorName = state.opts.decoratorName || 'style'
c... | /* @flow */
export default function({ types: t }: { types: Object }) {
const classBodyVisitor = {
JSXOpeningElement(path: Object, state: Object) {
const styleKey = state.get('motion$style')
path.node.attributes.push(t.jSXAttribute(
t.jSXIdentifier('motion$style'),
t.jSXExpressionConta... | Add a unique property that's same on class and jsx elements | :new: Add a unique property that's same on class and jsx elements
| JavaScript | mpl-2.0 | motion/motion,flintjs/flint,motion/motion,flintjs/flint,flintjs/flint |
5f5c66e3f2132a63347397a7ff2f6a2360f8f7c1 | afterSignHook.js | afterSignHook.js | 'use strict'
const { notarize } = require('electron-notarize')
async function main(context) {
const { electronPlatformName, appOutDir } = context
if (electronPlatformName !== 'darwin') {
return
}
const appName = context.packager.appInfo.productFilename
const appleId = 'accounts+apple@balena.io'
awai... | 'use strict'
const { notarize } = require('electron-notarize')
const { ELECTRON_SKIP_NOTARIZATION } = process.env
async function main(context) {
const { electronPlatformName, appOutDir } = context
if (electronPlatformName !== 'darwin' || ELECTRON_SKIP_NOTARIZATION === 'true') {
return
}
const appName = c... | Allow skipping notarization when building package | Allow skipping notarization when building package
Change-type: patch
Changelog-entry: Allow skipping notarization when building package (dev)
Signed-off-by: Lorenzo Alberto Maria Ambrosi <85d02d3d73c7f11f17a7802a45c32c7e0695e46d@gmail.com>
| JavaScript | apache-2.0 | resin-io/herostratus,resin-io/resin-etcher,resin-io/etcher,resin-io/resin-etcher,resin-io/etcher,resin-io/herostratus,resin-io/etcher,resin-io/etcher,resin-io/etcher |
78e3eda95cfe36ed811aa35ba90424a6f7503f4f | frontend/src/app/index.route.js | frontend/src/app/index.route.js | (function() {
'use strict';
angular
.module('afterHeap')
.config(routerConfig);
/** @ngInject */
function routerConfig($stateProvider, $urlRouterProvider) {
$stateProvider
.state('city', {
abstract: true,
url: '/:cityId',
template: '<ui-view/>'
})
.state('... | (function() {
'use strict';
angular
.module('afterHeap')
.config(routerConfig);
/** @ngInject */
function routerConfig($stateProvider, $urlRouterProvider) {
$stateProvider
.state('city', {
abstract: true,
url: '/:cityId',
template: '<ui-view/>'
})
.state('... | Test that typo in sources break the CI build | Test that typo in sources break the CI build
| JavaScript | mit | Vilsepi/after,Vilsepi/after,Vilsepi/after,Vilsepi/after,Vilsepi/after |
c519672157831e09f31deb1706fea14dcb6a90a4 | src/components/referrals/referral-info.js | src/components/referrals/referral-info.js | import React, { Component } from 'react';
export default class ReferralInfo extends Component {
render() {
return (
<div className="row text-center">
<div className=
"col-xs-12 col-sm-8 col-sm-push-2 col-md-6 col-md-push-3"
>
<div className="spacer20"></div>
<h... | import React, { Component } from 'react';
export default class ReferralInfo extends Component {
render() {
return (
<div className="row text-center">
<div className=
"col-xs-12 col-sm-8 col-sm-push-2 col-md-6 col-md-push-3"
>
<div className="spacer20"></div>
<h... | Update copy and formatting for referral info | Update copy and formatting for referral info
| JavaScript | mit | Storj/metadisk-gui,dylanlott/bridge-gui,Storj/metadisk-gui,dylanlott/bridge-gui |
571528880983a800fe4b9a87dcc132d6209ae779 | src/app/components/card/card.controller.js | src/app/components/card/card.controller.js | export default class CardController {
constructor($rootScope, $scope, $log, _, playerModel, cardsApi) {
'ngInject';
this.$rootScope = $rootScope;
this.$scope = $scope;
this.$log = $log;
this._ = _;
this.cardsApi = cardsApi;
this.playerModel = playerModel.model;
this.$log.info('constructor()', this);... | export default class CardController {
constructor($rootScope, $scope, $log, _, playerModel, cardsApi) {
'ngInject';
this.$rootScope = $rootScope;
this.$scope = $scope;
this.$log = $log;
this._ = _;
this.cardsApi = cardsApi;
this.playerModel = playerModel.model;
this.$log.info('constructor()', this);... | Set card to 'disabled' if player isn't 'active' | Set card to 'disabled' if player isn't 'active'
| JavaScript | unlicense | ejwaibel/squarrels,ejwaibel/squarrels |
ff5e03f97ac3d7d0f8edc8acb5c4a18013f578a6 | project/build/project.js | project/build/project.js | 'use strict';
/*jslint nomen: true, stupid: true*/
module.exports = function (grunt) {
grunt.registerTask('integration-test', 'Run integration tests', [
'docker-integration-test'
]);
grunt.registerMultiTask('docker-integration-test', function runTask() {
/*eslint-disable no-invalid-this*/... | 'use strict';
/*jslint nomen: true, stupid: true*/
module.exports = function (grunt) {
grunt.registerTask('integration-test', 'Run integration tests', [
'docker-integration-test'
]);
grunt.registerMultiTask('docker-integration-test', function runTask() {
/*eslint-disable no-invalid-this*/... | Add integration test via docker | Add integration test via docker
| JavaScript | apache-2.0 | sagiegurari/node-go-require,sagiegurari/node-go-require |
67ffe97b8f8c6d78333314df94742898e9567b5b | src/js/modules/comp-lib/v1/routes/index.js | src/js/modules/comp-lib/v1/routes/index.js | import Page from './../components/templates/page.jsx';
import React from 'react';
import atomicDesign from './atomic-design';
export default (injectDeps, context) => {
const {mount, page} = context;
const PageCtx = injectDeps(Page);
atomicDesign(React, PageCtx, page, mount);
};
| import Page from './../components/templates/page.jsx';
import React from 'react';
import atomicDesign from './atomic-design';
import testing from './testing';
export default (injectDeps, context) => {
const {mount, page} = context;
const PageCtx = injectDeps(Page);
atomicDesign(React, PageCtx, page, mount);
t... | Add route towards testing page | Add route towards testing page
| JavaScript | mit | littleqairoes/standard-project-setup-webpack,littleqairoes/standard-project-setup-webpack,littleqairoes/standard-project-setup-webpack |
09b672941b82c3af9c8e48849cf981feaa5bf108 | javascript/FormFieldHelpText.js | javascript/FormFieldHelpText.js | (function($){
$.entwine('ss', function($){
$('.field label.right').entwine({
onadd:function() {
this.hide();
this.closest('.field').addClass('help-text');
}
});
$('.field.help-text label.left').entwine({
onmouseenter:function() {
var field = this.closest('.field'),
helpText = field.fin... | (function($){
$.entwine('ss', function($){
$('.field label.right, .field.span.description').entwine({
onadd:function() {
this.hide();
var field = this.closest('.field');
if (!field.hasClass('checkbox')) field.addClass('help-text');
}
});
$('.field.help-text label.left').entwine({
onmouseen... | Fix for checkboxes and descriptions | Fix for checkboxes and descriptions
| JavaScript | mit | webtorque7/silverstripe-formfieldhelptext,webtorque7/silverstripe-formfieldhelptext |
074f94cf299741bb8bb2491b128cb3620dbed032 | src/js/browser.js | src/js/browser.js | // Firefox 1.0+
module.exports = {
isFirefox: function () {
return typeof InstallTrigger !== 'undefined'
},
// Internet Explorer 6-11
isIE: function () {
return !!document.documentMode
},
// Edge 20+
isEdge() {
return !this.isIE() && !!window.StyleMedia
},
// Chrome 1+
isChrome: funct... | // Firefox 1.0+
module.exports = {
isFirefox: function () {
return typeof InstallTrigger !== 'undefined'
},
// Internet Explorer 6-11
isIE: function () {
return !!document.documentMode
},
// Edge 20+
isEdge: function() {
return !this.isIE() && !!window.StyleMedia
},
// Chrome 1+
isChr... | Change es6 shorthand notation to es5 notation | Change es6 shorthand notation to es5 notation | JavaScript | mit | crabbly/Print.js,crabbly/Print.js |
70550db64397f1e0ea758ab9635a40625ef47614 | examples/index.js | examples/index.js | import 'bootstrap/dist/css/bootstrap.min.css';
import 'nvd3/build/nv.d3.min.css';
import 'react-select/dist/react-select.min.css';
import 'fixed-data-table/dist/fixed-data-table.min.css';
import ReactDOM from 'react-dom';
import React from 'react';
import customDataHandlers from './customDataHandlers';
import { setting... | import 'bootstrap/dist/css/bootstrap.min.css';
import 'nvd3/build/nv.d3.min.css';
import 'react-select/dist/react-select.min.css';
import 'fixed-data-table/dist/fixed-data-table.min.css';
import ReactDOM from 'react-dom';
import React from 'react';
import customDataHandlers from './customDataHandlers';
import { setting... | Test for jekyll env - 1 | Test for jekyll env - 1
| JavaScript | mit | NuCivic/react-dash,NuCivic/react-dash,NuCivic/react-dashboard,NuCivic/react-dash,NuCivic/react-dashboard,NuCivic/react-dashboard |
ff00aedce11cf49e97c10dfb7b272c0b4dbd8974 | build/gulp/deploy-code.js | build/gulp/deploy-code.js | 'use strict';
var gulp = require('gulp');
var replace = require('gulp-replace-task');
gulp.task('deploy-site', ['build'], function(done) {
gulp.src('./dist/**/*.*')
.pipe(gulp.dest('./../'));
});
'use strict';
// *
// Deploy code
gulp.task('paths', function(done) {
gulp.src('./dist/**/*.js')
.pipe(repla... | 'use strict';
var gulp = require('gulp');
var replace = require('gulp-replace-task');
// AWS reqs
var s3 = require("gulp-s3");
var fs = require('fs');
// Call aws.json file
var aws = JSON.parse(fs.readFileSync('./aws.json'));
gulp.task('clean', require('del').bind(null, ['dist']));
// Update asset paths in JS fil... | Update deployment task for AWS deployment | Update deployment task for AWS deployment
| JavaScript | mit | RobEasthope/lazarus,RobEasthope/lazarus |
70ff260697938f0b8ede7e00610baa55ad1bad64 | Workspace/Project/FileIOModule.js | Workspace/Project/FileIOModule.js | var fileIO = require('rw')
var path = require('path')
module.exports =
{
readFromFile: function(filename, callback)
{
fileIO.readFile(path.resolve(__dirname, filename), 'utf8', function(error, data) {
if (error)
throw error
callback(data)
})
},
writeInFile: function(filename, da... | var fileIO = require('rw')
var path = require('path')
module.exports =
{
readFromFile: function(filename, callback)
{
fileIO.readFile(path.resolve(__dirname, filename), 'utf8', function(error, data) {
if (error)
throw error
callback(data)
})
},
writeInFile: function(filename, da... | Append to End of File While Writing in File | Append to End of File While Writing in File
| JavaScript | mit | MrWooJ/WJChipDesign,MrWooJ/WJChipDesign |
93ed00e3f05589358139c03bd4d1982aaaddc990 | src/convert.js | src/convert.js | 'use strict';
module.exports = convert
var serializeInline = require('./inline').serializeInline
/**
* convert(elem, s) performs the actual work of converting an element
* into its abstract representation.
*
* @param {Element} elem
* @param {Serialize} s
*/
function convert (elem, s) {
var node = elem,
... | 'use strict';
module.exports = convert
var serializeInline = require('./inline').serializeInline
/**
* convert(elem, s) performs the actual work of converting an element
* into its abstract representation.
*
* @param {Element} elem
* @param {Serialize} s
*/
function convert (elem, s) {
var allMarkups = [],
... | Apply markups from the outside in | Apply markups from the outside in
| JavaScript | mit | lucthev/serialize-element,lucthev/serialize |
49a6cbd09caab09d66e9885fd620597db32b63f3 | log/EventIndex.js | log/EventIndex.js | // See Purple/license.txt for Google BSD license
// Copyright 2011 Google, Inc. johnjbarton@johnjbarton.com
define(['lib/Base'],
function (Base) {
var EventIndex = {};
EventIndex.recv = function(data) {
this.objectBuffer.push(data);
};
EventIndex._getMatcher = function(constraints) {
return... | // See Purple/license.txt for Google BSD license
// Copyright 2011 Google, Inc. johnjbarton@johnjbarton.com
define(['lib/Base'],
function (Base) {
var SparseArray = {};
SparseArray.set = function(p_id, data) {
this.objectsByP_ID[p_id] = data;
this.p_ids.push(p_id);
};
// maybe undefined.
... | Rewrite as sparse array class | Rewrite as sparse array class | JavaScript | bsd-3-clause | johnjbarton/Purple |
d1d3dc5dbd855532e54b5bf17a5f5bc08bb789c5 | lib/navdata/maskingFunctions.js | lib/navdata/maskingFunctions.js | exports.TAG_TYPE_MASK = function (tagtype) {
return (tagtype == 0) ? 0 : 1 << (tagtype - 1);
};
exports.NAVDATA_OPTION_MASK = function (option) {
return 1 << option;
};
exports.maskFromNavdataOptions = function (options) {
if (!Array.isArray(options)) {
options = Array.prototype.slice.call(arguments);
}
... | exports.TAG_TYPE_MASK = function (tagtype) {
return (tagtype == 0) ? 0 : 1 << (tagtype - 1);
};
exports.NAVDATA_OPTION_MASK = function (option) {
return 1 << option;
};
exports.maskFromNavdataOptions = function (options) {
if (!Array.isArray(options)) {
options = Array.prototype.slice.call(arguments);
}
... | Remove detritus which is causing errors. | Remove detritus which is causing errors.
| JavaScript | mit | martenl/node-ar-drone,lamiastella/node-ar-drone,thalesfsp/node-ar-drone,loftywaif002/node-ar-drone,rbtkoz/node-ar-drone,UnionTTC/node-ar-drone,felixge/node-ar-drone,Yoshka/node-ar-drone,aravindkoneru/node-ar-drone,elvinflores/https-github.com-felixge-node-ar-drone |
64073fb02d8693975934f04fe3c0ac910a44bb90 | common/predictive-text/unit_tests/headless/ascii-word-breaker.js | common/predictive-text/unit_tests/headless/ascii-word-breaker.js | var assert = require('chai').assert;
var sinon = require('sinon');
let LMLayer = require('../../build');
var breakASCIIWords = require('../../build/intermediate').wordBreakers['ascii'];
describe('The ASCIIWordBreaker', function() {
it('breaks simple English sentences', function () {
let breaks = breakASCI... | var assert = require('chai').assert;
var breakASCIIWords = require('../../build/intermediate').wordBreakers['ascii'];
describe('The ASCII word breaker', function () {
it('should break simple English sentences', function () {
let breaks = breakASCIIWords('Look! -- The quick brown fox jumps... over the lazy dog!'... | Clean up ASCII word breaker unit test. | Clean up ASCII word breaker unit test.
| JavaScript | apache-2.0 | tavultesoft/keymanweb,tavultesoft/keymanweb |
8a6269e00eb83a6faed810cbe07f7183bd42abf9 | src/js/qber.js | src/js/qber.js | var React = require('react');
var QBer = require('./components/QBer.react');
var MessagePanel = require('./components/MessagePanel.react');
React.render(
<QBer />,
document.getElementById('qber')
);
React.render(
<MessagePanel />,
document.getElementById('message_panel')
);
| var React = require('react');
var QBer = require('./components/QBer.react');
var MessagePanel = require('./components/MessagePanel.react');
var DatasetActions = require('./actions/DatasetActions');
DatasetActions.initializeStore();
React.render(
<QBer />,
document.getElementById('qber')
);
React.render(
<Mess... | Initialize store when loading the page | Initialize store when loading the page
| JavaScript | mit | CLARIAH-SDH/qber,CLARIAH/qber,CLARIAH-SDH/qber,CLARIAH-SDH/qber,CLARIAH/qber,CLARIAH/qber |
73751d0976f90d46464959fa1c8848f493aa2264 | src/widgets/DetailRow.js | src/widgets/DetailRow.js | /* eslint-disable react/forbid-prop-types */
/**
* mSupply Mobile
* Sustainable Solutions (NZ) Ltd. 2016
*/
import React from 'react';
import { View } from 'react-native';
import PropTypes from 'prop-types';
import { SimpleLabel } from './SimpleLabel';
/**
* Simple layout component render sequential SimpleLabel ... | /* eslint-disable react/forbid-prop-types */
/**
* mSupply Mobile
* Sustainable Solutions (NZ) Ltd. 2016
*/
import React from 'react';
import { View } from 'react-native';
import PropTypes from 'prop-types';
import { SimpleLabel } from './SimpleLabel';
/**
* Simple layout component render sequential SimpleLabel ... | Add detail row style adjustments | Add detail row style adjustments
| JavaScript | mit | sussol/mobile,sussol/mobile,sussol/mobile,sussol/mobile |
be4367fd440c72500b4814ecfa5d125f3e76bfd7 | public/client/models/Message.js | public/client/models/Message.js | //setup backbone message model
var Message = Backbone.Model.extend({
defaults:{
username:'',
text: '',
room:'',
lang: 'en',
translations: {}
}
});
| //setup backbone message model
var Message = Backbone.Model.extend({
defaults:{
username:'',
text: '',
room:'',
lang: 'en',
avatar: 'A01',
translations: {}
}
});
| Add default avatar to model defaults | Add default avatar to model defaults
| JavaScript | mit | leeric92/HumpbackSeahorses,leeric92/HumpbackSeahorses,leeric92/HumpbackSeahorses |
8fd6a4a461ea5dab2ec407fff4142d8450c1f92b | test/main.spec.js | test/main.spec.js | 'use strict';
var testKey = 'test-key';
var testOptions = {
publishNavigationTimingMetrics: true,
publishUserActive: true,
application: 'ui'
};
var testConfig = {
apiKey: testKey,
options: testOptions
};
angular.module('test', ['weblogng'])
.constant('weblogngApiKey', testKey)
.constant('weblogngOp... | 'use strict';
var testKey = 'test-api-key';
var testOptions = {
publishNavigationTimingMetrics: true,
publishUserActive: true,
application: 'ui'
};
var testConfig = {
apiKey: testKey,
options: testOptions
};
angular.module('test', ['weblogng'])
.constant('weblogngConfig', testConfig)
;
describe('M... | Remove constants that were used in 'old' weblogng module configuration approach. | Remove constants that were used in 'old' weblogng module configuration approach.
| JavaScript | mit | weblogng/angular-weblogng |
f938c89de55a022aec98bceec0f9edbd05cafdbb | app/assets/javascripts/history.js | app/assets/javascripts/history.js | $(document).ready(function() {
$('#history_tab').on('click', function(event) {
event.preventDefault();
event.stopPropagation();
var $details = $(event.target);
console.log($details[0].href)
$.ajax({
url: $details[0].href,
type: 'GET',
}).done(function (response) {
$('.pr... | $(document).ready(function() {
$('#history_tab').on('click', function(event) {
event.preventDefault();
event.stopPropagation();
var $details = $(event.target);
console.log($details[0].href)
$.ajax({
url: $details[0].href,
type: 'GET',
}).done(function (response) {
$('.pr... | Use jquery to send parcels tab and trips tab html back into profile in DOM | Use jquery to send parcels tab and trips tab html back into profile in DOM
| JavaScript | mit | nyc-rock-doves-2015/caravan,bicyclethief/caravan,nyc-rock-doves-2015/caravan,bicyclethief/caravan,grantziolkowski/caravan,bicyclethief/caravan,grantziolkowski/caravan,grantziolkowski/caravan,nyc-rock-doves-2015/caravan |
4ae6957ab38d3a8799a8f2a0a7eabf58e672152a | test/serialize.js | test/serialize.js | 'use strict';
var compiler = require('../lib/compiler');
var mocha = require('mocha');
var assert = require('../lib/assert');
var datasets = require('./lib/datasets');
mocha.suite('serialize', function () {
mocha.test('print;parse = id', function () {
var examples = [
'VAR x',
'QU... | 'use strict';
var compiler = require('../lib/compiler');
var mocha = require('mocha');
var assert = require('../lib/assert');
var datasets = require('./lib/datasets');
mocha.suite('serialize', function () {
mocha.test('print;parse = id', function () {
var examples = [
'VAR x',
'QU... | Add test for parse;print of church terms | Add test for parse;print of church terms
| JavaScript | mit | fritzo/puddle-syntax |
8aa02b4d7b03471dfafd974c3e94b14f1bd914e8 | src/setattr.js | src/setattr.js | /* global SVGElement */
import { setStyle } from './setstyle';
import { isFunction, getEl } from './util';
const xlinkns = 'http://www.w3.org/1999/xlink';
export const setAttr = (view, arg1, arg2) => {
const el = getEl(view);
let isSVG = el instanceof SVGElement;
if (arg2 !== undefined) {
if (arg1 === 'st... | /* global SVGElement */
import { setStyle } from './setstyle';
import { isFunction, getEl } from './util';
const xlinkns = 'http://www.w3.org/1999/xlink';
export const setAttr = (view, arg1, arg2) => {
const el = getEl(view);
let isSVG = el instanceof SVGElement;
if (arg2 !== undefined) {
if (arg1 === 'st... | Add support for dataset Object | Add support for dataset Object
| JavaScript | mit | redom/redom,pakastin/redom,tomerigal/redom |
ab850dacb2913cfc401224dc5e8fcc0703401139 | scripts/SwipeDetector.js | scripts/SwipeDetector.js | (function(){
"use strict";
var defaults = {
Selector : null,
Threshold: 30
}
var SwipeDetector = function(options) {
if (typeof options !== "object") {
options = {
Selector: options
};
}
var config = $.extend(defaults,options, { Start: null });
var clear = function () {
config.Sta... | (function(){
"use strict";
var defaults = {
Selector : null,
Threshold: 30
}
var SwipeDetector = function(options) {
if (typeof options !== "object") {
options = {
Selector: options
};
}
var config = $.extend(defaults,options, { Start: null });
var handlers = {};
var clear = fun... | Fix for touch vs mouse events | Fix for touch vs mouse events
Strategy pattern for handling mouse vs touch.
| JavaScript | cc0-1.0 | christopherbauer/FunWithJavascript,christopherbauer/FunWithJavascript |
270373d21430b5392910424f4ef4bb5a566d73c3 | src/locale/de-de.js | src/locale/de-de.js | const quotes = {
leftDoubleQuote : "„",
rightDoubleQuote : "“",
leftSingleQuote : "‚",
rightSingleQuote : "‘",
};
const numbers = {
ordinalIndicator : "\\.",
romanOrdinalIndicator : "\\.",
}
const abbreviationsForNbsp = [
"S.",
"z."
]
export default {
quotes,
numbers,
abbreviationsFor... | const quotes = {
leftDoubleQuote : "„",
rightDoubleQuote : "“",
leftSingleQuote : "‚",
rightSingleQuote : "‘",
};
const numbers = {
ordinalIndicator : "\\.",
romanOrdinalIndicator : "\\.",
}
const abbreviationsForNbsp = [
"S.",
"z."
]
export default {
quotes,
numbers,
abbreviationsFor... | Include German abbreviations for later work | Include German abbreviations for later work
| JavaScript | mit | surfinzap/typopo |
9c46dc1526497e26eea77ad76228df89cd1c03e7 | reviewboard/static/rb/js/resources/models/userFileAttachmentModel.es6.js | reviewboard/static/rb/js/resources/models/userFileAttachmentModel.es6.js | /**
* A new or existing user file attachment.
*
* Model Attributes:
* caption (string):
* The file attachment's caption.
*
* userName (string):
* The username of the owner of the file attachment.
*
* downloadURL (string):
* The URL to download the file, for existing file a... | /**
* A new or existing user file attachment.
*
* Model Attributes:
* caption (string):
* The file attachment's caption.
*
* userName (string):
* The username of the owner of the file attachment.
*
* downloadURL (string):
* The URL to download the file, for existing file a... | Fix resource paths for user file attachments. | Fix resource paths for user file attachments.
When I fixed the names in the user file attachments resource to make it
available within the API templates, I neglected to actually test the javascript
in the Review Board UI, which was still using the old paths and names. This
change fixes it.
Testing done:
Drag-and-drop... | JavaScript | mit | brennie/reviewboard,brennie/reviewboard,brennie/reviewboard,chipx86/reviewboard,reviewboard/reviewboard,reviewboard/reviewboard,reviewboard/reviewboard,reviewboard/reviewboard,chipx86/reviewboard,brennie/reviewboard,chipx86/reviewboard,chipx86/reviewboard |
870c21457c03216ca0ff0013c709dc4eb32d8dab | src/containers/ProfileEditForm/ProfileEditForm.validations.js | src/containers/ProfileEditForm/ProfileEditForm.validations.js | export default {
givenName: {
required: true,
validateOnBlur: true,
},
familyName: {
required: true,
validateOnBlur: true,
},
nickname: {
required: false,
validateOnBlur: true,
},
email: {
required: true,
email: true,
validateOnBlur: true,
},
};
| export default {
givenName: {
required: true,
validateOnBlur: true,
},
familyName: {
required: true,
validateOnBlur: true,
},
nickname: {
required: false,
validateOnBlur: true,
},
email: {
required: true,
email: true,
validateOnBlur: true,
},
emailVerified: {
re... | Fix bug: need complete list of validation fields | Fix bug: need complete list of validation fields
| JavaScript | mit | opencredo/opencredo-react-boilerplate,opencredo/opencredo-react-boilerplate,Bartekus/r3,Bartekus/r3 |
f199105d7bc67f310af4323612b976657b0960f9 | ch02/04_minify-task/Gruntfile.js | ch02/04_minify-task/Gruntfile.js | 'use strict';
module.exports = function(grunt){
grunt.initConfig({
uglify: {
cobra: {
files: {
'build/js/cobra.min.js': 'public/js/cobra.js'
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-uglify');
};
| 'use strict';
module.exports = function(grunt){
grunt.initConfig({
uglify: {
js: {
files: {
'build/js/foo.min.js': 'public/js/foo.js'
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-uglify');
};
| Correct task target name and file names | Correct task target name and file names
| JavaScript | mit | stevemao/buildfirst,stevemao/buildfirst,buildfirst/buildfirst,stevemao/buildfirst,subramaniashiva/buildfirst,subramaniashiva/buildfirst,cesarmarinhorj/buildfirst,thalesmello/buildfirst,thalesmello/buildfirst,buildfirst/buildfirst,cesarmarinhorj/buildfirst,thalesmello/buildfirst,cesarmarinhorj/buildfirst,subramaniashiva... |
0143cebd39da945b26470c45d6d372379621ae5a | source/javascript/application/trackEditor/views/instrumentManagerView.js | source/javascript/application/trackEditor/views/instrumentManagerView.js | define([
"use!underscore",
"use!backbone",
"baseView",
"settings",
"./instrumentView",
], function(_, Backbone, BaseView, settings, InstrumentView) {
var InstrumentManagerView = BaseView.extend({
modelEvents: {
"instrumentAdded": function (instrument) {
this.addInstrumentView(instrument);
},
"inst... | define([
"use!underscore",
"use!backbone",
"baseView",
"settings",
"./instrumentView",
], function(_, Backbone, BaseView, settings, InstrumentView) {
var InstrumentManagerView = BaseView.extend({
modelEvents: {
"instrumentAdded": function (instrument) {
this.addInstrumentView(instrument);
}
},
re... | Remove InstrumentManagerView's unnecessary 'instrumentRemoved' model event listener. | Remove InstrumentManagerView's unnecessary 'instrumentRemoved' model event listener.
| JavaScript | mit | stuartkeith/webaudiosequencer,stuartkeith/webaudiosequencer |
ba585b5182a9cf99284032dff1a1e990dd62a4f5 | test/unit/lib/unit/is-guest-checkout.js | test/unit/lib/unit/is-guest-checkout.js | 'use strict';
var fake = require('../../../helpers/fake');
var isGuestCheckout = require('../../../../src/lib/is-guest-checkout');
describe('isGuestCheckout', function () {
it('returns true when given a tokenization key', function () {
var auth = 'fake_tokenization_key';
expect(isGuestCheckout(auth)).to.be... | 'use strict';
var fake = require('../../../helpers/fake');
var isGuestCheckout = require('../../../../src/lib/is-guest-checkout');
describe('isGuestCheckout', function () {
it('returns true when given a tokenization key', function () {
var auth = fake.tokenizationKey;
expect(isGuestCheckout(auth)).to.be.tr... | Use authentication from helpers in isGuestCheckout tests | Use authentication from helpers in isGuestCheckout tests
| JavaScript | mit | braintree/braintree-web-drop-in,braintree/braintree-web-drop-in,braintree/braintree-web-drop-in |
b262d97518576ed0eacd7b5345b3e847c3d7eeea | tests/entry.js | tests/entry.js | var testsContext = require.context('./unit/', true, /.js$/);
testsContext.keys().forEach(testsContext);
| import BabelPolyFill from 'babel-polyfill';
var testsContext = require.context('./unit/', true, /.js$/);
testsContext.keys().forEach(testsContext);
| Add `babel-polyfill` to test environment | Add `babel-polyfill` to test environment
| JavaScript | mit | ufocoder/redux-universal-boilerplate |
4f223de7cfab259e83847b8f331dea0fc0e367ec | packages/pundle-transformer-js/lib/plugin-remove-dead-nodes.js | packages/pundle-transformer-js/lib/plugin-remove-dead-nodes.js | // @flow
// Empty out bodies of falsy parts of if/else statements
// to avoid requiring modules that aren't needed aka
// if (process.env.NODE_ENV === 'production') module.exports = require('./prod-version') else module.exports = require('./dev-version')
// OR
// module.exports = process.env.NODE_ENV === 'production' ... | // @flow
import * as t from '@babel/types'
// Empty out bodies of falsy parts of if/else statements
// to avoid requiring modules that aren't needed aka
// if (process.env.NODE_ENV === 'production') module.exports = require('./prod-version') else module.exports = require('./dev-version')
// OR
// module.exports = pro... | Support ternary in dead code removal plugin | :new: Support ternary in dead code removal plugin
| JavaScript | mit | motion/pundle,steelbrain/pundle,steelbrain/pundle,steelbrain/pundle |
d91ebf64fc787bbd38f6daa1ce0e0cb261bd85fb | tornado_backbone/templates/model.tpl.js | tornado_backbone/templates/model.tpl.js | /**
* File: model.tpl
* User: Martin Martimeo
* Date: 30.04.13
* Time: 13:12
*/
var {{ model_name }} = Backbone.Model.extend({
defaults: { {% for column in columns %}{% if column.default %}"{{ column.name }}": "{{ column.default }}", {% end %}{% end %} },
urlRoot: '{{ api_url }}/{{ collection_name }}',... | /**
* File: model.tpl
* User: Martin Martimeo
* Date: 30.04.13
* Time: 13:12
*/
var {{ model_name }} = Backbone.Model.extend({
defaults: { {% for column in columns %}{% if column.default %}"{{ column.name }}": "{{ column.default }}", {% end %}{% end %} },
urlRoot: '{{ api_url }}/{{ collection_name }}',... | Add list of readonly columns | Add list of readonly columns
| JavaScript | agpl-3.0 | tornado-utils/tornado-backbone,tornado-utils/tornado-backbone |
b97fa30d2efc8331c341e40f60f909f8c04d9f0f | tools/css-json-to-ttl.js | tools/css-json-to-ttl.js |
// Convert JSON on CVSS to Turtle for Css property namespace
const cssData = require( '../ed/css/CSS.json')
// console.log(JSON.stringify(cssData).slice(0,100))
function camelCasify (str) {
var result = str[0]
for (let i=1; i < str.length; i++) {
result += str[i-1] === '-' ? str[i].toUpperCase() : str[i]
... |
// Convert JSON on CVSS to Turtle for Css property namespace
const cssData = require( '../ed/css/CSS.json')
// console.log(JSON.stringify(cssData).slice(0,100))
function camelCasify (str) {
var result = str[0]
for (let i=1; i < str.length; i++) {
result += str[i-1] === '-' ? str[i].toUpperCase() : str[i]
... | Add editorial improvements to CSS ontology generation | Add editorial improvements to CSS ontology generation
Implements suggestions in https://github.com/w3c/webref/pull/327
| JavaScript | mit | tidoust/reffy-reports,tidoust/reffy-reports |
f325b081a685c03b89f1b4a828757c670ff36442 | webpack.config.js | webpack.config.js | var webpack = require('webpack');
module.exports = {
entry: [
'webpack-dev-server/client?http://localhost:3000',
'webpack/hot/dev-server',
'./scripts/index'
],
output: {
path: __dirname,
filename: 'bundle.js',
publicPath: '/scripts/'
},
plugins: [
new webpack.HotModuleReplacementP... | var webpack = require('webpack');
module.exports = {
devtool: 'eval',
entry: [
'webpack-dev-server/client?http://localhost:3000',
'webpack/hot/dev-server',
'./scripts/index'
],
output: {
path: __dirname,
filename: 'bundle.js',
publicPath: '/scripts/'
},
plugins: [
new webpack.Ho... | Add devtool: 'eval' for Chrome DevTools | Add devtool: 'eval' for Chrome DevTools | JavaScript | mit | michaelBenin/react-hot-boilerplate,j-der/pickmeup-ui,michaelBenin/react-hot-boilerplate,debarshri/react-logger,amysimmons/mememe,cpachomski/Lines,jxnblk/react-basscss-hot-boilerplate,buttercomponents/butter-component-show-detail,phosphene/react-d3-hotload-test-demo,gustavoguichard/react-image-uploader,phosphene/react-d... |
8e25dc7e7bef048ef1c590aeb5690bf280b6a0d6 | webpack.config.js | webpack.config.js | /* global __dirname, require, module*/
const webpack = require('webpack');
const UglifyJsPlugin = webpack.optimize.UglifyJsPlugin;
const path = require('path');
const env = require('yargs').argv.env; // use --env with webpack 2
let libraryName = 'Library';
let plugins = [], outputFile;
if (env === 'build') {
plu... | /* global __dirname, require, module*/
const webpack = require('webpack');
const UglifyJsPlugin = webpack.optimize.UglifyJsPlugin;
const path = require('path');
const env = require('yargs').argv.env; // use --env with webpack 2
let libraryName = 'Library';
let plugins = [], outputFile;
if (env === 'build') {
plug... | Fix lint, and add node_modules in the resolver | Fix lint, and add node_modules in the resolver | JavaScript | mit | krasimir/webpack-library-starter,bigbee/react-universal-form |
13bbb814530181e3293c9194d179138032ad4398 | config/initializers/sequelize.js | config/initializers/sequelize.js | Sequelize = require('sequelize')
dbConfig = require('../database.json')['staging']
pg = require('pg').native;
sequelize = new Sequelize(dbConfig.database, dbConfig.user, dbConfig.password, {
dialect: "postgres",
host: dbConfig.host,
port: 5432,
omitNull: true,
native: true,
protocol: 'postgres'
});
module... | Sequelize = require('sequelize')
dbConfig = require('../database.json')['staging']
pg = require('pg').native;
var db;
if (process.env.POSTGRES_URL) {
var match = process.env.POSTGRES_URL.match(/postgres:\/\/([^:]+):([^@]+)@([^:]+):(\d+)\/(.+)/);
var db = new Sequelize(match[5], match[1], match[2], {
dialect: ... | Add option to specify postgres config with url in ENV. | [FEATURE] Add option to specify postgres config with url in ENV.
| JavaScript | isc | Parkjeahwan/awegeeks,xdv/gatewayd,crazyquark/gatewayd,zealord/gatewayd,whotooktwarden/gatewayd,whotooktwarden/gatewayd,zealord/gatewayd,crazyquark/gatewayd,xdv/gatewayd,Parkjeahwan/awegeeks |
a010d6957b4fdbbab2d7b3bb6793881ca26b9ccd | webpack.dll.js | webpack.dll.js | const path = require("path")
const webpack = require("webpack")
const HardSourceWebpackPlugin = require("hard-source-webpack-plugin")
process.noDeprecation = true
module.exports = {
cache: true,
entry: {
vendor: ["./web/static/js/vendor"],
},
stats: "errors-only",
output: {
path: path.resolve(__dirn... | const path = require("path")
const webpack = require("webpack")
const HardSourceWebpackPlugin = require("hard-source-webpack-plugin")
process.noDeprecation = true
module.exports = {
cache: true,
entry: {
vendor: ["./web/static/js/vendor"],
},
stats: "errors-only",
output: {
path: path.resolve(__dirn... | Disable ReactDev tools warning that appears in React 16 | Disable ReactDev tools warning that appears in React 16
- this was crufting up the output of our end-to-end tests locally, as these are compiled using development configs
| JavaScript | mit | samdec11/remote_retro,stride-nyc/remote_retro,stride-nyc/remote_retro,stride-nyc/remote_retro |
9423a19d8c68de92e938d0614a205d325ee44c50 | js/components/AboutDialog.js | js/components/AboutDialog.js | import React from 'react';
const AboutDialog = ({ closeDialog }) => (
<div>
<button className="dialog-close" onClick={closeDialog}>
<i className="icon-close" />
</button>
<p>
This is a MineSweeper game implemented with React and Redux.
<br />
<br />
You can play it in the sa... | import React from 'react';
const AboutDialog = ({ closeDialog }) => (
<div>
<button className="dialog-close" onClick={closeDialog}>
<i className="icon-close" />
</button>
<p>
This is a Mine Sweeper game built with React and Redux.
<br />
<br />
You can play it in the same wa... | Update to the about dialog text | Update to the about dialog text
| JavaScript | mit | hihuz/mine-sweeper,hihuz/mine-sweeper |
3e9fc102ca1c189a31400df3818a0db55b11e082 | app/javascript/components/widgets/widgets/land-cover/primary-forest/config.js | app/javascript/components/widgets/widgets/land-cover/primary-forest/config.js | export default {
widget: 'primaryForest',
title: 'Primary forest in {location}',
categories: ['land-cover'],
types: ['country'],
admins: ['adm0', 'adm1', 'adm2'],
options: {
landCategories: true,
thresholds: true
},
colors: 'extent',
metaKey: 'widget_primary_forest',
datasets: [
// tree ... | export default {
widget: 'primaryForest',
title: 'Primary forest in {location}',
categories: ['land-cover'],
types: ['country'],
admins: ['adm0', 'adm1', 'adm2'],
options: {
landCategories: true,
thresholds: true
},
colors: 'extent',
metaKey: 'widget_primary_forest',
datasets: [
// tree ... | Update primary forest widget sentence | Update primary forest widget sentence
| JavaScript | mit | Vizzuality/gfw,Vizzuality/gfw |
ff2c39adb862974e4626ff0dcb32ec870c99f701 | packages/mjml-validator/src/rules/validChildren.js | packages/mjml-validator/src/rules/validChildren.js | import { elements } from 'mjml-core'
import filter from 'lodash/filter'
import includes from 'lodash/includes'
import ruleError from './ruleError'
export const validChildren = (element) => {
const { children, tagName } = element
const Component = elements[tagName]
if (!Component) {
return;
}
if (!child... | import { elements } from 'mjml-core'
import filter from 'lodash/filter'
import includes from 'lodash/includes'
import ruleError from './ruleError'
export const validChildren = (element) => {
const { children, tagName } = element
const Component = elements[tagName]
if (!Component) {
return;
}
if (!child... | Add ChildComponent.tagName in the error | Add ChildComponent.tagName in the error | JavaScript | mit | rogierslag/mjml,mjmlio/mjml,rogierslag/mjml |
f4c0397ee8fd21ab46a06fd8c78c2ebe1176c80b | all-aboard-battleship/js/main.js | all-aboard-battleship/js/main.js |
var startGame = function(){
return false;
}
var Ships = function(){
return false;
}
var Players = function(){
return false;
}
var Scoreboard = function(){
return false;
}
|
var startGame = function(){
return false;
};
function Ship(shipSize,shipType){
this.shipSize = shipSize || 0;
this.shipType = shipType;
}
var submarine = new Ship(3, "Submarine");
var destroyer = new Ship(3,"Destroyer");
var patrolBoat = new Ship(2, "Patrol Boat");
var battleship = new Ship(4, "Battleship");
v... | Add click handler (hard-code) for the first tile on board | Add click handler (hard-code) for the first tile on board
| JavaScript | mit | outdoorsole/BattleShip,outdoorsole/BattleShip |
a0978f2edd0a4c7c7aab1f602653546732655ab7 | config/server/config/services.js | config/server/config/services.js | 'use strict';
module.exports = {
mongodb: {
class: 'vendor.mongodb'
},
db: {
collections: ['db'],
class: 'db',
declinations: '$connections$',
properties: {
name: '@_@',
connectionUrl: '@url@',
connectionOptions: '@options@',
... | 'use strict';
module.exports = {
mongodb: {
class: 'vendor.mongodb'
},
db: {
collections: ['db'],
class: 'db',
declinations: '$connections$',
properties: {
id: '@_@',
connectionUrl: '@url@',
connectionOptions: '@options@',
... | Add collection and db id injection | Add collection and db id injection
| JavaScript | mit | Gnucki/danf-gnucki-mongodb |
6c0fcc48028ffd3f273b5b0f6c36e25e1d5ca12c | app/assets/javascripts/search.js | app/assets/javascripts/search.js | $(function() {
var $tabs = $('#search-results-tabs'),
$searchForm = $('.js-search-hash');
if($tabs.length > 0){
$tabs.tabs({ 'defaultTab' : getSelectedSearchTabIndex(), scrollOnload: true });
}
function getSelectedSearchTabIndex(){
var tabIds = $('.search-navigation a').map(function(i, el){
... | $(function() {
var $tabs = $('#search-results-tabs'),
$searchForm = $('.js-search-hash');
if($tabs.length > 0){
$tabs.tabs({ 'defaultTab' : getSelectedSearchTabIndex(), scrollOnload: true });
}
function getSelectedSearchTabIndex(){
var tabIds = $('.search-navigation a').map(function(i, el){
... | Change method name and document for clarity | Change method name and document for clarity
| JavaScript | mit | alphagov/frontend,alphagov/frontend,alphagov/frontend,alphagov/frontend |
75316478871c2580bec220db66d1aa5eec72ac5f | app/assets/javascripts/angular/common/models/user-model.js | app/assets/javascripts/angular/common/models/user-model.js | (function(){
'use strict';
angular
.module('secondLead')
.factory('UserModel',['Auth', 'Restangular', function(Auth, Restangular) {
var baseUsers = Restangular.all('users');
var currentUser = null;
return {
getAll: baseUsers.getList().$object,
getOne: function(userId) {
... | (function(){
'use strict';
angular
.module('secondLead')
.factory('UserModel',['Auth', 'Restangular', 'store', function(Auth, Restangular, store) {
var baseUsers = Restangular.all('users');
return {
getAll: baseUsers.getList().$object,
getOne: function(userId) {
return Rest... | Add islogged to user model | Add islogged to user model
| JavaScript | mit | ac-adekunle/secondlead,ac-adekunle/secondlead,ac-adekunle/secondlead |
26e4f70285a21ccec03a66516c5e0c8c1eba2849 | lib/CardGame/cardGameTest.js | lib/CardGame/cardGameTest.js | /* eslint-env mocha */
let expect = require('chai').expect
let CardGame = require('./index')
let Deck = CardGame.Deck
describe('Deck', function () {
specify('An empty deck with no cards', function () {
let deckData = { cards: [ ] }
let deck = new Deck(deckData)
expect(deck.cards.length).to.eq(0)
})
... | /* eslint-env mocha */
let expect = require('chai').expect
let CardGame = require('./index')
let Deck = CardGame.Deck
describe('Deck', function () {
specify('An empty deck with no cards', function () {
let deckData = { cards: [ ] }
let deck = new Deck(deckData)
expect(deck.cards.length).to.eq(0)
})
... | Use the draw function in the test | Use the draw function in the test
| JavaScript | apache-2.0 | carlthuringer/game-off-2016,carlthuringer/game-off-2016,carlthuringer/game-off-2016 |
a831a133e86c98ec069507dbd3e268a4b42fd719 | js/main.js | js/main.js | $(document).ready(function(){
$("#owl-demo").owlCarousel({
autoPlay: 3000, //Set AutoPlay to 3 seconds
items : 3,
itemsDesktop : [1199,3],
itemsDesktopSmall : [979,3],
navigation: true,
navigationText: ["<i class='fa fa-angle-left'></i>","<i class='fa fa-angle-right'></i>"]
});
$("#slide-... | $(document).ready(function(){
$("#owl-demo").owlCarousel({
autoPlay: 3000, //Set AutoPlay to 3 seconds
items : 4,
itemsDesktop : [1199,3],
itemsDesktopSmall : [979,3],
navigation: true,
navigationText: ["<i class='fa fa-angle-left'></i>","<i class='fa fa-angle-righ... | Make Awesome Creations Carousel 4 | Make Awesome Creations Carousel 4
| JavaScript | apache-2.0 | ForceProject/ROS-ForceJS,ForceProject/ROS-ForceJS |
c0c9bf1a9d2ad2b796d455566f25ab6ab9333eea | client/src/app/routes/signUp/modules/signUp/signUp.spec.js | client/src/app/routes/signUp/modules/signUp/signUp.spec.js | import * as signUpActions from './signUp';
import reducer from './signUp';
describe('signUp reducer', () => {
it('should return the initial state', () => {
expect(
reducer(undefined, {})
).toEqual({
isFetchingSuccessful: false,
isFetching: false,
errorMessage: {}
}
)
... | import * as signUpActions from './signUp';
import reducer from './signUp';
describe('signUp reducer', () => {
it('should return the initial state', () => {
expect(
reducer(undefined, {})
).toEqual({
isFetchingSuccessful: false,
isFetching: false,
errorMessage: {}
}
)
... | Fix unit test to sign action creators | Fix unit test to sign action creators
| JavaScript | mit | Madmous/Trello-Clone,Madmous/madClones,Madmous/Trello-Clone,Madmous/madClones,Madmous/madClones,Madmous/Trello-Clone,Madmous/madClones |
90dde9687bdbacbb0f02d5fc15a244e1bcea4523 | autotest/tests/platform.tests.js | autotest/tests/platform.tests.js | describe('Platform (cordova)', function () {
it("should exist", function() {
expect(cordova).toBeDefined();
});
describe('Platform (Cordova)', function () {
it("should exist", function() {
expect(window.Cordova).toBeDefined();
});
});
describe('Platform (PhoneGap)... | describe('Platform (cordova)', function () {
it("should exist", function() {
expect(cordova).toBeDefined();
});
it("exec method should exist", function() {
expect(cordova.exec).toBeDefined();
expect(typeof cordova.exec).toBe('function');
});
});
| REMOVE plugins and PhoneGap global objects from JavaScript implementation | CB-388: REMOVE plugins and PhoneGap global objects from JavaScript implementation
| JavaScript | apache-2.0 | polyvi/xface-mobile-spec,polyvi/xface-mobile-spec,apache/cordova-mobile-spec,ollie314/cordova-mobile-spec,polyvi/xface-mobile-spec,ollie314/cordova-mobile-spec,corimf/cordova-mobile-spec,apache/cordova-mobile-spec,corimf/cordova-mobile-spec,apache/cordova-mobile-spec,corimf/cordova-mobile-spec,apache/cordova-mobile-spe... |
afa44095060bcd0441e9f2f8d13ad3a2fbfdc43c | stolaf-background.widget/closed-tickets.js | stolaf-background.widget/closed-tickets.js | command: [
'curl --silent ',
'"https://help.stolaf.edu/helpdesk',
'/WebObjects/Helpdesk.woa/ra/Tickets?',
'style=details&',
'qualifier=(statustype.statusTypeName%3D%27Closed%27)&',
'limit=50&',
'apiKey=***REMOVED***"',
].join(''),
refreshFrequency: 60000,
render: function(output) {
return '<span class="... | command: [
'curl --silent ',
'"https://help.stolaf.edu/helpdesk',
'/WebObjects/Helpdesk.woa/ra/Tickets?',
'style=details&',
'qualifier=(statustype.statusTypeName%3D%27Closed%27)&',
'limit=50&',
'apiKey=***REMOVED***"',
].join(''),
refreshFrequency: 60000,
render: function(output) {
return '<span class="... | Store last-update-time in the widget | Store last-update-time in the widget
| JavaScript | mit | hawkrives/stolaf-ubersicht-widgets,hawkrives/stolaf-ubersicht-widgets,hawkrives/stolaf-ubersicht-widgets |
3d22a51134963c3f188edeacb937d2a6f17a29e5 | lib/env.js | lib/env.js | /**
* @file env
* @author treelite(c.xinle@gmail.com)
*/
/**
* 修复全局的异步函数
* 使之能在异步回调中恢复请求请求上下文
*
* @inner
* @param {Object} app server
*/
function fixGlobalMethods(app) {
var methods = ['setTimeout', 'setInterval', 'setImmediate'];
methods.forEach(function (name) {
var method = global[name];
... | /**
* @file env
* @author treelite(c.xinle@gmail.com)
*/
/**
* 修复异步函数
* 使之能在异步回调中恢复请求请求上下文
*
* @inner
* @param {Object} app server
*/
function fixAsyncMethods(app) {
/**
* 包裹异步函数
*
* @param {Object} obj 模块
* @param {string} name 方法名
*/
function wrap(obj, name) {
var m... | Fix process.nextTick, try to save context | Fix process.nextTick, try to save context
| JavaScript | mit | ecomfe/rebas,ecomfe/rebas,noikiy/rebas |
2e56b51c9aa8286f121f0a0cec20de501d0d0576 | app/assets/javascripts/pageflow/widgets.js | app/assets/javascripts/pageflow/widgets.js | pageflow.widgets = {
isPresent: function(name) {
return !!$('div.widget_' + name + '_present').length;
},
areLoaded: function() {
return !!$('div.widgets_present').length;
}
}; | pageflow.widgets = (function() {
return {
isPresent: function(name) {
return !!$('div.' + className(name)).length;
},
areLoaded: function() {
return !!$('div.widgets_present').length;
},
use: function(options, callback) {
var original = options.insteadOf;
var originalCla... | Add method to temporarily enable a widget | Add method to temporarily enable a widget
| JavaScript | mit | tf/pageflow-dependabot-test,tilsammans/pageflow,Modularfield/pageflow,codevise/pageflow,tf/pageflow-dependabot-test,tf/pageflow-dependabot-test,tf/pageflow,Modularfield/pageflow,tilsammans/pageflow,tilsammans/pageflow,Modularfield/pageflow,tilsammans/pageflow,tf/pageflow,tf/pageflow,tf/pageflow-dependabot-test,Modularf... |
311d4272a5fee0828667c215b519566f99d40e45 | package.js | package.js | Package.describe({
name: 'zodern:pure-admin',
version: '0.8.2',
summary: 'Isolated, customizable admin panel for Meteor',
git: 'https://github.com/zodern/meteor-pure-admin.git',
documentation: 'README.md'
});
Package.onUse(function(api) {
api.versionsFrom('1.8.0.2');
api.use(['ecmascript', 'dynamic-impor... | Package.describe({
name: 'zodern:pure-admin',
version: '0.8.2',
summary: 'Isolated, customizable admin panel for Meteor',
git: 'https://github.com/zodern/meteor-pure-admin.git',
documentation: 'README.md'
});
Package.onUse(function(api) {
api.versionsFrom('1.8.0.2');
api.use(['ecmascript', 'dynamic-impor... | Use zodern:melte to compile svelte files | Use zodern:melte to compile svelte files
| JavaScript | mit | zodern/meteor-pure-admin,zodern/meteor-pure-admin |
b3858e96457763a8e3137c7c294cf9d47d969195 | webpack.config.js | webpack.config.js | // JavaScript Document
// Scripts written by __gulp_init_author_name__ @ __gulp_init_author_company__
const GLOB = require("glob");
module.exports = {
config(plugins, source_directory, js_directory) {
const ENTRY = {};
const SCRIPT_FOLDERS = plugins.fs.readdirSync(source_directory);
// ... | // JavaScript Document
// Scripts written by __gulp_init_author_name__ @ __gulp_init_author_company__
const GLOB = require("glob");
module.exports = {
config(plugins, source_directory, js_directory) {
const ENTRY = {};
const SCRIPT_FOLDERS = plugins.fs.existsSync(source_directory) ? plugins.fs.r... | Make sure folders exist before reading them | Make sure folders exist before reading them
| JavaScript | mit | revxx14/new-site,JacobDB/new-site,JacobDB/new-site,JacobDB/new-site,revxx14/new-site |
fcd6bbf298d88e27c4a425e0515c9757d955fc7c | webpack.config.js | webpack.config.js | "use strict";
const HtmlWebpackPlugin = require('html-webpack-plugin');
const HOST = process.env.HOST || "127.0.0.1";
const PORT = process.env.PORT || "8080";
module.exports = {
entry: [
'./src/client/web/main.jsx'
],
output: {
path: './build/web',
filename: 'bundle.js'
},
resolve: {
extensions: ['', '.... | "use strict";
const HtmlWebpackPlugin = require('html-webpack-plugin');
const HOST = process.env.HOST || "127.0.0.1";
const PORT = process.env.PORT || "8080";
module.exports = {
entry: [
'./src/client/web/main.jsx'
],
output: {
path: './build/web',
filename: 'bundle.js'
},
resolve: {
extensions: ['', '.... | Remove unnecessary contentBase setting of webpack dev server. | [clean-up] Remove unnecessary contentBase setting of webpack dev server.
| JavaScript | apache-2.0 | jzdynamo/MTM,jzdynamo/MTM,jzdynamo/MTM,jzdynamo/MTM |
ba9b586cd4567b739cbe94e51b47e1f933ae1242 | webpack.config.js | webpack.config.js | var path = require('path');
var devConfig = {
context: path.join(__dirname, '/app'),
entry: [
'./app.js'
],
output: {
path: path.join(__dirname, '/build/'),
publicPath: '/public/assets/js/',
filename: 'app.js',
},
devtool: 'eval-source-map',
devServer: {
... | var path = require('path');
var devConfig = {
context: path.join(__dirname, '/app'),
entry: [
'./app.js'
],
output: {
path: path.join(__dirname, '/build/'),
publicPath: '/public/assets/js/',
filename: 'app.js',
},
devtool: 'eval-source-map',
devServer: {
... | Change log level to info | Change log level to info
| JavaScript | mit | rbartoli/react-boilerplate,fryymann715/merciful-eland,rbartoli/react-boilerplate,fryymann715/merciful-eland |
5ad80c5925dc6b47510fb238d33439192500602c | webpack.config.js | webpack.config.js | var path = require('path');
var webpack = require('webpack');
module.exports = {
regular: {
devtool: 'source-map',
output: {
filename: 'meyda.js',
library: 'Meyda',
libraryTarget: 'var'
},
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
... | var path = require('path');
var webpack = require('webpack');
module.exports = {
regular: {
devtool: 'source-map',
output: {
filename: 'meyda.js',
library: 'Meyda',
libraryTarget: 'umd'
},
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
... | Change libraryTarget to UMD, remove add-module-export plugin | Change libraryTarget to UMD, remove add-module-export plugin
| JavaScript | mit | hughrawlinson/meyda,meyda/meyda,meyda/meyda,meyda/meyda |
6382dee9b612d41848d69ef979d2f427108c3273 | client/tests/acceptance/visit-home-test.js | client/tests/acceptance/visit-home-test.js | import Ember from 'ember';
import { module, test } from 'qunit';
import startApp from 'firedragon/tests/helpers/start-app';
module('Acceptance | visit home', {
beforeEach: function() {
this.application = startApp();
},
afterEach: function() {
Ember.run(this.application, 'destroy');
}
});
test('visiti... | import Ember from 'ember';
import { module, test } from 'qunit';
import startApp from 'firedragon/tests/helpers/start-app';
module('Acceptance | visit home', {
beforeEach: function() {
this.application = startApp();
},
afterEach: function() {
Ember.run(this.application, 'destroy');
}
});
test('visiti... | Update test for changed layout | Update test for changed layout
| JavaScript | mit | bubblebox/server,bubblebox/client-ember,ariejan/firedragon,ariejan/firedragon,bubblebox/server,bubblebox/client-ember |
df173a307488b90c4c1486fb2a64029032c18d2f | webapps/callimachus/scripts/add-resource.js | webapps/callimachus/scripts/add-resource.js | // add-resource.js
/*
Copyright (c) 2011 Talis Inc, Some Rights Reserved
Licensed under the Apache License, Version 2.0, http://www.apache.org/licenses/LICENSE-2.0
*/
(function($){
calli.addTemplate = calli.addResource = function(event) {
event = calli.fixEvent(event);
var node = event.target;
var rel = $(no... | // add-resource.js
/*
Copyright (c) 2011 Talis Inc, Some Rights Reserved
Licensed under the Apache License, Version 2.0, http://www.apache.org/licenses/LICENSE-2.0
*/
(function($){
calli.addTemplate = calli.addResource = function(event, container) {
event = calli.fixEvent(event);
var node = container ? $(cont... | Add second argument to addResource for container | Add second argument to addResource for container
| JavaScript | apache-2.0 | edwardsph/callimachus,Thellmann/callimachus,Thellmann/callimachus,3-Round-Stones/callimachus,edwardsph/callimachus,edwardsph/callimachus,Thellmann/callimachus,jimmccusker/callimachus,jimmccusker/callimachus,edwardsph/callimachus,jimmccusker/callimachus,3-Round-Stones/callimachus,Thellmann/callimachus,jimmccusker/callim... |
ca2c53a499865c5d66643f33f6e1290820d5e408 | lib/cli/file-set-pipeline/log.js | lib/cli/file-set-pipeline/log.js | /**
* @author Titus Wormer
* @copyright 2015 Titus Wormer
* @license MIT
* @module mdast:cli:log
* @fileoverview Log a file context on successful completion.
*/
'use strict';
/*
* Dependencies.
*/
var report = require('vfile-reporter');
/**
* Output diagnostics to stdout(4) or stderr(4).
*
* @param {CLI}... | /**
* @author Titus Wormer
* @copyright 2015 Titus Wormer
* @license MIT
* @module mdast:cli:log
* @fileoverview Log a file context on successful completion.
*/
'use strict';
/*
* Dependencies.
*/
var chalk = require('chalk');
var report = require('vfile-reporter');
/**
* Output diagnostics to stdout(4) or... | Fix bug where colour on mdast(1) persisted | Fix bug where colour on mdast(1) persisted
The symbols used in the report to show the count of warnings, errors,
were coloured even when `color` was disabled on mdast(1).
| JavaScript | mit | chcokr/mdast,eush77/remark,eush77/remark,chcokr/mdast,yukkurisinai/mdast,yukkurisinai/mdast,tanzania82/remarks,wooorm/remark |
b99e47d5caa963bf322d6ca9c2c6af7a04338e31 | lib/group/handleJoinRequestId.js | lib/group/handleJoinRequestId.js | // Includes
var http = require('../util/http.js').func;
var getGeneralToken = require('../util/getGeneralToken.js').func;
// Args
exports.required = ['group', 'requestId', 'accept'];
exports.optional = ['jar'];
// Define
function handleJoinRequestId (jar, token, accept, requestId) {
var httpOpt = {
url: '//www.... | // Includes
var http = require('../util/http.js').func;
var getGeneralToken = require('../util/getGeneralToken.js').func;
// Args
exports.required = ['group', 'requestId', 'accept'];
exports.optional = ['jar'];
// Define
function handleJoinRequestId (jar, token, accept, requestId) {
var httpOpt = {
url: '//www.... | Add accept only for false, check result statusCode | Add accept only for false, check result statusCode
Technically the request is not sent with the `accept` option when you do want to accept the user. Not sure if this behavior is really important to match but people have been having problems with this function. | JavaScript | mit | sentanos/roblox-js,FroastJ/roblox-js |
8d8b1a12fd0dbdf691b1a054a167ff11cfe064f5 | js/apps/system/aardvark/clusterFrontend/js/routers/startApp.js | js/apps/system/aardvark/clusterFrontend/js/routers/startApp.js | /*jslint indent: 2, nomen: true, maxlen: 100, white: true, */
/*global window, $, Backbone, document */
(function() {
"use strict";
$.get("cluster/amIDispatcher", function(data) {
if (!data) {
var url = window.location.origin;
url += window.location.pathname;
url = url.replace("cluster", "i... | /*jslint indent: 2, nomen: true, maxlen: 100, white: true, */
/*global window, $, Backbone, document */
(function() {
"use strict";
$.get("cluster/amIDispatcher", function(data) {
if (!data) {
var url = window.location.origin;
url += window.location.pathname;
url = url.replace("cluster", "i... | Fix relocation of hash information on startup of cluster interface | Fix relocation of hash information on startup of cluster interface
| JavaScript | apache-2.0 | hkernbach/arangodb,joerg84/arangodb,CoDEmanX/ArangoDB,graetzer/arangodb,hkernbach/arangodb,baslr/ArangoDB,CoDEmanX/ArangoDB,fceller/arangodb,fceller/arangodb,baslr/ArangoDB,m0ppers/arangodb,jsteemann/arangodb,graetzer/arangodb,hkernbach/arangodb,wiltonlazary/arangodb,joerg84/arangodb,hkernbach/arangodb,CoDEmanX/ArangoD... |
80ebc1cc9618b429f0f51d527deea8663750987d | lib/ember-addon/blueprints/ember-cli-data-factory-guy/index.js | lib/ember-addon/blueprints/ember-cli-data-factory-guy/index.js | 'use strict';
var EOL = require('os').EOL;
module.exports = {
normalizeEntityName: function() {},
afterInstall: function() {
this.insertIntoFile('tests/.jshintrc',
' "FactoryGuy",', {
after: '"predef": [' + EOL
}
);
return this.addBowerPackageToProject('ember-data-factory-guy'... | 'use strict';
var EOL = require('os').EOL;
module.exports = {
normalizeEntityName: function() {},
afterInstall: function() {
return this.addBowerPackageToProject('ember-data-factory-guy', '~0.8.4');
}
};
| Remove FactoryGuy from js hint | Remove FactoryGuy from js hint
| JavaScript | mit | cristinawithout/ember-cli-data-factory-guy |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.