Jun 16 2019 01:44 PM
Hi, I wanted to hide the QuickLaunch Bar when displaying my React WebPart.
I succeed in removing it with this code when in the DidMount or DidUpdate :
Is it a good practice ?
Regards
Jun 17 2019 04:42 AM
Jun 17 2019 08:29 AM
Jun 17 2019 03:42 PM
@Deleted Thanks for your reply, It is what I suspected. But how can I find the div spNav div for hiding the quicklaunch more safely?
Jun 17 2019 03:43 PM
@Thomas Berman Thanks for your reply, It is what I suspected. But how can I find the div spNav div for hiding the quicklaunch more safely?
Jun 18 2019 02:08 AM - edited Jun 18 2019 02:09 AM
Solution
You can hide the Quick Lauch (left side navigation) via site settings > navigation elements > uncheck "Enable quick launch"
As for the top bar, you can delete all the links in there, but hiding via CSS/JS is definitely not advisable.
Jul 03 2019 07:20 AM
As I found no other solution and as I do not want to add jQuery with a selector like ("*[class~='spNav_']") in my React component (that will be even more ugly) I have finally write this for hiding all not needed part of the page even it is not a good practice. If someone found a better solution please ping me.
Regards
Jun 18 2019 02:08 AM - edited Jun 18 2019 02:09 AM
Solution
You can hide the Quick Lauch (left side navigation) via site settings > navigation elements > uncheck "Enable quick launch"
As for the top bar, you can delete all the links in there, but hiding via CSS/JS is definitely not advisable.