{"action":"created","issue":{"url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/369","repository_url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin","labels_url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/369/labels{/name}","comments_url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/369/comments","events_url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/369/events","html_url":"https://github.com/orthes/medium-editor-insert-plugin/issues/369","id":168302356,"node_id":"MDU6SXNzdWUxNjgzMDIzNTY=","number":369,"title":"Call a function when when file upload process starts","user":{"login":"chintanbanugaria","id":222917,"node_id":"MDQ6VXNlcjIyMjkxNw==","avatar_url":"https://avatars3.githubusercontent.com/u/222917?v=4","gravatar_id":"","url":"https://api.github.com/users/chintanbanugaria","html_url":"https://github.com/chintanbanugaria","followers_url":"https://api.github.com/users/chintanbanugaria/followers","following_url":"https://api.github.com/users/chintanbanugaria/following{/other_user}","gists_url":"https://api.github.com/users/chintanbanugaria/gists{/gist_id}","starred_url":"https://api.github.com/users/chintanbanugaria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chintanbanugaria/subscriptions","organizations_url":"https://api.github.com/users/chintanbanugaria/orgs","repos_url":"https://api.github.com/users/chintanbanugaria/repos","events_url":"https://api.github.com/users/chintanbanugaria/events{/privacy}","received_events_url":"https://api.github.com/users/chintanbanugaria/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-29T11:08:24Z","updated_at":"2018-08-22T09:43:03Z","closed_at":"2016-08-08T11:30:58Z","author_association":"NONE","body":"Any idea how to call a custom function when file upload function starts ?\nHere's my code. I want to start a loader as soon as file upload process starts and close it when upload is completed.\n\n```\n$('.editable').mediumInsert({\n                                  editor: editor,\n                                  addons: { \n                                    images: { \n                                      deleteScript: 'deleteimage',\n                                      deleteMethod: 'POST',\n                                      fileDeleteOptions: {\n                                                headers: {\n                                                  'X-CSRF-TOKEN': $('meta[name=\"csrf-token\"]').attr('content')\n                                                }\n                                      },\n                                      fileUploadOptions: {\n                                            formData: [\n                                                                {\n                                                                    name: '_token',\n                                                                    value: $('meta[name=\"csrf-token\"]').attr('content')\n                                                                }\n                                            ],\n                                            url: 'uploadimage', \n                                            acceptFileTypes: /(\\.|\\/)(gif|jpe?g|png)$/i \n                                        },\n\n                                    },\n                                  }\n                });\n```\n\nThanks,\nChintan\n"},"comment":{"url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/comments/414975434","html_url":"https://github.com/orthes/medium-editor-insert-plugin/issues/369#issuecomment-414975434","issue_url":"https://api.github.com/repos/orthes/medium-editor-insert-plugin/issues/369","id":414975434,"node_id":"MDEyOklzc3VlQ29tbWVudDQxNDk3NTQzNA==","user":{"login":"SurbhiVyas97","id":39584470,"node_id":"MDQ6VXNlcjM5NTg0NDcw","avatar_url":"https://avatars0.githubusercontent.com/u/39584470?v=4","gravatar_id":"","url":"https://api.github.com/users/SurbhiVyas97","html_url":"https://github.com/SurbhiVyas97","followers_url":"https://api.github.com/users/SurbhiVyas97/followers","following_url":"https://api.github.com/users/SurbhiVyas97/following{/other_user}","gists_url":"https://api.github.com/users/SurbhiVyas97/gists{/gist_id}","starred_url":"https://api.github.com/users/SurbhiVyas97/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SurbhiVyas97/subscriptions","organizations_url":"https://api.github.com/users/SurbhiVyas97/orgs","repos_url":"https://api.github.com/users/SurbhiVyas97/repos","events_url":"https://api.github.com/users/SurbhiVyas97/events{/privacy}","received_events_url":"https://api.github.com/users/SurbhiVyas97/received_events","type":"User","site_admin":false},"created_at":"2018-08-22T09:43:03Z","updated_at":"2018-08-22T09:43:03Z","author_association":"NONE","body":"here in the first way how to use callback of fileuploadstart in fileuploadoption?"}}
{"actor":{"display_login":"SurbhiVyas97"}}