sindresorhus/refined-github

`latest-tag-button`, `default-branch-button` and `list-prs-for-file` are not fast/reliable enough #3673

fregante posted onGitHub

  1. Visit https://github.com/sindresorhus/refined-github/blob/42dfa16cd5366de26b475de94f8225003df07364/source/features/list-prs-for-file.tsx (or any file with an open PR)
  2. Refresh the page
  3. Wait for each button to appear, if ever

a212

These are 3 separate features but they affect the same area. I think they should be reviewed to understand why they're so slow and why latest-tag-button sometimes doesn't appear at all.

default-branch-button is the most annoying one because it's a simple feature with data that's easily available, it should be instant.


Makes sense! Any API calls should appear before elementReady, or else we definitely wait too long.

posted by fregante over 4 years ago

Here's an error:

refined-github.js:5657 ❌ Refined GitHub → latest-tag-button → TypeError: Cannot read property 'parentElement' of null
    at init (refined-github.js:6078)
    at async runFeature (refined-github.js:5697)
    at async setupPageLoad (refined-github.js:5710)

It can't find #branch-select-menu. It happened on the root of a fork:

https://github.com/fregante/refined-github

posted by fregante over 4 years ago

Fund this Issue

$0.00
Funded

Pull requests