got a lot working

This commit is contained in:
JISAUAY committed 2024-10-21 10:00:30 -05:00
1 parent e0fcf3326e
commit a7bd278b4a
11 files changed
+166 -36

No files matched your search

+38 -4
View File
@@ -1,6 +1,40 @@
// const { fromUrl } = require('id3js');
// const { fromUrl } = id3js;
// import fromUrl from id3js;
console.log('test');
const player = new Audio('file://C:\\Users\\JISAUAY\\Documents\\misc\\sspm\\test.mp3');
player.play().catch(e =>
console.error("Audio play failed with " + e)
);
// 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 player = new Audio(url);
// let info = window.api.getAudioInfo(url);
// const test = async function() {
// const info = await window.api.getAudioInfo(path);
// console.log(info);
// };
async function getLibraryFiles() {
const dirInfo = await window.api.readMusicLibrary(libPath);
console.log(dirInfo);
}
document.addEventListener('DOMContentLoaded', async () => {
const libContentDisplay = document.getElementById('libContents');
let files = await getLibraryFiles();
});
// fromUrl(url).then((tags) => {
// console.log(tags);
// });
// player.play().catch(e =>
// console.error("Audio play failed with " + e)
// );
// https://www.debugandrelease.com/the-ultimate-electron-guide/ seems decent