pkg
pkg copied to clipboard
chore: refactor dictionary handling
Moves dictionary files into a single object in a file, this should reduce bundle size and slightly improve performance because we'll be directly importing the dictionary object, skipping the middleman, so to speak.
I tried to reuse some of the types, but it seems some of them are unused or not quite up to date with the current code, so I updated them as well and tried to match it with the current code as much as possible.
cc @jesec
@ignatiusmb WOuld like to know @jesec opinion on this before merging
Another pair of eyes never goes wrong 😄
This pull-request is stale because it has been open 90 days with no activity. Remove the stale label or comment or this will be closed in 5 days. To ignore this pull-request entirely you can add the no-stale label
What's left to do?
The "not understandable" reference was to existing code and variable naming, which you (rightly) continued to follow, not a comment on your code specifically. I'm just looking for the code quality to improve more while you are touching these parts of the code.
I'm just looking for the code quality to improve more while you are touching these parts of the code.
I would love to do that, but the changes here are already huge as it is, I would prefer to have that in a separate PR as it may get out of scope if we start touching a lot of unrelated code here.
can you clarify what problem you are trying to solve? [...] on one hand, it is nice to have the modules in their own separate files, since they do not relate to one another. Changes in one module file should not be part of the history when looking at another module. This pulls them all into one mega-file. Granted, they don't change often, so churn should be low.
To keep it simple and consistent in one file and type-checked with TypeScript, make it easier to add or amend patches in the future, and reduce inefficient path
concatenation and fs
calls.
~~Test failures seems unrelated?~~ Good thing we have tests.
This pull-request is stale because it has been open 90 days with no activity. Remove the stale label or comment or this will be closed in 5 days. To ignore this pull-request entirely you can add the no-stale label
This pull-request is now closed due to inactivity, you can of course reopen or reference this pull-request if you see fit.