mirror of
https://github.com/cheveguerra/bot-whatsapp.git
synced 2026-04-20 20:49:15 +00:00
docs: ⚡ added contributors
This commit is contained in:
@@ -1,20 +1,23 @@
|
|||||||
import { component$, Resource, useResource$ } from '@builder.io/qwik'
|
import { component$, Resource, useResource$ } from '@builder.io/qwik'
|
||||||
import Collaborator from './Collaborator'
|
import Collaborator from './Collaborator'
|
||||||
import { Octokit } from '@octokit/core'
|
|
||||||
|
|
||||||
export const octokit = new Octokit({
|
export const apiGetCollaborators = async () => {
|
||||||
auth: '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',
|
const data = fetch(
|
||||||
})
|
`https://api.github.com/repos/codigoencasa/bot-whatsapp/contributors`,
|
||||||
|
|
||||||
export const apiGetCollaborators = () =>
|
|
||||||
octokit.request(
|
|
||||||
'GET /repos/codigoencasa/bot-whatsapp/contributors{?anon,per_page,page}',
|
|
||||||
{
|
{
|
||||||
owner: 'OWNER',
|
method: 'GET',
|
||||||
repo: 'REPO',
|
headers: {
|
||||||
|
Accept: 'application/vnd.github+json',
|
||||||
|
'X-GitHub-Api-Version': '2022-11-28',
|
||||||
|
Authorization:
|
||||||
|
'Bearer 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',
|
||||||
|
},
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
return (await data).json()
|
||||||
|
}
|
||||||
|
|
||||||
export const TaleUsers = component$((props: { users: any[] }) => {
|
export const TaleUsers = component$((props: { users: any[] }) => {
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
@@ -30,7 +33,7 @@ export const TaleUsers = component$((props: { users: any[] }) => {
|
|||||||
|
|
||||||
export default component$(() => {
|
export default component$(() => {
|
||||||
const collaboratorsResource = useResource$(
|
const collaboratorsResource = useResource$(
|
||||||
async () => await (await apiGetCollaborators()).data
|
async () => await apiGetCollaborators()
|
||||||
)
|
)
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@@ -13,11 +13,6 @@ export default defineConfig(() => {
|
|||||||
qwikCity({
|
qwikCity({
|
||||||
basePathname: SITE.basePathname,
|
basePathname: SITE.basePathname,
|
||||||
trailingSlash: SITE.trailingSlash,
|
trailingSlash: SITE.trailingSlash,
|
||||||
mdxPlugins: {
|
|
||||||
rehypeSyntaxHighlight: true,
|
|
||||||
rehypeAutolinkHeadings: false,
|
|
||||||
remarkGfm: true,
|
|
||||||
},
|
|
||||||
}),
|
}),
|
||||||
qwikVite(),
|
qwikVite(),
|
||||||
tsconfigPaths(),
|
tsconfigPaths(),
|
||||||
|
|||||||
Reference in New Issue
Block a user