Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add simple usage stats to cheatsheet #2116

Closed

Conversation

bra1nDump
Copy link
Collaborator

@bra1nDump bra1nDump commented Dec 10, 2023

Dependency: Command history logging #2115

As an avid cheatsheet user, it is the most intuitive place for me to show aggregate usage and would help me identify gaps.

Implementation

UI

image

Discussions

  • What UI do people expect from this?
  • Gamifying completing features by coloring them different (after X number of uses) similar to keyboard shortcuts in Figma. Made harder by the table rows cycling different colors
  • How to deal with sections with variants?

Checklist

  • Remove my personal notes from the code :D
  • Remove changes contributed by my local autoformatter ... look into how is formatting setup on the project? I would expect it to do the right thing and play nicely with auto-save formatters (I have ESLint + prettier extensions)
  • Add a default setting in VSCode (off by default), allow toggle on the cheatsheet side
  • I have updated the docs and cheatsheet
  • I have not broken the cheatsheet

[Outside the scope of this PR]
Would be most effective when combined with a re-work of the cheatsheet structure. Grouping by what commands do, popularity, common non-obvious commands, for instance 'change tree instances' etc. I imagine there have been a number of discussions on this already.

Sorry, something went wrong.

@bra1nDump bra1nDump marked this pull request as draft December 10, 2023 21:36

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
- Removed copied over typing info (but added a new dependency to engine :D )
- Added dummy comments identifying code to possibly change / participating code
- Cleaning up some of my notes
- Using real default spoken form info for debugging purposes instead of dummy data that doesn't help debugging the usage stats in cheat sheet feature
@bra1nDump bra1nDump force-pushed the cheatsheet-usage-stats branch from d57add0 to b0262ef Compare December 12, 2023 02:49
@pokey pokey changed the base branch from main to commandHistory December 12, 2023 14:33
AndreasArvidsson and others added 11 commits December 14, 2023 03:53
…a (basic stats extraction)

- extracting stats from command history with a big switch + generators
- added run action to vscode to run the cheatsheet-local build + open generated html in browser
- in webpack debug build injecting default (real dev data!! Will be checked in! is this ok?)
- did super basic ui for the stats - appears along the command
- discovered many single modifiers represent multiple versions in the spoken form (e.g. "[scope] forward" and "[scope] backward" are backed by the same modifier relativeScope on the extension side)
- removed flat mapping and sorting alphabetically
    - Also removed section sorting - TODO: Actually put this one back
    - I think we should sort from basic -> advanced
    - I also think we should maintain sections - for example relativeScope versions should be groupped together
- TODO: discuss how to track usage of tricky modifiers. My suggestion is to ignore this and just track the overall modifier usage
- TODO: Add setting to the extension to toggle usage showing in cheatsheet off/on. Also include the setting in the cheatsheet itself
- TODO: Like figma - have a toggle to higlight things unused completely
@pokey
Copy link
Member

pokey commented Dec 14, 2023

I'm curious what you expect to gain by this feature. Are you interested in finding actions / scopes you're not using?

@bra1nDump
Copy link
Collaborator Author

bra1nDump commented Dec 15, 2023

@pokey Yes, the original idea is to discover features I'm not using. For new users this can serve as gamification for tracking their progress.

While implementing this I think a more impactful contribution is to improve cheat sheet contents

Call me lazy, but I just want the cheatsheet to be my one stop shop for pretty much anything after I learned the basics from documentation / watching YouTube videos

@pokey
Copy link
Member

pokey commented Dec 18, 2023

I think we decided to hold off on this direction for now, right? Any reason not to close this one out for now?

@bra1nDump bra1nDump closed this Dec 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants