Hacker Newsnew | comments | show | ask | jobs | submitlogin

+1. I can't even add an element directly in the Chrome dev tools - you can only edit an existing elements HTML and append something after it.

My kingdom for a '+' button.




You can, sort of.

Right click on an element and choose "edit as HTML" and you can add whatever you want, granted it offers no reasonable formatting, its just a wall of text, not even tabs / line breaks.

It is also broken in that when you do this Chrome rebuilds all the sub elements of what your editing so if there were event hooks or anything like that on the elements they will be gone.

-----


Not to mention dragging over text to select it usually results in the entire HTML fragment getting destroyed when Chrome decides that you're actually attempting to drag the text to move it somewhere else.

-----


> It is also broken in that when you do this Chrome rebuilds all the sub elements of what your editing so if there were event hooks or anything like that on the elements they will be gone.

This may not be completely true. In Edit As HTML mode every effort is made to retain the original elements. If you move some tags to another location, the real element (and handlers) should actually be retained.

-----


My workaround is to click an element, then type into console

    $0.appendChild(document.createElement('tagName'))
but yeah, a [+] button would be niceā€¦

-----


It really seems like you didn't read my post before you replied to it.

-----




Applications are open for YC Summer 2015

Guidelines | FAQ | Support | Lists | Bookmarklet | DMCA | Y Combinator | Apply | Contact

Search: