Repository: mwouts/itables

Issue:
html in column names
I was attempting to use itables to present units in the column name. I found that the HTML tags work well in cell values but not in table headers:

``` python
from itables import show
test_df = pd.DataFrame(
    {"some_nm<sup>2</sup>": ["some val <sup>2</sup>", "<b>Bold Value</b>"]}
    )
show(test_df)
```

<img width="824" alt="image" src="https://github.com/mwouts/itables/assets/49126943/804801bf-6d81-424f-9afc-2ddc54d091d3">


Discussion:

Patch:
diff --git a/docs/changelog.md b/docs/changelog.md
index 1bec8a1..96145cf 100644
--- a/docs/changelog.md
+++ b/docs/changelog.md
@@ -1,6 +1,13 @@
 ITables ChangeLog
 =================
 
+1.6.3 (2023-12-10)
+------------------
+
+**Changed**
+- HTML in table columns is supported ([#213](https://github.com/mwouts/itables/issues/213))
+
+
 1.6.2 (2023-10-07)
 ------------------
 
diff --git a/itables/javascript.py b/itables/javascript.py
index e601972..761783d 100644
--- a/itables/javascript.py
+++ b/itables/javascript.py
@@ -144,7 +144,7 @@ def _table_header(
     # Generate table head using pandas.to_html(), see issue 63
     pattern = re.compile(r".*<thead>(.*)</thead>", flags=re.MULTILINE | re.DOTALL)
     try:
-        html_header = df.head(0).to_html()
+        html_header = df.head(0).to_html(escape=False)
     except AttributeError:
         # Polars DataFrames
         html_header = pd.DataFrame(data=[], columns=df.columns).to_html()
diff --git a/itables/version.py b/itables/version.py
index 211dd9d..6557b26 100644
--- a/itables/version.py
+++ b/itables/version.py
@@ -1,3 +1,3 @@
 """ITables' version number"""
 
-__version__ = "1.6.2"
+__version__ = "1.6.3"


Test patch:
diff --git a/tests/test_html_in_table_header.py b/tests/test_html_in_table_header.py
new file mode 100644
index 0000000..eb09d85
--- /dev/null
+++ b/tests/test_html_in_table_header.py
@@ -0,0 +1,9 @@
+import pandas as pd
+
+from itables import to_html_datatable
+
+
+def test_html_in_table_header(df=pd.DataFrame({"<b>B</b>": [1]})):
+    html = to_html_datatable(df)
+    print(html)
+    assert "<b>B</b>" in html