Conversation
* Fix(lang/help): wrong pronoun used #102 * refactor(crownicles): dedupe data loaders via cachedPromise helper Replace the promise-cache-and-evict boilerplate, copy-pasted across 6 loaders, with a single cachedPromise() helper in data/source.ts. The five single-value loaders (loadNames, loadItemIcons, loadMapTypeIcons, getCrowniclesMapGraph, getContinentGraph) memoize through it; getItems keeps a per-category Map of memoized loaders. Caching, deduplication of concurrent calls and eviction-on-failure now live in one place. Also drops the now-dead module-level promise variables, restores the export accidentally lost on loadItemIcons, and documents the helper. Closes #58 * refactor(crownicles): share the CrowniclesIcons parser between loaders Extract crownicles-icons-source.ts (ICONS_SOURCE_PATH, fetchIconsSource, extractIconBlock) so the item and map-type icon loaders stop each re-implementing the `} = {` split + brace-matching + pair regex. The key pattern is parameterized (\d+ for item ids, default \w+ for map codes), so behaviour is unchanged. Closes #61 * docs: tidy comments and fill JSDoc gaps The codebase was already well-commented, so this is a focused pass: - document computeLeagueBonusScore (as a Crownicles-formula mirror) and CROWNICLES_LEAGUES / CrowniclesLeague - rewrite the terse CrowniclesMap* interface docs and the HelpState path* field comments (incl. the "choosed" typo); drop the redundant `// BFS` marker - add concise JSDoc to ItemCategory, TitleSize, TextInputStyleName, the /mail modal ids, the reminder result types, pathfinderPage and the mail-repository helpers; move the misplaced homePage doc onto the export Closes #79 Closes #80 Closes #81 Closes #82 Closes #83
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.