title: summernote add class in img
body: <p>I want to add a class (class="img-responsive") in the images which i add with the editor.</p>
  
  <p>actually i get this code after i saved my text:</p>
  
  <pre><code>&amp;lt;img src=&amp;quot;LINK&amp;quot; style=&amp;quot;width: 628px; height: 470.7191413237925px;&amp;quot;&amp;gt;
  </code></pre>
  
  <p>in the summernote.js i found this code:</p>
  
  <pre><code>/**
       * create `&lt;image&gt;` from url string
       *
       * @param {String} sUrl
       * @return {Promise} - then: $image
       */
      var createImage = function (sUrl) {
        return $.Deferred(function (deferred) {
          $('&lt;img&gt;').one('load', function () {
            deferred.resolve($(this));
          }).one('error abort', function () {
            deferred.reject($(this));
          }).css({
            display: 'none'
          }).appendTo(document.body).attr('src', sUrl);
        }).promise();
      };
  
      return {
        readFileAsDataURL: readFileAsDataURL,
        createImage: createImage
      };
    })();
  </code></pre>
  
  <p>i dont know if that is the right code to add a class, and also i dont know how and where to add class="img-responsive"</p>