Open poojakapuriya619 opened 4 years ago
I've no experiences with Fabric.js, but I think you can maybe trigger it's behavior after the polyfill has run.
Edit: Okay, I see the issue now after having a look at Fabric.js. I think you need to delay this polyfill after Fabric is run. So you need to load and apply the polyfill after Fabric did its magic (and maybe re-apply it after changes have been made). You can see here how the polyfill is applied. Lazy loading the script is some Stackoverflow research. It'll may be easier to have a global short hand method to call the polyfill dynamically...
Thanks. I'll check this and let you know if it works.
I checked the lazy loading script. Unfortunately its not working in my case because once the script is loaded it again overrides the default behaviour of all methods. I want to add filters and text from frabic.js simultaneously.
The global method sounds like a solution but I am really new to polyfill. I downloaded js from demo and struggling to create a global class for the same. Could you please create a Js and add to your repo?
It changes the default CanvasRenderingContext2d and therefore while adding text to canvas the method does not work properly.
Can you please help fix this? Thanks in advance.