Skip to content

Commit d19aeb1

Browse files
authored
Add isProjects (#102)
1 parent 37b0777 commit d19aeb1

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

index.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,11 @@ collect.set('isProject', [
182182
'https://github.com/sindresorhus/refined-github/projects/3',
183183
]);
184184

185+
export const isProjects = (url: URL | HTMLAnchorElement | Location = location): boolean => getRepo(url)?.path === 'projects';
186+
collect.set('isProjects', [
187+
'https://github.com/sindresorhus/refined-github/projects',
188+
]);
189+
185190
export const isDiscussion = (url: URL | HTMLAnchorElement | Location = location): boolean => /^discussions\/\d+/.test(getRepo(url)?.path!);
186191
collect.set('isDiscussion', [
187192
'https://github.com/tophf/mpiv/discussions/50',

0 commit comments

Comments
 (0)