mirror of
https://github.com/pheralb/svgl.git
synced 2025-12-29 08:01:36 +08:00
10 lines
226 B
TypeScript
10 lines
226 B
TypeScript
interface SourceParams {
|
|
url: string | undefined;
|
|
}
|
|
|
|
export const getSource = async (params: SourceParams) => {
|
|
const response = await fetch(params.url || '');
|
|
const content = await response.text();
|
|
return content;
|
|
};
|