File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed
Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,10 @@ This allows you to use the `class` and `class_name` functions in the template an
4747``` eex
4848 <h1 class="_2313dsc-title">Hello world</h1>
4949```
50+
51+ ** Please note that ` class ` cannot be used in ` heex ` templates as the HTML
52+ validation engine does not allow it.**
53+
5054## Advanced usage
5155
5256### Phoenix.View
Original file line number Diff line number Diff line change @@ -57,6 +57,10 @@ defmodule ExCSSModules do
5757
5858 Returns nil for a class_name that does not exist.
5959
60+ Note that this function cannot be used with HEEX templates, as the HTML
61+ validation engine does not allow them to be build with arbitrary text.
62+ `class_name/3` should be used instead.
63+
6064 ## Examples
6165
6266 iex> class(%{ "hello" => "world"}, "hello")
You can’t perform that action at this time.
0 commit comments