id stringlengths 34 124 | type stringclasses 4
values | prompt stringlengths 0 4.95k | response stringlengths 21 4.89k | source_lang stringclasses 3
values | target_lang stringclasses 2
values | repo stringclasses 75
values | path stringlengths 10 88 | license stringclasses 1
value | commit stringlengths 40 40 | stars int64 431 18.7k | source_url stringlengths 86 176 | line_start int64 1 214 | line_end int64 3 253 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:1:raw_corpus | raw_corpus | suite 'Attributes:', ->
test 'Add attribute (single with object argument)', ->
eq(
xml('test4', { headless: true })
.ele('node', 'element', {"first":"1", "second":"2"})
.att("third", "3")
.end()
'<test4><node first="1" second="2" third="3">element</node></test4>'
)
tes... | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 1 | 40 | ||
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
suite 'Attributes:', ->
test 'Add attribute (single with object argument)', ->
eq(
xml('test4', { headless: true })
.ele('node', 'element', {"first":"1", "second":"2"})
.att("third", "3")
.end()
'<test4><node first="1" ... | suite('Attributes:', function() {
test('Add attribute (single with object argument)', function() {
return eq(xml('test4', {
headless: true
}).ele('node', 'element', {
"first": "1",
"second": "2"
}).att("third", "3").end(), '<test4><node first="1" second="2" third="3">element</node></test... | CoffeeScript | JavaScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 1 | 40 |
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
suite('Attributes:', function() {
test('Add attribute (single with object argument)', function() {
return eq(xml('test4', {
headless: true
}).ele('node', 'element', {
"first": "1",
"second": "2"
}).att("third", "3").end(), '<test4><n... | suite 'Attributes:', ->
test 'Add attribute (single with object argument)', ->
eq(
xml('test4', { headless: true })
.ele('node', 'element', {"first":"1", "second":"2"})
.att("third", "3")
.end()
'<test4><node first="1" second="2" third="3">element</node></test4>'
)
tes... | JavaScript | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 1 | 40 |
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:1:completion | completion | suite 'Attributes:', ->
test 'Add attribute (single with object argument)', ->
eq(
xml('test4', { headless: true })
.ele('node', 'element', {"first":"1", "second":"2"})
.att("third", "3")
.end()
'<test4><node first="1" second="2" third="3">element</node></test4>'
)
tes... | xml('test4', { headless: true })
.ele('node', 'element', {"first":"1", "second":"2", "third":"3"})
.removeAttribute("second")
.end()
'<test4><node first="1" third="3">element</node></test4>'
)
test 'Remove multiple attributes', ->
eq(
xml('test4', { headless: true })
... | CoffeeScript | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 1 | 40 |
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:2:raw_corpus | raw_corpus | test 'Throw if null attribute (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att("first")
)
test 'Throw if null attribute name (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att(null, "first")
/Missing attribute name of element node/
)
test... | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 42 | 86 | ||
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
test 'Throw if null attribute (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att("first")
)
test 'Throw if null attribute name (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att(null, "first")
... | test('Throw if null attribute (att)', function() {
return err(function() {
return xml('test4', {
headless: true
}).ele('node').att("first");
});
});
test('Throw if null attribute name (att)', function() {
return err(function() {
return xml('test4', {
headless: true
}).ele('node').att(... | CoffeeScript | JavaScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 42 | 86 |
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
test('Throw if null attribute (att)', function() {
return err(function() {
return xml('test4', {
headless: true
}).ele('node').att("first");
});
});
test('Throw if null attribute name (att)', function() {
return err(function() {
return xml(... | test 'Throw if null attribute (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att("first")
)
test 'Throw if null attribute name (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att(null, "first")
/Missing attribute name of element node/
)
test... | JavaScript | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 42 | 86 |
oozcitak/xmlbuilder-js:test/basic/attributes.coffee:2:completion | completion | test 'Throw if null attribute (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att("first")
)
test 'Throw if null attribute name (att)', ->
err(
() -> xml('test4', { headless: true }).ele('node').att(null, "first")
/Missing attribute name of element node/
)
test... | test 'Skip if null attribute (ele)', ->
eq(
xml('test4', { headless: true, skipNullAttributes: true })
.ele('node', 'element', {"first":null, 'second': '2'})
.end()
'<test4><node second="2">element</node></test4>'
)
test 'Skip if null attribute (att)', ->
eq(
xml('test4'... | CoffeeScript | CoffeeScript | oozcitak/xmlbuilder-js | test/basic/attributes.coffee | MIT | e0e2ce57b49ef63f06840d517d31b2c08b473199 | 926 | https://github.com/oozcitak/xmlbuilder-js/blob/e0e2ce57b49ef63f06840d517d31b2c08b473199/test/basic/attributes.coffee | 42 | 86 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare variable with... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare variable with... | return variable
# Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
if quick
(engine.replaced ||= {})[variable.name] = variable
else
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.d... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:2:raw_corpus | raw_corpus | '+': (left, right) ->
return left + right
'-': (left, right) ->
return left - right
'*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 51 | 63 | ||
gss/engine:src/commands/Variable.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
'+': (left, right) ->
return left + right
'-': (left, right) ->
return left - right
'*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable
``` | ({
'+': function(left, right) {
return left + right;
},
'-': function(left, right) {
return left - right;
},
'*': function(left, right) {
return left * right;
},
'/': function(left, right) {
return left / right;
}
});
module.exports = Variable; | CoffeeScript | JavaScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 51 | 63 |
gss/engine:src/commands/Variable.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
({
'+': function(left, right) {
return left + right;
},
'-': function(left, right) {
return left - right;
},
'*': function(left, right) {
return left * right;
},
'/': function(left, right) {
return left / right;
}
});
module.exports... | '+': (left, right) ->
return left + right
'-': (left, right) ->
return left - right
'*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable | JavaScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 51 | 63 |
gss/engine:src/commands/Variable.coffee:2:completion | completion | '+': (left, right) ->
return left + right
'-': (left, right) ->
return left - right | '*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 31938f86e04f67ada173275db8f0e673655a12e9 | 2,854 | https://github.com/gss/engine/blob/31938f86e04f67ada173275db8f0e673655a12e9/src/commands/Variable.coffee | 51 | 63 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 6b055796e2c1a026dd9de5a4c62d00422ef0bc98 | 2,854 | https://github.com/gss/engine/blob/6b055796e2c1a026dd9de5a4c62d00422ef0bc98/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | return variable
# Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
if quick
(engine.replaced ||= {})[variable.name] = variable
else
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.d... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 6b055796e2c1a026dd9de5a4c62d00422ef0bc98 | 2,854 | https://github.com/gss/engine/blob/6b055796e2c1a026dd9de5a4c62d00422ef0bc98/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 2ea0de755ae8cfef64b1d0b0612f8c1096930c12 | 2,854 | https://github.com/gss/engine/blob/2ea0de755ae8cfef64b1d0b0612f8c1096930c12/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | return variable
# Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
if quick
(engine.replaced ||= {})[variable.name] = variable
else
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.d... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 2ea0de755ae8cfef64b1d0b0612f8c1096930c12 | 2,854 | https://github.com/gss/engine/blob/2ea0de755ae8cfef64b1d0b0612f8c1096930c12/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 5b9cdc8206e187bfd07869d3f159fc262c27b575 | 2,854 | https://github.com/gss/engine/blob/5b9cdc8206e187bfd07869d3f159fc262c27b575/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending... | var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((value = ascending != null ? (ref = ascending.values) != nu... | CoffeeScript | JavaScript | gss/engine | src/commands/Variable.coffee | MIT | 5b9cdc8206e187bfd07869d3f159fc262c27b575 | 2,854 | https://github.com/gss/engine/blob/5b9cdc8206e187bfd07869d3f159fc262c27b575/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((val... | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | JavaScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 5b9cdc8206e187bfd07869d3f159fc262c27b575 | 2,854 | https://github.com/gss/engine/blob/5b9cdc8206e187bfd07869d3f159fc262c27b575/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | return variable
# Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
if quick
(engine.replaced ||= {})[variable.name] = variable
else
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.d... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 5b9cdc8206e187bfd07869d3f159fc262c27b575 | 2,854 | https://github.com/gss/engine/blob/5b9cdc8206e187bfd07869d3f159fc262c27b575/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | d3179d65e07f4c8b8a25cd5f21abb43650cd19b0 | 2,854 | https://github.com/gss/engine/blob/d3179d65e07f4c8b8a25cd5f21abb43650cd19b0/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending... | var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((value = ascending != null ? (ref = ascending.values) != nu... | CoffeeScript | JavaScript | gss/engine | src/commands/Variable.coffee | MIT | d3179d65e07f4c8b8a25cd5f21abb43650cd19b0 | 2,854 | https://github.com/gss/engine/blob/d3179d65e07f4c8b8a25cd5f21abb43650cd19b0/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((val... | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | JavaScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | d3179d65e07f4c8b8a25cd5f21abb43650cd19b0 | 2,854 | https://github.com/gss/engine/blob/d3179d65e07f4c8b8a25cd5f21abb43650cd19b0/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | return variable
# Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
if quick
(engine.replaced ||= {})[variable.name] = variable
else
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.d... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | d3179d65e07f4c8b8a25cd5f21abb43650cd19b0 | 2,854 | https://github.com/gss/engine/blob/d3179d65e07f4c8b8a25cd5f21abb43650cd19b0/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:raw_corpus | raw_corpus | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 1 | 50 | ||
gss/engine:src/commands/Variable.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending... | var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((value = ascending != null ? (ref = ascending.values) != nu... | CoffeeScript | JavaScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var Command, Variable;
Command = require('../concepts/Command');
Variable = (function() {
class Variable extends Command {
constructor() {}
before(args, engine, operation, continuation, scope, ascender, ascending) {
var ref, value;
if ((val... | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | JavaScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:1:completion | completion | Command = require('../concepts/Command')
class Variable extends Command
type: 'Variable'
signature: [
property: ['String']
]
constructor: ->
before: (args, engine, operation, continuation, scope, ascender, ascending) ->
if (value = ascending?.values?[args[0]])?
return value
# Declare vari... | # Undeclare variable in given domain, outputs "null" once
undeclare: (engine, variable, quick) ->
(engine.nullified ||= {})[variable.name] = variable
if engine.declared?[variable.name]
delete engine.declared[variable.name]
delete engine.values[variable.name]
engine.nullify(variable)
engine... | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 1 | 50 |
gss/engine:src/commands/Variable.coffee:2:raw_corpus | raw_corpus | '*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 51 | 58 | ||
gss/engine:src/commands/Variable.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
'*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable
``` | ({
'*': function(left, right) {
return left * right;
},
'/': function(left, right) {
return left / right;
}
});
module.exports = Variable; | CoffeeScript | JavaScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 51 | 58 |
gss/engine:src/commands/Variable.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
({
'*': function(left, right) {
return left * right;
},
'/': function(left, right) {
return left / right;
}
});
module.exports = Variable;
``` | '*': (left, right) ->
return left * right
'/': (left, right) ->
return left / right
module.exports = Variable | JavaScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 51 | 58 |
gss/engine:src/commands/Variable.coffee:2:completion | completion | '*': (left, right) ->
return left * right | '/': (left, right) ->
return left / right
module.exports = Variable | CoffeeScript | CoffeeScript | gss/engine | src/commands/Variable.coffee | MIT | 527308fd09ab6b18a30ad7b6194f0fd00f872647 | 2,854 | https://github.com/gss/engine/blob/527308fd09ab6b18a30ad7b6194f0fd00f872647/src/commands/Variable.coffee | 51 | 58 |
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:raw_corpus | raw_corpus | class ParseMore extends Error
constructor: (message, parsedLine, snippet) ->
super message
@message = message
@parsedLine = parsedLine
@snippet = snippet
toString: ->
if @parsedLine? and @snippet?
return '<ParseMore> ' + @message + ' (line ' + @parsedLine + ... | CoffeeScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | efe8ce18704ae43383e4177aa7de1a2619bd4e67 | 887 | https://github.com/jeremyfa/yaml.js/blob/efe8ce18704ae43383e4177aa7de1a2619bd4e67/src/Exception/ParseMore.coffee | 1 | 15 | ||
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
class ParseMore extends Error
constructor: (message, parsedLine, snippet) ->
super message
@message = message
@parsedLine = parsedLine
@snippet = snippet
toString: ->
if @parsedLine? and @snippet?
retu... | var ParseMore;
ParseMore = class ParseMore extends Error {
constructor(message, parsedLine, snippet) {
super(message);
this.message = message;
this.parsedLine = parsedLine;
this.snippet = snippet;
}
toString() {
if ((this.parsedLine != null) && (this.snippet != null)) {
return '<ParseM... | CoffeeScript | JavaScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | efe8ce18704ae43383e4177aa7de1a2619bd4e67 | 887 | https://github.com/jeremyfa/yaml.js/blob/efe8ce18704ae43383e4177aa7de1a2619bd4e67/src/Exception/ParseMore.coffee | 1 | 15 |
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
var ParseMore;
ParseMore = class ParseMore extends Error {
constructor(message, parsedLine, snippet) {
super(message);
this.message = message;
this.parsedLine = parsedLine;
this.snippet = snippet;
}
toString() {
if ((this.parsedLine != n... | class ParseMore extends Error
constructor: (message, parsedLine, snippet) ->
super message
@message = message
@parsedLine = parsedLine
@snippet = snippet
toString: ->
if @parsedLine? and @snippet?
return '<ParseMore> ' + @message + ' (line ' + @parsedLine + ... | JavaScript | CoffeeScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | efe8ce18704ae43383e4177aa7de1a2619bd4e67 | 887 | https://github.com/jeremyfa/yaml.js/blob/efe8ce18704ae43383e4177aa7de1a2619bd4e67/src/Exception/ParseMore.coffee | 1 | 15 |
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:completion | completion | class ParseMore extends Error
constructor: (message, parsedLine, snippet) ->
super message
@message = message
@parsedLine = parsedLine
@snippet = snippet | toString: ->
if @parsedLine? and @snippet?
return '<ParseMore> ' + @message + ' (line ' + @parsedLine + ': \'' + @snippet + '\')'
else
return '<ParseMore> ' + @message
module.exports = ParseMore | CoffeeScript | CoffeeScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | efe8ce18704ae43383e4177aa7de1a2619bd4e67 | 887 | https://github.com/jeremyfa/yaml.js/blob/efe8ce18704ae43383e4177aa7de1a2619bd4e67/src/Exception/ParseMore.coffee | 1 | 15 |
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:raw_corpus | raw_corpus | class ParseMore extends Error
constructor: (@message, @parsedLine, @snippet) ->
toString: ->
if @parsedLine? and @snippet?
return '<ParseMore> ' + @message + ' (line ' + @parsedLine + ': \'' + @snippet + '\')'
else
return '<ParseMore> ' + @message
module.exports = Pars... | CoffeeScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | 1e8d6dd845e0f59dd88c28615ad8702e4a59c0d9 | 887 | https://github.com/jeremyfa/yaml.js/blob/1e8d6dd845e0f59dd88c28615ad8702e4a59c0d9/src/Exception/ParseMore.coffee | 1 | 11 | ||
jeremyfa/yaml.js:src/Exception/ParseMore.coffee:1:completion | completion | class ParseMore extends Error
constructor: (@message, @parsedLine, @snippet) ->
toString: -> | if @parsedLine? and @snippet?
return '<ParseMore> ' + @message + ' (line ' + @parsedLine + ': \'' + @snippet + '\')'
else
return '<ParseMore> ' + @message
module.exports = ParseMore | CoffeeScript | CoffeeScript | jeremyfa/yaml.js | src/Exception/ParseMore.coffee | MIT | 1e8d6dd845e0f59dd88c28615ad8702e4a59c0d9 | 887 | https://github.com/jeremyfa/yaml.js/blob/1e8d6dd845e0f59dd88c28615ad8702e4a59c0d9/src/Exception/ParseMore.coffee | 1 | 11 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:1:raw_corpus | raw_corpus | exports.mapFieldToDefaultMethod = (field) ->
switch field
when '_roomId' then @defaultRoomId
when 'url' then @defaultUrl
when 'token' then @defaultToken
when 'events' then @defaultEvents
when 'title' then @defaultTitle
when 'description' then @defaultDescription
when 'iconUrl' then @defaul... | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 7 | 17 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.mapFieldToDefaultMethod = (field) ->
switch field
when '_roomId' then @defaultRoomId
when 'url' then @defaultUrl
when 'token' then @defaultToken
when 'events' then @defaultEvents
when 'title' then @defaultTitle
when 'description'... | exports.mapFieldToDefaultMethod = function(field) {
switch (field) {
case '_roomId':
return this.defaultRoomId;
case 'url':
return this.defaultUrl;
case 'token':
return this.defaultToken;
case 'events':
return this.defaultEvents;
case 'title':
return this.defaultTitle... | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 7 | 17 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.mapFieldToDefaultMethod = function(field) {
switch (field) {
case '_roomId':
return this.defaultRoomId;
case 'url':
return this.defaultUrl;
case 'token':
return this.defaultToken;
case 'events':
return this.defaultE... | exports.mapFieldToDefaultMethod = (field) ->
switch field
when '_roomId' then @defaultRoomId
when 'url' then @defaultUrl
when 'token' then @defaultToken
when 'events' then @defaultEvents
when 'title' then @defaultTitle
when 'description' then @defaultDescription
when 'iconUrl' then @defaul... | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 7 | 17 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:1:completion | completion | exports.mapFieldToDefaultMethod = (field) ->
switch field
when '_roomId' then @defaultRoomId
when 'url' then @defaultUrl
when 'token' then @defaultToken | when 'events' then @defaultEvents
when 'title' then @defaultTitle
when 'description' then @defaultDescription
when 'iconUrl' then @defaultIconUrl
when 'webhookUrl' then @defaultWebhookUrl
else throw new Error "map needs update" | CoffeeScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 7 | 17 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:2:raw_corpus | raw_corpus | exports.mapFieldToDefinedMethod = (field) ->
switch field
when '_roomId' then @definedRoomId
when 'url' then @definedUrl
when 'token' then @definedToken
when 'events' then @definedEvents
when 'title' then @definedTitle
when 'description' then @definedDescription
when 'iconUrl' then @define... | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 19 | 29 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:2:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.mapFieldToDefinedMethod = (field) ->
switch field
when '_roomId' then @definedRoomId
when 'url' then @definedUrl
when 'token' then @definedToken
when 'events' then @definedEvents
when 'title' then @definedTitle
when 'description'... | exports.mapFieldToDefinedMethod = function(field) {
switch (field) {
case '_roomId':
return this.definedRoomId;
case 'url':
return this.definedUrl;
case 'token':
return this.definedToken;
case 'events':
return this.definedEvents;
case 'title':
return this.definedTitle... | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 19 | 29 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:2:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.mapFieldToDefinedMethod = function(field) {
switch (field) {
case '_roomId':
return this.definedRoomId;
case 'url':
return this.definedUrl;
case 'token':
return this.definedToken;
case 'events':
return this.definedE... | exports.mapFieldToDefinedMethod = (field) ->
switch field
when '_roomId' then @definedRoomId
when 'url' then @definedUrl
when 'token' then @definedToken
when 'events' then @definedEvents
when 'title' then @definedTitle
when 'description' then @definedDescription
when 'iconUrl' then @define... | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 19 | 29 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:2:completion | completion | exports.mapFieldToDefinedMethod = (field) ->
switch field
when '_roomId' then @definedRoomId
when 'url' then @definedUrl
when 'token' then @definedToken | when 'events' then @definedEvents
when 'title' then @definedTitle
when 'description' then @definedDescription
when 'iconUrl' then @definedIconUrl
when 'webhookUrl' then @definedWebhookUrl
else throw new Error "map needs update" | CoffeeScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 19 | 29 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:3:raw_corpus | raw_corpus | exports.mapFieldToUpdatedMethod = (field) ->
switch field
when '_roomId' then @updatedRoomId
when 'url' then @updatedUrl
when 'token' then @updatedToken
when 'events' then @updatedEvents
when 'title' then @updatedTitle
when 'description' then @updatedDescription
when 'iconUrl' then @update... | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 31 | 43 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:3:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.mapFieldToUpdatedMethod = (field) ->
switch field
when '_roomId' then @updatedRoomId
when 'url' then @updatedUrl
when 'token' then @updatedToken
when 'events' then @updatedEvents
when 'title' then @updatedTitle
when 'description'... | exports.mapFieldToUpdatedMethod = function(field) {
switch (field) {
case '_roomId':
return this.updatedRoomId;
case 'url':
return this.updatedUrl;
case 'token':
return this.updatedToken;
case 'events':
return this.updatedEvents;
case 'title':
return this.updatedTitle... | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 31 | 43 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:3:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.mapFieldToUpdatedMethod = function(field) {
switch (field) {
case '_roomId':
return this.updatedRoomId;
case 'url':
return this.updatedUrl;
case 'token':
return this.updatedToken;
case 'events':
return this.updatedE... | exports.mapFieldToUpdatedMethod = (field) ->
switch field
when '_roomId' then @updatedRoomId
when 'url' then @updatedUrl
when 'token' then @updatedToken
when 'events' then @updatedEvents
when 'title' then @updatedTitle
when 'description' then @updatedDescription
when 'iconUrl' then @update... | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 31 | 43 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:3:completion | completion | exports.mapFieldToUpdatedMethod = (field) ->
switch field
when '_roomId' then @updatedRoomId
when 'url' then @updatedUrl
when 'token' then @updatedToken
when 'events' then @updatedEvents | when 'title' then @updatedTitle
when 'description' then @updatedDescription
when 'iconUrl' then @updatedIconUrl
when 'webhookUrl' then @updateWebhookUrl
else throw new Error "map needs update"
# _roomId | CoffeeScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 31 | 43 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:6:raw_corpus | raw_corpus | exports.updatedRoomId = (a, b) ->
a isnt b
# url | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 51 | 54 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:6:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedRoomId = (a, b) ->
a isnt b
# url
``` | exports.updatedRoomId = function(a, b) {
return a !== b;
};
// url | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 51 | 54 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:6:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedRoomId = function(a, b) {
return a !== b;
};
// url
``` | exports.updatedRoomId = (a, b) ->
a isnt b
# url | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 51 | 54 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:9:raw_corpus | raw_corpus | exports.updatedUrl = (a, b) ->
a isnt b
# token | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 62 | 65 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:9:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedUrl = (a, b) ->
a isnt b
# token
``` | exports.updatedUrl = function(a, b) {
return a !== b;
};
// token | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 62 | 65 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:9:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedUrl = function(a, b) {
return a !== b;
};
// token
``` | exports.updatedUrl = (a, b) ->
a isnt b
# token | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 62 | 65 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:10:raw_corpus | raw_corpus | exports.defaultToken = (inte, settings) ->
if inte?
return inte.get('token')
# or maybe need to generate one
tokenField = fieldsReader.getField settings.fields, 'token'
if tokenField.autoGen
shortid.generate()
else
undefined | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 67 | 75 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:10:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.defaultToken = (inte, settings) ->
if inte?
return inte.get('token')
# or maybe need to generate one
tokenField = fieldsReader.getField settings.fields, 'token'
if tokenField.autoGen
shortid.generate()
else
undefined
``` | exports.defaultToken = function(inte, settings) {
var tokenField;
if (inte != null) {
return inte.get('token');
}
// or maybe need to generate one
tokenField = fieldsReader.getField(settings.fields, 'token');
if (tokenField.autoGen) {
return shortid.generate();
} else {
return void 0;
}
}; | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 67 | 75 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:10:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.defaultToken = function(inte, settings) {
var tokenField;
if (inte != null) {
return inte.get('token');
}
// or maybe need to generate one
tokenField = fieldsReader.getField(settings.fields, 'token');
if (tokenField.autoGen) {
return sho... | exports.defaultToken = (inte, settings) ->
if inte?
return inte.get('token')
# or maybe need to generate one
tokenField = fieldsReader.getField settings.fields, 'token'
if tokenField.autoGen
shortid.generate()
else
undefined | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 67 | 75 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:10:completion | completion | exports.defaultToken = (inte, settings) ->
if inte?
return inte.get('token')
# or maybe need to generate one | tokenField = fieldsReader.getField settings.fields, 'token'
if tokenField.autoGen
shortid.generate()
else
undefined | CoffeeScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 67 | 75 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:12:raw_corpus | raw_corpus | exports.updatedToken = (a, b) ->
a isnt b
# webhookUrl | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 80 | 83 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:12:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedToken = (a, b) ->
a isnt b
# webhookUrl
``` | exports.updatedToken = function(a, b) {
return a !== b;
};
// webhookUrl | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 80 | 83 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:12:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedToken = function(a, b) {
return a !== b;
};
// webhookUrl
``` | exports.updatedToken = (a, b) ->
a isnt b
# webhookUrl | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 80 | 83 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:13:raw_corpus | raw_corpus | exports.defaultWebhookUrl = (inte, settings) ->
if inte?
return inte.get('webhookUrl') | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 85 | 87 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:13:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.defaultWebhookUrl = (inte, settings) ->
if inte?
return inte.get('webhookUrl')
``` | exports.defaultWebhookUrl = function(inte, settings) {
if (inte != null) {
return inte.get('webhookUrl');
}
}; | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 85 | 87 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:13:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.defaultWebhookUrl = function(inte, settings) {
if (inte != null) {
return inte.get('webhookUrl');
}
};
``` | exports.defaultWebhookUrl = (inte, settings) ->
if inte?
return inte.get('webhookUrl') | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 85 | 87 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:15:raw_corpus | raw_corpus | exports.updateWebhookUrl = (a, b) ->
a isnt b
# events | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 92 | 95 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:15:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updateWebhookUrl = (a, b) ->
a isnt b
# events
``` | exports.updateWebhookUrl = function(a, b) {
return a !== b;
};
// events | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 92 | 95 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:15:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updateWebhookUrl = function(a, b) {
return a !== b;
};
// events
``` | exports.updateWebhookUrl = (a, b) ->
a isnt b
# events | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 92 | 95 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:18:raw_corpus | raw_corpus | exports.updatedEvents = (a, b) ->
not (isEqual a, b)
# title | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 103 | 106 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:18:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedEvents = (a, b) ->
not (isEqual a, b)
# title
``` | exports.updatedEvents = function(a, b) {
return !(isEqual(a, b));
};
// title | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 103 | 106 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:18:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedEvents = function(a, b) {
return !(isEqual(a, b));
};
// title
``` | exports.updatedEvents = (a, b) ->
not (isEqual a, b)
# title | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 103 | 106 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:21:raw_corpus | raw_corpus | exports.updatedTitle = (a, b) ->
a isnt b
# description | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 114 | 117 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:21:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedTitle = (a, b) ->
a isnt b
# description
``` | exports.updatedTitle = function(a, b) {
return a !== b;
};
// description | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 114 | 117 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:21:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedTitle = function(a, b) {
return a !== b;
};
// description
``` | exports.updatedTitle = (a, b) ->
a isnt b
# description | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 114 | 117 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:23:raw_corpus | raw_corpus | exports.definedDescription = (description) ->
# description is optional
return true | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 122 | 124 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:23:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.definedDescription = (description) ->
# description is optional
return true
``` | exports.definedDescription = function(description) {
// description is optional
return true;
}; | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 122 | 124 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:23:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.definedDescription = function(description) {
// description is optional
return true;
};
``` | exports.definedDescription = (description) ->
# description is optional
return true | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 122 | 124 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:24:raw_corpus | raw_corpus | exports.updatedDescription = (a, b) ->
a isnt b
# iconUrl | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 126 | 129 | ||
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:24:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
exports.updatedDescription = (a, b) ->
a isnt b
# iconUrl
``` | exports.updatedDescription = function(a, b) {
return a !== b;
};
// iconUrl | CoffeeScript | JavaScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 126 | 129 |
jianliaoim/talk-os:talk-web/client/util/inte-validator.coffee:24:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
exports.updatedDescription = function(a, b) {
return a !== b;
};
// iconUrl
``` | exports.updatedDescription = (a, b) ->
a isnt b
# iconUrl | JavaScript | CoffeeScript | jianliaoim/talk-os | talk-web/client/util/inte-validator.coffee | MIT | 2545c4497865779a55762e03963a39237df9046b | 2,703 | https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/util/inte-validator.coffee | 126 | 129 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:raw_corpus | raw_corpus | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 7296aa6bc321370c1b92de005c9b55b9e1365596 | 2,055 | https://github.com/soyjavi/QuoJS/blob/7296aa6bc321370c1b92de005c9b55b9e1365596/source/quo.gestures.pinch.coffee | 1 | 50 | ||
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pin... | /*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],
handler: (function(base) {
var GAP, _check, _dis... | CoffeeScript | JavaScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 7296aa6bc321370c1b92de005c9b55b9e1365596 | 2,055 | https://github.com/soyjavi/QuoJS/blob/7296aa6bc321370c1b92de005c9b55b9e1365596/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
/*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],... | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | JavaScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 7296aa6bc321370c1b92de005c9b55b9e1365596 | 2,055 | https://github.com/soyjavi/QuoJS/blob/7296aa6bc321370c1b92de005c9b55b9e1365596/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:completion | completion | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | move = (target, data) ->
if _start and data.length is 2
distance = _distance data[0], data[1]
_last = touches: data, delta: (distance - _start)
_check(true)
cancel = end = (target, data) ->
if _start and _last
_check(false)
_start = null
_last = null
... | CoffeeScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 7296aa6bc321370c1b92de005c9b55b9e1365596 | 2,055 | https://github.com/soyjavi/QuoJS/blob/7296aa6bc321370c1b92de005c9b55b9e1365596/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:raw_corpus | raw_corpus | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | ef4a79667bc693ccc1f8e75dcb902652dc0dca28 | 2,055 | https://github.com/soyjavi/QuoJS/blob/ef4a79667bc693ccc1f8e75dcb902652dc0dca28/source/quo.gestures.pinch.coffee | 1 | 50 | ||
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pin... | /*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],
handler: (function(base) {
var GAP, _check, _dis... | CoffeeScript | JavaScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | ef4a79667bc693ccc1f8e75dcb902652dc0dca28 | 2,055 | https://github.com/soyjavi/QuoJS/blob/ef4a79667bc693ccc1f8e75dcb902652dc0dca28/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
/*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],... | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | JavaScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | ef4a79667bc693ccc1f8e75dcb902652dc0dca28 | 2,055 | https://github.com/soyjavi/QuoJS/blob/ef4a79667bc693ccc1f8e75dcb902652dc0dca28/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:completion | completion | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Javier Jimenez Villar <javi@tapquo.com> || @soyjavi
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | move = (target, data) ->
if _start and data.length is 2
distance = _distance data[0], data[1]
_last = touches: data, delta: (distance - _start)
_check(true)
end = (target, data) ->
if _start and _last
_check(false)
_start = null
_last = null
_distanc... | CoffeeScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | ef4a79667bc693ccc1f8e75dcb902652dc0dca28 | 2,055 | https://github.com/soyjavi/QuoJS/blob/ef4a79667bc693ccc1f8e75dcb902652dc0dca28/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:raw_corpus | raw_corpus | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 1ae37dec9559e15872daa8be159849e329456005 | 2,055 | https://github.com/soyjavi/QuoJS/blob/1ae37dec9559e15872daa8be159849e329456005/source/quo.gestures.pinch.coffee | 1 | 50 | ||
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pin... | /*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],
handler: (function(base) {
var GAP, _check, _dis... | CoffeeScript | JavaScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 1ae37dec9559e15872daa8be159849e329456005 | 2,055 | https://github.com/soyjavi/QuoJS/blob/1ae37dec9559e15872daa8be159849e329456005/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
/*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: ["pinch", "pinching", "pinchIn", "pinchOut"],... | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | JavaScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 1ae37dec9559e15872daa8be159849e329456005 | 2,055 | https://github.com/soyjavi/QuoJS/blob/1ae37dec9559e15872daa8be159849e329456005/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:completion | completion | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@namespace Quo.Gestures
@class Pinch
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : ["pinch", "pinching", "pinchIn", "pinchOut"]
handler : do (base = Quo.Gestures) ->
GAP ... | move = (target, data) ->
if _start and data.length is 2
distance = _distance data[0], data[1]
_last = touches: data, delta: (distance - _start)
_check(true)
end = (target, data) ->
if _start and _last
_check(false)
_start = null
_last = null
_distanc... | CoffeeScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 1ae37dec9559e15872daa8be159849e329456005 | 2,055 | https://github.com/soyjavi/QuoJS/blob/1ae37dec9559e15872daa8be159849e329456005/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:raw_corpus | raw_corpus | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : "pinch,pinching,pinchIn,pinchOut".split(",")
handler : do (gm = Quo.Gestures) ->
TRIGGER_PIXELS = 20
_target = null
... | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 3e94097849c8265b1e1f85eded77562ec42e7672 | 2,055 | https://github.com/soyjavi/QuoJS/blob/3e94097849c8265b1e1f85eded77562ec42e7672/source/quo.gestures.pinch.coffee | 1 | 50 | ||
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:coffee_to_js | coffee_to_js | Convert this CoffeeScript to JavaScript.
```coffeescript
###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : "pinch,pinching,pinchIn,pinchOut".split(",")
handler : do (gm = Quo.Gestu... | /*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: "pinch,pinching,pinchIn,pinchOut".split(","),
handler: (function(gm) {
var TRIGGER_PIXELS, _check, _distance, _last, _start, _target... | CoffeeScript | JavaScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 3e94097849c8265b1e1f85eded77562ec42e7672 | 2,055 | https://github.com/soyjavi/QuoJS/blob/3e94097849c8265b1e1f85eded77562ec42e7672/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:js_to_coffee | js_to_coffee | Convert this JavaScript to CoffeeScript.
```javascript
/*
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
*/
"use strict";
Quo.Gestures.add({
name: "pinch",
events: "pinch,pinching,pinchIn,pinchOut".split(","),
handler: (function(gm) {
var TR... | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : "pinch,pinching,pinchIn,pinchOut".split(",")
handler : do (gm = Quo.Gestures) ->
TRIGGER_PIXELS = 20
_target = null
... | JavaScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 3e94097849c8265b1e1f85eded77562ec42e7672 | 2,055 | https://github.com/soyjavi/QuoJS/blob/3e94097849c8265b1e1f85eded77562ec42e7672/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:completion | completion | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.Gestures.add
name : "pinch"
events : "pinch,pinching,pinchIn,pinchOut".split(",")
handler : do (gm = Quo.Gestures) ->
TRIGGER_PIXELS = 20
_target = null
... | if _start and data.length is 2
distance = _distance data[0], data[1]
_last = touches: data, delta: (distance - _start)
_check(true)
end = (target, data) ->
if _start and _last
_check(false)
_start = null
_last = null
_distance = (A, B) ->
Math.sqrt((... | CoffeeScript | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | 3e94097849c8265b1e1f85eded77562ec42e7672 | 2,055 | https://github.com/soyjavi/QuoJS/blob/3e94097849c8265b1e1f85eded77562ec42e7672/source/quo.gestures.pinch.coffee | 1 | 50 |
soyjavi/QuoJS:source/quo.gestures.pinch.coffee:1:raw_corpus | raw_corpus | ###
Quo Pinch Gestures: pinch, pinching, pinchIn, pinchOut
@author Ignacio Olalde Ramos <ina@tapquo.com> || @piniphone
###
"use strict"
Quo.gesture.add
name : "pinch"
events : "pinch,pinching,pinchIn,pinchOut".split(",")
handler : do (gm = Quo.gesture) ->
TRIGGER_PIXELS = 20
_target = null
_s... | CoffeeScript | soyjavi/QuoJS | source/quo.gestures.pinch.coffee | MIT | ff24a23aa557eabf4db8c0adbe9712f8a960293d | 2,055 | https://github.com/soyjavi/QuoJS/blob/ff24a23aa557eabf4db8c0adbe9712f8a960293d/source/quo.gestures.pinch.coffee | 1 | 50 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.