#5421: Limit usage of variable to just the extra node rendering.
#5421: Handle variable in booktoc widget.
Merge pull request #5557 from openscholar/5421-book_js_fixes

Fix unwanted side effects of book variable