Add a command history list
Categories
(DevTools :: Console, enhancement, P3)
Tracking
(firefox93 fixed)
Tracking | Status | |
---|---|---|
firefox93 | --- | fixed |
People
(Reporter: sebo, Assigned: claubatista)
References
(Blocks 2 open bugs)
Details
Attachments
(1 file)
Updated•8 years ago
|
Updated•8 years ago
|
Updated•6 years ago
|
Comment 1•5 years ago
|
||
Partially solved in bug 1024913, but having a visual history would still be nice.
Comment 2•3 years ago
|
||
Claudia, would you be interested working on this? It's about a new :history
command to add in the console.
I thought it might be a nice fit for you since you were working in this area lately.
Let me know if you'd rather work on something else if this doesn't look appealing / wants to work on a different area/panel :)
Assignee | ||
Comment 3•3 years ago
|
||
(In reply to Nicolas Chevobbe [:nchevobbe] from comment #2)
Claudia, would you be interested working on this? It's about a new
:history
command to add in the console.
I thought it might be a nice fit for you since you were working in this area lately.
Let me know if you'd rather work on something else if this doesn't look appealing / wants to work on a different area/panel :)
Thank you, Nicolas, it's perfect for me. :)
Comment 4•3 years ago
|
||
Nice :) I'm assigning the bug to you then
The command needs to be registered in https://searchfox.org/mozilla-central/rev/cfc40681e13089f92fb3f5f67d5d527fb04d9505/devtools/server/actors/webconsole/commands.js#7
Then I think everything will be handled in the client, so we can take inspiration from the screenshot command for what's needed on the server https://searchfox.org/mozilla-central/rev/cfc40681e13089f92fb3f5f67d5d527fb04d9505/devtools/server/actors/webconsole/utils.js#567-577 (i.e. not much)
We can then handle the server response on the client side, adding a case
in this switch https://searchfox.org/mozilla-central/rev/cfc40681e13089f92fb3f5f67d5d527fb04d9505/devtools/client/webconsole/actions/input.js#184
We can see here how we can retrieve the history https://searchfox.org/mozilla-central/rev/cfc40681e13089f92fb3f5f67d5d527fb04d9505/devtools/client/webconsole/middleware/history-persistence.js#23
Then, when we have all the data, we want to display them in a message.
As the history can have many items (that can be quite long), we we can try to render it the same way we render console.table
calls, where the first column would be an index, and the second one the expression.
Let me know if you have any question!
Assignee | ||
Comment 5•3 years ago
|
||
Comment 6•3 years ago
|
||
As phabricator says it won't send notification as the patch is a draft, I'm letting you know that I did added some comments on it :)
Updated•3 years ago
|
Updated•3 years ago
|
Comment 9•3 years ago
|
||
bugherder |
Description
•