{"action":"opened","issue":{"url":"https://api.github.com/repos/spchuang/videojs-markers/issues/82","repository_url":"https://api.github.com/repos/spchuang/videojs-markers","labels_url":"https://api.github.com/repos/spchuang/videojs-markers/issues/82/labels{/name}","comments_url":"https://api.github.com/repos/spchuang/videojs-markers/issues/82/comments","events_url":"https://api.github.com/repos/spchuang/videojs-markers/issues/82/events","html_url":"https://github.com/spchuang/videojs-markers/issues/82","id":293462141,"number":82,"title":"How to use the plugin with react","user":{"login":"MohammedAkhil","id":15796106,"avatar_url":"https://avatars0.githubusercontent.com/u/15796106?v=4","gravatar_id":"","url":"https://api.github.com/users/MohammedAkhil","html_url":"https://github.com/MohammedAkhil","followers_url":"https://api.github.com/users/MohammedAkhil/followers","following_url":"https://api.github.com/users/MohammedAkhil/following{/other_user}","gists_url":"https://api.github.com/users/MohammedAkhil/gists{/gist_id}","starred_url":"https://api.github.com/users/MohammedAkhil/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MohammedAkhil/subscriptions","organizations_url":"https://api.github.com/users/MohammedAkhil/orgs","repos_url":"https://api.github.com/users/MohammedAkhil/repos","events_url":"https://api.github.com/users/MohammedAkhil/events{/privacy}","received_events_url":"https://api.github.com/users/MohammedAkhil/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-01T09:38:57Z","updated_at":"2018-02-01T09:38:57Z","closed_at":null,"author_association":"NONE","body":"I'm trying to add this plugin to my react app. \r\n\r\nI've tried to add a script to index.html\r\n\r\n```\r\n<link href=\"http://vjs.zencdn.net/4.3/video-js.css\" rel=\"stylesheet\">\r\n<script src=\"http://vjs.zencdn.net/4.3/video.js\"></script>\r\n<script src=\"http://code.jquery.com/jquery-2.0.3.min.js\"></script>\r\n  \r\n<!-- include videojs marker src !-->\r\n<script src=\"https://rawgithub.com/spchuang/videojs-markers/master/dist/videojs-markers.js\"></script>\r\n<link href=\"https://rawgithub.com/spchuang/videojs-markers/master/dist/videojs.markers.css\" rel=\"stylesheet\">\r\n```\r\n\r\nin `App.js`\r\n```\r\ncomponentDidMount() {\r\n        // instantiate Video.js\r\n        this.player = videojs(this.videoNode, this.props, function onPlayerReady() {\r\n            let video = videojs('video-x');\r\n            video.markers({\r\n                markers: [\r\n                    {time: 9.5, text: \"this\"},\r\n                    {time: 16,  text: \"is\"}\r\n                ]\r\n            });\r\n        });\r\n    }\r\n```\r\n\r\nbut i get this error\r\n```\r\n\r\nTypeError: video.markers is not a function\r\nonPlayerReady\r\n\r\n// instantiate Video.js\r\n   8 | this.player = videojs(this.videoNode, this.props, function onPlayerReady() {\r\n   9 |     let video = videojs('video-x');\r\n> 10 |     video.markers({\r\n  11 |         markers: [\r\n  12 |             {time: 9.5, text: \"this\"},\r\n  13 |             {time: 16,  text: \"is\"}\r\n```\r\n\r\nhow do i properly add this plugin in react.js"}}
{"actor":{"display_login":"MohammedAkhil"}}