Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support Afdian as a provider #29

Merged
merged 5 commits into from Dec 30, 2022
Merged

feat: support Afdian as a provider #29

merged 5 commits into from Dec 30, 2022

Conversation

ModyQyW
Copy link
Contributor

@ModyQyW ModyQyW commented Dec 29, 2022

Description

Afdian (爱发电) is one of the most popular sponsor platform in China. Will be nice to support Afdian.

Linked Issues

None

Additional context

I don't think of any.

@antfu antfu changed the title feat: support Afdian feat: support Afdian as a provider Dec 30, 2022
@antfu antfu merged commit b285d79 into antfu-collective:main Dec 30, 2022
throw new Error('Afdian id and token are required')

const sponsors: any[] = []
const sponsorshipApi = 'https://afdian.net/api/open/query-sponsor'
Copy link
Contributor

@YunYouJun YunYouJun Jan 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have also implemented an afdian provider myself.

I used afdian-api. I think that might be more concise.

https://github.com/YunYouJun/sponsors/blob/master/kit/providers/afdian.ts

@antfu If you think that's better, I'd be happy to create a pr for that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would the current code work for you? I would prefer not to add a new dependency if possible.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's OK. It works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants