defmodule Liliform do use Phoenix.Component import PhxComponentHelpers @doc """ Renders a button. """ slot :inner_block, required: true def button(assigns) do assigns = assigns |> extend_class("bg-blue-500 text-white px-4 py-2 rounded-md") |> set_attributes([:type, :id], required: [:id]) |> set_phx_attributes() ~H""" """ end end