Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added method to return data url #13

Merged
merged 3 commits into from
Jan 4, 2017
Merged

Conversation

akhilrex
Copy link
Contributor

@akhilrex akhilrex commented Jan 3, 2017

Hi

I have added a simple method that returns the data url that can be returned directly in the img tag. It just exposes the default functionality of canvas.

* @param {String} imageType The image type name. Valid values are image/png image/jpeg
* @returns {Promise} A promise that resolves when the image is received in the form of data url
*/
getImageDataUrl(imageType) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT: Tab this back to line up with the other methods.

@sedouard
Copy link
Contributor

sedouard commented Jan 3, 2017

Thanks @akhilrex! This looks awesome 👍 . Just one tiny formatting issue. If you can just fix it real quick I'll have it merged and published today.

Cheers! 🍻

@akhilrex
Copy link
Contributor Author

akhilrex commented Jan 4, 2017

Done!!

@sedouard sedouard merged commit 264d860 into vmpowerio:master Jan 4, 2017
@sedouard
Copy link
Contributor

sedouard commented Jan 4, 2017

Thanks!

@sedouard
Copy link
Contributor

sedouard commented Jan 4, 2017

[email protected] published has this change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants