This just tracks how long the editor was active for.
I know these extensions exists, I wanted to learn how to make my own.
This is using setInterval
every second it checks if the window is focused, if it is, stores a second/adds to total time displayed by calling Time In Editor
via command palette.
Have @vscode/vsce
package installed globally, vsce package
, then install by right of extension search, install by VSIX option