GetmeUK / ContentTools

A JS library for building WYSIWYG editors for HTML content.
http://getcontenttools.com
MIT License
3.94k stars 393 forks source link

How do I get the image to save as an image tag instead of background css? #548

Closed ScotsScripts closed 4 years ago

ScotsScripts commented 4 years ago

I'm working on finalizing image uploading and I'm using the scripts on this page to make my js:

http://getcontenttools.com/tutorials/handling-image-uploads

I'm wondering how to not apply hard coded width and height to the image tag when I save the content? CSS handles fitting the images into their parent elements and I don't need hard coded dimensions. It's probably an obvious thing, but I'm that experienced with JS and the solution is eluding my efforts.

Thanks for a super cool set of content editing tools!

ScotsScripts commented 4 years ago

Cancel that question, I realized later that it only uses background css image when editing.