feat: added m3u handler support

This commit is contained in:
ner committed 2025-08-23 21:44:57 +03:00
1 parent f78af76da5
commit 3460041115
3 files changed
+43 -4

No files matched your search

+12
View File
@@ -0,0 +1,12 @@
import { useAtomValue, useSetAtom } from 'jotai';
import { atomWithStorage } from 'jotai/utils';
import { STREAM_URL } from '@/env';
const M3UUrlAtom = atomWithStorage<string>('M3U url', '', undefined, {
unstable_getOnInit: true
});
export const useSetM3UUrl = () => useSetAtom(M3UUrlAtom);
export const useM3UUrl = () => useAtomValue(M3UUrlAtom);