{"action":"closed","issue":{"url":"https://api.github.com/repos/draft-js-plugins/draft-js-plugins/issues/1043","repository_url":"https://api.github.com/repos/draft-js-plugins/draft-js-plugins","labels_url":"https://api.github.com/repos/draft-js-plugins/draft-js-plugins/issues/1043/labels{/name}","comments_url":"https://api.github.com/repos/draft-js-plugins/draft-js-plugins/issues/1043/comments","events_url":"https://api.github.com/repos/draft-js-plugins/draft-js-plugins/issues/1043/events","html_url":"https://github.com/draft-js-plugins/draft-js-plugins/issues/1043","id":301438623,"number":1043,"title":"Mentions not triggering","user":{"login":"IbeGarritsen","id":1218448,"avatar_url":"https://avatars0.githubusercontent.com/u/1218448?v=4","gravatar_id":"","url":"https://api.github.com/users/IbeGarritsen","html_url":"https://github.com/IbeGarritsen","followers_url":"https://api.github.com/users/IbeGarritsen/followers","following_url":"https://api.github.com/users/IbeGarritsen/following{/other_user}","gists_url":"https://api.github.com/users/IbeGarritsen/gists{/gist_id}","starred_url":"https://api.github.com/users/IbeGarritsen/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IbeGarritsen/subscriptions","organizations_url":"https://api.github.com/users/IbeGarritsen/orgs","repos_url":"https://api.github.com/users/IbeGarritsen/repos","events_url":"https://api.github.com/users/IbeGarritsen/events{/privacy}","received_events_url":"https://api.github.com/users/IbeGarritsen/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-03-01T15:06:23Z","updated_at":"2018-03-16T11:44:33Z","closed_at":"2018-03-16T11:44:33Z","author_association":"NONE","body":"Hi guys,\r\n\r\nI've a problem with the Mention plugin. I got no errors and when I inspect with React DevTools I can see the Component renders good. When I type '@' nothing happens, even the console log is not working in the 'onSearchChange' function. Anybody suggestions?\r\n\r\nThis is my code:\r\n\r\n```\r\n...\r\nvar  createMentionPlugin = require('draft-js-mention-plugin').default,\r\n     defaultSuggestionsFilter = require('draft-js-mention-plugin').defaultSuggestionsFilter,\r\n...\r\n````\r\n\r\n```\r\ncomponentWillMount: function() {\r\n    this.mentionPlugin = createMentionPlugin();\r\n},\r\n\r\nonSearchChange: function({ value }) {\r\n    console.log('foo');\r\n\r\n    this.setState({\r\n        suggestions: defaultSuggestionsFilter(value, mentions)\r\n    });\r\n },\r\n```\r\nAnd in the render function:\r\n```\r\nif (!this.mentionPlugin) {\r\n    return <div />;\r\n}\r\n// Mentions\r\nconst { MentionSuggestions } = this.mentionPlugin;\r\nconst editorPlugins = [this.mentionPlugin];\r\n\r\n<Draft.Editor\r\n    editorState={this.state.editorState}\r\n    handleKeyCommand={this.handleKeyCommand}\r\n    onChange={this.handleChange}\r\n    onBlur={this.handleBlur}\r\n    onFocus={this.handleFocus}\r\n    placeholder={placeholder}\r\n    plugins={editorPlugins}\r\n    ref={function(element) {\r\n       self.editor = element;\r\n     }}\r\n/>\r\n<MentionSuggestions\r\n     onSearchChange={this.onSearchChange}\r\n     suggestions={this.state.suggestions}\r\n/>\r\n```\r\n"}}
{"actor":{"display_login":"IbeGarritsen"}}