Skip to content

Instantly share code, notes, and snippets.

View leobalter's full-sized avatar
💭
status

Leo Balter leobalter

💭
status
View GitHub Profile
@rwaldron
rwaldron / index.html
Created September 3, 2012 02:34 — forked from visnup/index.html
playing with a very minimal one page site
<pre>
# Just Markdown, Yo.
So, I wanted to try to write the simplest webpage possible, [Max Ogden][1]
style. If you have JavaScript, you get something pretty. If not, then you see
[Markdown][2] text, which is fine too.
[1]: http://maxogden.com
[2]: http://daringfireball.net/projects/markdown/
</pre>
(function( exports ) {
function EventEmitter() {}
EventEmitter.prototype.emit = function() {
var type, handlers, args, listeners;
type = arguments[0];
args = [].slice.call( arguments, 1 );
@davidsonfellipe
davidsonfellipe / gist:4601852
Last active December 11, 2015 12:38
CSS FTW

#CSS FTW My way to face the challenge: Maintainable + Efficient + Optimized

##General

  • YSlow + Page Speed (Performance Rules)…
  • CSSLint Rules…
  • Don’t use too many web fonts talk to your designer, and explain the impact of loading many sources.

##Tools

@millermedeiros
millermedeiros / osx_setup.md
Last active May 7, 2024 08:01
Mac OS X setup

Setup Mac OS X

I've done the same process every couple years since 2013 (Mountain Lion, Mavericks, High Sierra, Catalina) and I updated the Gist each time I've done it.

I kinda regret for not using something like Boxen (or anything similar) to automate the process, but TBH I only actually needed to these steps once every couple years...

@mikeal
mikeal / gist:7897206
Created December 10, 2013 20:01
Animals for slaughter.

Children are created, raised, cared for and we hope that they will live a long and proud life only to end long after their creator's has ended. They are their creator's legacy.

Your code is not your child, it is an animal raised for slaughter. Your code will die. It will die before your death. Your code's entire purpose is to die. Your code enables some new function and if successful that new function will grow, it will mature, it will eventually outlive the usefullness you've provided. When successful your code creates value that outlives it and the faster the better. When unsuccessful a mercy killing is most appropriate.

Believing that our code is our children makes us territorial, protective. Nobody is allowed to kill it, only improve it. The idea that our code can be perfect, that it can change to handle so many new concerns leads to the birth of frameworks and plugin systems. These systems brutalize creativity by forcing new value to conform to the standards of our aging children.

@sindresorhus
sindresorhus / post-merge
Last active May 2, 2024 03:18
git hook to run a command after `git pull` if a specified file was changed.In this example it's used to run `npm install` if package.json changed and `bower install` if `bower.json` changed.Run `chmod +x post-merge` to make it executable then put it into `.git/hooks/`.
#!/usr/bin/env bash
# MIT © Sindre Sorhus - sindresorhus.com
# git hook to run a command after `git pull` if a specified file was changed
# Run `chmod +x post-merge` to make it executable then put it into `.git/hooks/`.
changed_files="$(git diff-tree -r --name-only --no-commit-id ORIG_HEAD HEAD)"
check_run() {
echo "$changed_files" | grep --quiet "$1" && eval "$2"
@guifromrio
guifromrio / front-end-brasil.md
Last active July 15, 2017 12:20
O estado da comunidade brasileira de front end

Para onde caminha a comunidade brasileira de front end?

Hoje algo cômico e surreal aconteceu na comunidade FrontEnd Brasil. Algo chocante a ponto de desanimar o mais engajado dos participantes.

Após postar um Gist sobre moment com um código bastante didático, Berger foi rechaçado pelo moderador da comunidade, Jean Carlo Nascimento. Ao notar que o gist era escrito em CoffeeScript, o moderador comentou uma piadinha:

Prefiro usar moment a coffee.

A comunidade não gostou e reagiu, criticando o comentário infeliz e prezando o autor por compartilhar um código útil. Não satisfeito, as agressões sobre o uso de CoffeeScript continuaram.

@diegoeis
diegoeis / brazil2014-leo-data-binding.md
Last active August 29, 2015 14:05
Data-binding [R]evolution

Data-binding [R]evolution

Leo Balter

BrazilJS 2014

  • Data Binding é o processo que estabelece uma conexão entre a interface aplicação e o lógica de negócio
  • Com o ES5, já tínhamos alguns métodos fazem com que comecemos a manipular propriedades de objetos e como lidamos com essas propriedades.
  • Com o ES6 e ES7 teremos coisas mais interessantes, solucionando mais problemas.
  • Os frameworks para data binding estão vindo: polymer, ember.js, react, Angular.JS, Backbone.js, way.js etc.
  • O Way é um experimento lançado em pouco tempo, de uma forma de integrar sua interface com seus objeto.
  • Data Binding quebra um pouco a linha de programação funcional.
@juanplopes
juanplopes / pave.md
Last active August 29, 2015 14:05
Candidato, é pavê ou pra comê? (texto de @kramercarlos)

Texto criado pelo amigo Carlos Krämer (github . twitter . facebook) lá no Facebook, reproduzido aqui com a permissão dele.

Jornalista: Candidato, é pavê ou pra comê?

Dilma: Veja bem, nunca foi tanto pra comê quanto no meu governo. Há um ditado.... eu digo, editaram quando eu era o cachorro atrás de uma criança ... que diz que todo mundo que insere, ou melhor, ingere o que é pavê, tem uma satisfação imensa de... como dizem... dobrar a esquina. Mas nós precisamos continuar mudando, meu governo foi ótimo, eu fui eleita para dar prosseguimento ao governo Lula, Lula, LULA. Mas ninguém está mais insatisfeita com ele, digo, com o governo, não com o Lula, do que eu, mas os pessimistas é que estão tornando tudo ruim.

Marina: Eu não acho que é pavê nem pra comê. Nós precisamos aprender a reunir o que é bom em tudo, as melhores

Qual o resultado para:
// 1:
{}+{} // ?
// 2:
({}+{}) // ?