Removing height and width from images with a caption

Here is another possibility, it alters the image markup when you select an image to add to your content in the editor

  add_filter( 'image_send_to_editor', 'remove_img_attribute', 10, 8 );

   function remove_img_attribute( $html, $id, $caption, $title, $align, $url, $size, $alt ) 
    {
       $imagetpl="<figure>
            <a href="https://wordpress.stackexchange.com/questions/129666/%s" title="https://wordpress.stackexchange.com/questions/129666/%s"><img src="https://wordpress.stackexchange.com/questions/129666/%s" alt="https://wordpress.stackexchange.com/questions/129666/%s" class="img-responsive %s" /></a>
            %s
       </figure>";
       $figcaption = (!empty($caption)) ? sprintf('<figcaption>%s</figcaption>',$caption):null;
       $image = wp_get_attachment_image_src($id,'large');
       return sprintf($imagetpl,$image[0],$title,$image[0],$alt,$align,$figcaption);
    }