Sider bar USFM markup is:
\esb
Some content ...
\esbe
The Bible text is being included in the sidebar as the sidebar end marker \esbe is being ignored.
Source text
\id JAS
\ide UTF-8
\h James
\toc3 James
\toc1 The Letter of James
\toc2 James
\mt2 The Letter of
\mt1 James
\c 1
\esb \cat Fact\cat*
\ms Fact
\p Some random facts about James...
\esbe
\s1 Greeting
\p
\v 1 Hello people ....