Skip to content

Instantly share code, notes, and snippets.

$ ->
class AjaxDateUpdater
constructor: (@id, @url) ->
$(@id).hover @hover_in, @hover_out
@old = ""
@has_focus = false
hover_in: (ev) =>
return if @has_focus
$el = $ ev.target
require 'shelljs/global'
require! <[gaze charm]>
charm = charm!
charm.pipe process.stdout
task 'build' 'Compile *.moon files to lib/*.lua' !->
charm.write (exec 'moonc -t lib *.moon' {+silent}).output
task 'test' 'Run unit tests with busted.', !->
@Demo.module "Entities", (Entities, App, Backbone, Marionette, $, _) ->
App.reqres.setHandler "users:entities", ->
promise = $.Deferred()
App.request("socket:get:users").then
(value) -> promise.resolve(value)
promise.promise()
@vendethiel
vendethiel / es6-map.js
Last active July 10, 2024 15:12 — forked from heath/es6-map.js
Map in different languages
[1,2,3].map((n)=> n*2)
class @MediaItemsAPI
constructor: (options = {}) ->
console.log this.options
# this.options = _.extend this.options, options
if not this.key? and not this.options.key?
Meteor.Erros.throw "No API key has been set. Please set and API key and try again."
@key = options.key
@services = options.services
@extensions = options.extensions
<?php
/**
*
* @package Icy Phoenix
* @version $Id$
* @copyright (c) 2008 Icy Phoenix
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/

Mods ajoutés dans l'EzArena

File Attachment Mod 2.4.5 - Acyd Burn

Permet d'attacher des fichiers aux messages Addons :

  • Addon Attach mod stats in Userlist/profile - Informpro
  • Addon thumbnail settings 1.1.1 - rxu

Fix Session Error 1.0.1 - TerraFrost

Réduit les chances d'avoir une erreur type "Error creating new session"

<?php
class XkcdParser
{
/* @var array $last Data of the latest comic */
private $last;
/* @var int $max Latest comic data ID */
private $max;
public function __construct()
(use '[clojure.core.match :only [match]])
(defn evaluate [env [sym x y]]
(match [sym]
['Number] x
['Add] (+ (evaluate env x) (evaluate env y))
['Multiply] (* (evaluate env x) (evaluate env y))
['Variable] (env x)))
(def environment {"a" 3, "b" 4, "c" 5})