Skip to content

πŸš€ GitHubTree 0.4

Choose a tag to compare

@mgks mgks released this 02 Apr 00:06
· 1089 commits to main since this release

✨ Features and Improvements:

  • Dynamic Loading Indicator: The "Fetching..." message now dynamically displays the repository and branch being loaded, improving user context and potentially providing more information to crawlers during rendering.
  • SEO-Optimized Metadata: Dynamically generated page titles (<title>) and meta descriptions are now more descriptive and keyword-rich, using the repository name, branch, and description (if available) to enhance search engine visibility for specific repo views.
  • Enhanced Error Handling & Feedback:
    • Implemented more specific error messages for various GitHub API responses (e.g., 401 Unauthorized, 403 Forbidden, 404 Not Found, Rate Limits).
    • Rate limit messages now provide estimated reset times and suggest using a PAT (in private forks) for higher limits.
  • Clearer Truncation Warning: Added a distinct (non-blocking) warning message if the GitHub API indicates the returned tree data was truncated due to repository size.
  • Code Structure: Introduced a getApiHeaders helper function to centralize API request header generation, simplifying PAT integration.
  • Clipboard Functionality: Minor refinement to the copyToClipboard fallback mechanism.
  • ❀️ Support the Project (consider supporting the project via GitHub Sponsors).

🐞 Bug Fixes:

  • Corrected Private Repository Access: Fixed the implementation for using a Personal Access Token (PAT). API calls now correctly include the Authorization header if a PAT is provided in the script.js (intended for private forks only).
  • Improved URL Encoding: Ensured file/directory paths containing special characters are properly encoded in the generated links within the tree view.
  • Robust Empty/Invalid State Handling: Added specific checks and clearer user messages for scenarios like empty repositories (409 Conflict), invalid branches (404/422), or missing tree data.