diff --git a/src/renderer.js b/src/renderer.js index 87cd24e..1b87c47 100644 --- a/src/renderer.js +++ b/src/renderer.js @@ -7,7 +7,7 @@ console.log('test'); // const url = 'file://C:\\Users\\JISAUAY\\Documents\\misc\\sspm\\test.ogg'; // const path = 'C:\\Users\\JISAUAY\\Documents\\misc\\sspm\\ChangelingForest.mp3'; -const libPath = 'C:\\Users\\JISAUAY\\Documents\\misc\\sspm\\test-library\\' +const libPath = './test-library/' // const player = new Audio(url); @@ -17,8 +17,7 @@ const libPath = 'C:\\Users\\JISAUAY\\Documents\\misc\\sspm\\test-library\\' // console.log(info); // }; async function getLibraryFiles() { - const dirInfo = await window.api.readMusicLibrary(libPath); - console.log(dirInfo); + return await window.api.readMusicLibrary(libPath); } @@ -26,6 +25,11 @@ document.addEventListener('DOMContentLoaded', async () => { const libContentDisplay = document.getElementById('libContents'); let files = await getLibraryFiles(); + console.log(files); + + for (const file_i in files) { + libContentDisplay.innerHTML += `