Packages

Build calendars from ecto queries, includes view helpers for easy rendering with Phoenix

Current section

Files

Jump to
ez_calendar lib ez_calendar html calendars calendar.ex
Raw

lib/ez_calendar/html/calendars/calendar.ex

defmodule EZCalendar.HTML.Calendar do
@moduledoc """
Behaviour definition for HTML calendar types.
"""
@type calendar :: struct
@type render_function :: fun
@doc """
Builds the html for a calendar struct, accepts a calendar and a function as arugments.
The function can be passed in from the view and used to render the content for each date.
"""
@callback build(calendar, render_function) :: [any]
end