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

custom properties in the backgroundImage object, are not serialized in JSON #3241

Closed
ncou opened this issue Sep 7, 2016 · 1 comment · Fixed by #3250
Closed

custom properties in the backgroundImage object, are not serialized in JSON #3241

ncou opened this issue Sep 7, 2016 · 1 comment · Fixed by #3250
Labels

Comments

@ncou
Copy link
Collaborator

ncou commented Sep 7, 2016

Hi,

I am using the v1.6.3 of the library.
I have added a custom attribute on the backgroundImage using something like ::

canvas.setBackgroundImage('http://cssdeck.com/uploads/media/items/4/4OIJyak.png', canvas.renderAll.bind(canvas), {left:100, customattribute:"TEST1"});

And it's not serialized in the canvas.toJSON(["customattribute"]) methode.

If i move my custom attribute, on the canvas it's work fine.
I checked on the code source and it seems that the "propertiesToInclude" array is ok on the image class.

PS : If i display my custom attribute in the console with "canvas.imageBackground.get('customattribe')" it's showing the right value.

any idear ? it seems to be a bug

Thank you for your help. and keep up the good work. this library is amazing

@asturur asturur added the bug label Sep 11, 2016
@asturur asturur added this to the 1.6.5 milestone Sep 11, 2016
@asturur
Copy link
Member

asturur commented Sep 11, 2016

checking if is a bug i ll fix it otherway just close it

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

Successfully merging a pull request may close this issue.

2 participants