mirror of
https://github.com/janishutz/MusicPlayer.git
synced 2026-09-10 14:25:24 +02:00
18 lines
294 B
TypeScript
18 lines
294 B
TypeScript
export const useMusicKit = () => {
|
|
const init = () => {
|
|
isInit = true;
|
|
};
|
|
|
|
let isInit = false;
|
|
|
|
if ( !window.MusicKit ) {
|
|
document.addEventListener( 'musickitloaded', () => {
|
|
init();
|
|
} );
|
|
} else {
|
|
init();
|
|
}
|
|
|
|
return {};
|
|
};
|