I have a Modern sharepoint online list with 2 views. Is it possible to create 2 button to change the view "on the fly"? either json or via ClientSideExtension.ListViewCommandSet.CommandBar or is there an other way. I know I can create to links but that would reload the page and is to slow.

Thanks Morten

Update: Thanks Denis now i know React debug :) It looks like the change view "button / menu" is a customizedcommandbarbutton see picture, but i cannot find what it does. Because it is rather easy to make command bar buttons. enter image description here


I am not an expert at SharePoint Framework, but I can guess that we can't create a menu custom action that somehow can change React's state from outside and cause the proper page re-render.

Theoretically, if it's somehow possible, maybe SPFx's ListView command Set could do it. But I still doubt it.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.