sp-dev-docs icon indicating copy to clipboard operation
sp-dev-docs copied to clipboard

spfx ListViewCommandSet CommandBar does not show up

Open 123Flick123 opened this issue 7 years ago • 17 comments

Category

  • [ ] Question
  • [ ] Typo
  • [x] Bug
  • [x] spfx
  • [ ] Additional article idea

Bug behaivor

If I want to host my spfx ListViewCommandSet at localhost with "gulp serve" I got following issue. Everything works fine - no errors, but after clicking "Load Debug Scripts" nothing happend. No custom CommandBar Items will appear.

Ironically, if I type something in the SharePoint List Search Bar, the Custom CommandBar will appear...

I used this MS Demo: https://docs.microsoft.com/de-de/sharepoint/dev/spfx/extensions/get-started/building-simple-cmdset-with-dialog-api

After clicking "Load Debug Scripts": image

After typing something in the searchbar: image

I hope you can help me to fix this, that I can also use my Custom List Actions in the normal list view..

Thanks!

123Flick123 avatar Jul 22 '19 15:07 123Flick123

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.

msft-github-bot avatar Jul 22 '19 15:07 msft-github-bot

Same exact issue here. Would love to get an update as this is blocking active development work.

kcasamento avatar Jul 22 '19 17:07 kcasamento

I'm having the same issue with the field customizer and the CommandBar. I've gone through the docs for all three extensions to make sure it wasn't something I was doing.

The Application Customizer however is still loading correctly and displaying the pop-up. When I put break points on OnInit() in the developer tools, the Application Customizer hits them correctly. The other two never stop on the break points.

Please let me know if there are any logs or screenshots that would help.

jonesron avatar Jul 22 '19 17:07 jonesron

I have the same issue now with my tenant which is updated later since today. In my dev tenant this didn't work before. I think its the same issue as https://github.com/SharePoint/sp-dev-docs/issues/3705

barisbikmaz avatar Jul 23 '19 06:07 barisbikmaz

@barisbikmaz Thanks, it does look like the same issue. I'll keep an eye on that one.

It looks like some in the page and not with the extensions. I tried the same test as @123Flick123 did with the field extension. The script didn't show up till I searched for the item.

field-extension-debug

The search also hit the breakpoints.

jonesron avatar Jul 23 '19 12:07 jonesron

@barisbikmaz Thanks, it does look like the same issue. I'll keep an eye on that one.

It looks like some in the page and not with the extensions. I tried the same test as @123Flick123 did with the field extension. The script didn't show up till I searched for the item.

field-extension-debug

The search also hit the breakpoints.

Hi @jonesron,

Thanks for testing! I did some researches today. Somebody wrote it's an issue of version 1.8.2 of spfx. I don't know if it's possible but maybe we can downgrade our version to 1.8.1 or lower. I will try it tomorrow. If somebody has downgraded their version someonce, please reach out to me.

123Flick123 avatar Jul 23 '19 15:07 123Flick123

Well, I downgraded to 1.8.1 and upgraded to 1.9.0. Neither worked. The results were exactly the same as the ones described above.

jonesron avatar Jul 23 '19 20:07 jonesron

Same problem here since 15 days in local gulp serve command... ! After clicking "Load Debug Scripts" nothing happend. No custom CommandBar Items will appear, no log and breakpoint work. I don't know if is the same problem... but i think it's the same issue as https://github.com/SharePoint/sp-dev-docs/issues/4219

JonathanJourdan avatar Jul 24 '19 10:07 JonathanJourdan

Same issue. Command sets do not work when running gulp serve.

frnk01 avatar Jul 29 '19 07:07 frnk01

I also experience this issue, but works fine when deployed. 🔥🧯 hotfix needed because this is blocking active development.

nayots avatar Jul 29 '19 08:07 nayots

There is a "non-dev-friendly" workaround:

  • gulp bundle
  • gulp package-solution
  • deploy created package to SharePoint app catalog
  • gulp serve --nobrowser

Then you can debug the code as it comes from the localhost. But you need to rebuild the whole stuff if you want to change sth in the code.

barisbikmaz avatar Jul 29 '19 10:07 barisbikmaz

Guys here a workaround by @jackPoz it's work for me ! :) https://github.com/SharePoint/sp-dev-docs/issues/4374#issuecomment-516815819

JonathanJourdan avatar Jul 31 '19 11:07 JonathanJourdan

Thanks @JonathanJourdan (and @jackpoz). Tested it out and changing it to &loadSpfx=true worked for me.

Due to my lack of understanding of gulp, when I change it to &loadSpfx=true and tried @123Flick123 test with the item search, the 'value' text was still on the item. Shouldn't that not work now? Not a big deal, but just wondering.

Thanks for everyone's help.

jonesron avatar Jul 31 '19 12:07 jonesron

Thank you very much! This workaround is also working for me!

123Flick123 avatar Aug 01 '19 10:08 123Flick123

Now it's working also with SPFX in big case! Thanks for fixing the Bug!

123Flick123 avatar Aug 22 '19 11:08 123Flick123

@123Flick123 I just tried as it as well following the office dev instructions and it worked exactly as it's laid out in the instructions.

Thanks to the team for resolving this issue.

jonesron avatar Aug 22 '19 12:08 jonesron

Issues that have been closed & had no follow-up activity for at least 7 days are automatically locked. Please refer to our wiki for more details, including how to remediate this action if you feel this was done prematurely or in error: Issue List: Our approach to locked issues

msft-github-bot avatar Jan 24 '20 00:01 msft-github-bot