Demos: Pre-render collapsibles in demos left-side menu

(cherry picked from commit 08f1e7cd1a5c61aa125d4cff84daf0409fc820b5)

Fixes gh-7225