question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Mention plugin only pops up when '@' is the first character in a line after updating

See original GitHub issue

Hello,

I’m using draft-mention-plugin in production, and after updating to Draft 0.10 and mentions plugin 2.0.0-rc9, I’m finding that the suggestions only pop-down if the ‘@’ character is the first character in any row. So:

@name works, but

hi @name will not pop the suggestions component.

I’ve been debugging through the code and am at a loss as to why this is happening. It appears that on editor state change, the function in MentionSuggestions component that determines if it should be shown is returning early because there are no search portals, so it’s not looking at the raw content and looking for content that ends with a @.

Any idea where to look here? Thank you.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
thenanyucommented, Oct 4, 2017

I just repro’d in rc10

0reactions
diegohazcommented, Oct 20, 2017

I’m also having this problem (with rc10). Trying to investigate it, but without success so far.

UPDATE:

Ok, don’t know if that’s a npm/yarn bug. But, for some reason, having "draft-js-mention-plugin": "^2.0.0-rc10" on package.json was installing rc9. I needed to remove ^ from the version to get it to install rc10 properly. And with rc10 this problem doesn’t happen.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Guide to Configuring Plug-ins - Apache Maven
Configuring Build Plugins. The following is only to configure Build plugins in the <build> element. Using the <executions> Tag.
Read more >
FAQ Troubleshooting – WordPress.org Forums
Check that the very first characters are with no blank lines or spaces after it.
Read more >
Vim: insert the same characters across multiple lines
Note: It will only update the screen in the first line - until Esc is pressed (6.), at which point all lines will...
Read more >
50 Most Common WordPress Errors and How to Fix Them
If a user initiates another update process while an update is already underway, then you'll see this error message.
Read more >
How To Index and Slice Strings in Python 3 - DigitalOcean
When we refer to a particular index number of a string, Python returns the character that is in that position. Since the letter...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found