Skip to content

Instantly share code, notes, and snippets.

View dkulchenko's full-sized avatar
🐧

Daniil Kulchenko dkulchenko

🐧
View GitHub Profile
defmodule SchemaChecker do
def find_field_discrepancies do
schema_modules()
|> Enum.map(fn mod ->
{mod.__schema__(:source), check_module(mod)}
end)
end
defp schema_modules do
{:ok, modules} = :application.get_key(:core, :modules)
@bstruthers
bstruthers / AngularStrap hover popover contents
Last active July 23, 2016 01:00
Extend AngularStrap popover so the contents can interact with the mouse
/**
* Popover Directive. Wraps the AngularStrap popover and
* 1) Allows the popover to stay open when hovering / focusing the contents.
* If the popover was only triggered by 'hover' or 'focus', it closes as soon
* as the mouse leaves or focus is lost on the triggering element.
*
* 2) Lazy initializes the popover until it's needed. This reduces the
* amount of scope.
*
* 3) When the popover closes, cleans up the AngularStrap popover memory leak