Files
feeddeck/supabase/functions/_shared/models/source.ts
Rico Berger 8c88ece3dc [lemmy] Add Support for Lemmy (#94)
This commit adds support to add Lemmy RSS feeds to FeedDeck. A user can
provide the url of an Lemmy instance, the url of a community or of an
user.

The special thing of the Lemmy source in opposite to the normal RSS
source is, that we parse the provided link form a feed item, to check if
it contains a image, video or YouTube url, to apply some special
formatting.
2023-12-02 15:52:50 +01:00

50 lines
1001 B
TypeScript

import { ISourceOptionsGithub } from './sources/github.ts';
import { ISourceOptionsGoogleNews } from './sources/googlenews.ts';
import { ISourceOptionsStackOverflow } from './sources/stackoverflow.ts';
export type TSourceType =
| 'github'
| 'googlenews'
| 'lemmy'
| 'mastodon'
| 'medium'
| 'nitter'
| 'pinterest'
| 'podcast'
| 'reddit'
| 'rss'
| 'stackoverflow'
| 'tumblr'
| 'x'
| 'youtube'
| 'none';
export interface ISource {
id: string;
columnId: string;
userId: string;
type: TSourceType;
title: string;
options?: ISourceOptions;
link?: string;
icon?: string;
updatedAt?: number;
}
export interface ISourceOptions {
github?: ISourceOptionsGithub;
googlenews?: ISourceOptionsGoogleNews;
lemmy?: string;
mastodon?: string;
medium?: string;
nitter?: string;
pinterest?: string;
podcast?: string;
reddit?: string;
rss?: string;
stackoverflow?: ISourceOptionsStackOverflow;
tumblr?: string;
x?: string;
youtube?: string;
}