max397574 / better-escape.nvim

Map keys without delay when typing
GNU General Public License v3.0
629 stars 19 forks source link

refactor: add more comments and rename variables #76

Closed Sam-programs closed 3 months ago

Sam-programs commented 3 months ago

Since there were some bugs recently, and the code was hard to read, I decided to review it and

TODO: fix: clear_mappings' position (Currently, it clears the mappings of the new config, not the old config) TODO: move pcall to be inside of clear_mappings, so that it doesn't crash(stop deleting mappings) if mapping gets deleted twice (it gets deleted twice when it's a startkey and an endkey). TODO: remove sequences because we can use the settings.mappings table instead. I will do the TODO:s in other prs later.

@max397574, Since this is a breaking change for all other prs, if you are working on the plugin right now, don't merge this.

max397574 commented 3 months ago

tell me when you're done with the todos so I can then take another quick look and merge looks really nice so far 👍

Sam-programs commented 3 months ago

tell me when you're done with the todos so I can then take another quick look and merge

I am gonna do the todos in other prs after this is merged, so that we can revert the individual prs without reverting this one.

looks really nice so far 👍

Thanks.

max397574 commented 3 months ago

so this would be good to merge as is from your side?

Sam-programs commented 3 months ago

Yes.

Sam-programs commented 3 months ago

Of course, I messed up the branch, and now, it has a million duplicated commits.

max397574 commented 3 months ago

seems like a messed up rebase imo the simplest would be to just go there, copy the whole file, create a new branch from master, past, commit, open new pr

imo this change isn't so big that the history would be important