Comments (8)
Things I'm not excited about:
- how transient and imperfect each of those API is
- documenting them and releasing breaking versions more often than this module requires
- external contributions (or lack thereof)
- the slowing of RG’s development due to having them externally and having to consider third parties
- having to also extract every internal function that those helpers use, further slowing RG’s development
I wouldn't be totally opposed to publishing a "gh extensions utils" package but I'd probably suggest using npm install refined-github/refined-github
in order to access those files directly instead.
from github-url-detection.
I'll add, even if we go to the trouble of doing all of that, it doesn't mean it actually helps that many people. See how many repos use this very simple, very old package:
https://github.com/refined-github/github-url-detection/network/dependents
Here's the total of 2 non-fork non-ghosttown extensions that use it:
- https://github.com/ineo6/git-master/search?q=github-url-detection
- https://github.com/hypertrons/hypertrons-crx/search?q=github-url-detection
I'd argue we didn't even need to extract github-url-detection
. 😃 The only reason it's still great to have is that it makes it easier to test it and work on it.
from github-url-detection.
I think we can extract it to be its own module, I like how simple this one is no need to complicated it.
@refined-github/maintainers thoughts?
from github-url-detection.
To be fair, I think most github-helpers
are useful on their own1, like get-user-avatar
. But let's not overcomplicate things 😅 this issue only considers branch name related stuff.
Footnotes
-
maybe one day I extract them to modules myself, that's MIT for you ↩
from github-url-detection.
The only reason it's still great to have is that it makes it easier to test it and work on it.
Exactly why we extracted, the tests took too much time.
from github-url-detection.
@fregante Really good points. I agree it's too much hassle for those simple helpers, I brought up about this one because I think it's an exception:
- There are projects that could benefit from it
- It (mostly) fits in this package
- More people using it, more/faster bugs are found
from github-url-detection.
maybe one day I extract them to modules myself, that's MIT for you ↩
Well be glad to host them. That's refined-github for you 🤪
from github-url-detection.
PR welcome to add those two:
- utils/github-url.ts
- utils/get-current-committish.ts
from github-url-detection.
Related Issues (20)
- Add `isSingleGistCode`
- Add `typed-query-selector/strict` locally to ensure selectors are valid
- Include example URLs in JSDocs HOT 1
- `hasRenderedText` (markdown etc)
- Add `?url=http://etc` to the demo
- Use meta tags in isRepoPublic
- `isOrganizationRepo` is broken due to new search
- `isFileFinder` should include `/tree/*/?search=1` HOT 1
- Update vite once they fix a bug
- Publish script broken? HOT 1
- `isArchivedRepo` broken on Global navigation update HOT 1
- Potentially use new `route-pattern` meta tag HOT 1
- `isReleasesOrTags` !== `isReleases || isTags` HOT 2
- `isPRFiles` doesn't include "PR Files with single commit selected" HOT 1
- `/user/repo?search=1` should not match `isRepoRoot` nor `isRepoHome`
- New discussions are not included in `hasRichTextEditor`
- Add `isGistFile`
- Add `/dashboard-feed` to `isDashboard`?
- `isRepoRoot()` return false if the repository doesn’t have a description
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from github-url-detection.