Skip to content

Instantly share code, notes, and snippets.

View darioghilardi's full-sized avatar

Dario Ghilardi darioghilardi

View GitHub Profile
@darioghilardi
darioghilardi / branch.jsx
Last active September 7, 2017 20:41
Recompose: branch
import React from 'react';
import { render } from 'react-dom';
import { branch, renderComponent, renderNothing } from 'recompose';
// Define a stateless React component
const HelloWorld = () => <p>Hello World!</p>;
// Defines an higher order component using branch:
// - The first parameter is a function that
// returns true or false. In this case
@darioghilardi
darioghilardi / config.el
Created February 19, 2020 13:00
Doom-Emacs Elixir config
;; Elixir configuration
;; Start by configuring Alchemist for some tasks.
(def-package! alchemist
:hook (elixir-mode . alchemist-mode)
:config
(set-lookup-handlers! 'elixir-mode
:definition #'alchemist-goto-definition-at-point
:documentation #'alchemist-help-search-at-point)
(set-eval-handler! 'elixir-mode #'alchemist-eval-region)
(set-repl-handler! 'elixir-mode #'alchemist-iex-project-run)
### Keybase proof
I hereby claim:
* I am darioghilardi on github.
* I am darioghilardi (https://keybase.io/darioghilardi) on keybase.
* I have a public key ASA1x5u-a9hQqE6zsI_LSm0j3qQ4Ka60dCnju36DCoipYwo
To claim this, I am signing this object: