{"action":"created","issue":{"url":"https://api.github.com/repos/mathjax/MathJax-node/issues/205","repository_url":"https://api.github.com/repos/mathjax/MathJax-node","labels_url":"https://api.github.com/repos/mathjax/MathJax-node/issues/205/labels{/name}","comments_url":"https://api.github.com/repos/mathjax/MathJax-node/issues/205/comments","events_url":"https://api.github.com/repos/mathjax/MathJax-node/issues/205/events","html_url":"https://github.com/mathjax/MathJax-node/issues/205","id":147345697,"number":205,"title":"move PNG generation out of mathjax-node","user":{"login":"pkra","id":426686,"avatar_url":"https://avatars.githubusercontent.com/u/426686?v=3","gravatar_id":"","url":"https://api.github.com/users/pkra","html_url":"https://github.com/pkra","followers_url":"https://api.github.com/users/pkra/followers","following_url":"https://api.github.com/users/pkra/following{/other_user}","gists_url":"https://api.github.com/users/pkra/gists{/gist_id}","starred_url":"https://api.github.com/users/pkra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pkra/subscriptions","organizations_url":"https://api.github.com/users/pkra/orgs","repos_url":"https://api.github.com/users/pkra/repos","events_url":"https://api.github.com/users/pkra/events{/privacy}","received_events_url":"https://api.github.com/users/pkra/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/mathjax/MathJax-node/labels/Feature%20Request","name":"Feature Request","color":"0080FF"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/mathjax/MathJax-node/milestones/5","html_url":"https://github.com/mathjax/MathJax-node/milestones/v1.0","labels_url":"https://api.github.com/repos/mathjax/MathJax-node/milestones/5/labels","id":1696931,"number":5,"title":"v1.0","description":"The big one.","creator":{"login":"pkra","id":426686,"avatar_url":"https://avatars.githubusercontent.com/u/426686?v=3","gravatar_id":"","url":"https://api.github.com/users/pkra","html_url":"https://github.com/pkra","followers_url":"https://api.github.com/users/pkra/followers","following_url":"https://api.github.com/users/pkra/following{/other_user}","gists_url":"https://api.github.com/users/pkra/gists{/gist_id}","starred_url":"https://api.github.com/users/pkra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pkra/subscriptions","organizations_url":"https://api.github.com/users/pkra/orgs","repos_url":"https://api.github.com/users/pkra/repos","events_url":"https://api.github.com/users/pkra/events{/privacy}","received_events_url":"https://api.github.com/users/pkra/received_events","type":"User","site_admin":false},"open_issues":4,"closed_issues":0,"state":"open","created_at":"2016-04-11T07:56:06Z","updated_at":"2016-04-11T10:09:48Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2016-04-11T07:58:01Z","updated_at":"2016-04-17T17:25:04Z","closed_at":null,"body":"As per F2F, the PNG generation will be moved out of mathjax-node; there will be alternative modules to use.\r\n\r\nCf. the discussion in #174; see also #191."},"comment":{"url":"https://api.github.com/repos/mathjax/MathJax-node/issues/comments/211065891","html_url":"https://github.com/mathjax/MathJax-node/issues/205#issuecomment-211065891","issue_url":"https://api.github.com/repos/mathjax/MathJax-node/issues/205","id":211065891,"user":{"login":"dpvc","id":432782,"avatar_url":"https://avatars.githubusercontent.com/u/432782?v=3","gravatar_id":"","url":"https://api.github.com/users/dpvc","html_url":"https://github.com/dpvc","followers_url":"https://api.github.com/users/dpvc/followers","following_url":"https://api.github.com/users/dpvc/following{/other_user}","gists_url":"https://api.github.com/users/dpvc/gists{/gist_id}","starred_url":"https://api.github.com/users/dpvc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dpvc/subscriptions","organizations_url":"https://api.github.com/users/dpvc/orgs","repos_url":"https://api.github.com/users/dpvc/repos","events_url":"https://api.github.com/users/dpvc/events{/privacy}","received_events_url":"https://api.github.com/users/dpvc/received_events","type":"User","site_admin":false},"created_at":"2016-04-17T17:25:04Z","updated_at":"2016-04-17T17:25:04Z","body":"The `<img>` tag is actually for an SVG file, not a PNG file, so the file version of the SVG is used for that as well as the PNG file.  But perhaps you don't want to produce the SVG `<img>` tag any longer and want to push that to the surrounding tool.  Once of the difficulties of pushing this off to the application is the copying of the style attributes from the `<svg>` to the `<img>` tag.  If we are returning just a string for the svg (as we do now), then it is harder to get the style using string manipulation rather than DOM element's methods, and that is less reliable.  But if we return the DOM element rather than a string, then that means the application is now responsible for prettying it up as we [currently do](https://github.com/mathjax/MathJax-node/blob/master/lib/mj-single.js#L587-L593).\r\n\r\nOne solution might be to provide service routines to do some of this so that the application can call them as needed."}}