I am completely new to electron.js. I am trying to run this code:
const { app, BrowserWindow } = require("electron");
const createWindow = () => {
const win = new BrowserWindow({
width: 800,
height: 600,
});
win.loadFile("index.html");
};
app.whenReady().then(() => {
createWindow();
app.on("activate", () => {
if (BrowserWindow.getAllWindows().length === 0) createWindow();
});
});
app.on("window-all-closed", () => {
if (process.platform !== "darwin") app.quit();
});
When I run it, it does open a window and display the contents of the HTML-file correctly. In the console I get a lot warnings though:
/snap/core20/current/lib/x86_64-linux-gnu/libstdc++.so.6: version `GLIBCXX_3.4.29' not found (required by /lib/x86_64-linux-gnu/libproxy.so.1)
Failed to load module: /home/jan/snap/code/common/.cache/gio-modules/libgiolibproxy.so
Warning: /usr/lib/i386-linux-gnu/libvulkan_lvp.so: wrong ELF-class: ELFCLASS32
Warning: loader_icd_scan: Failed loading library associated with ICD JSON /usr/lib/i386-linux-gnu/libvulkan_lvp.so. Ignoring this JSON
Warning: /usr/lib/i386-linux-gnu/libvulkan_intel_hasvk.so: wrong ELF-class: ELFCLASS32
Warning: loader_icd_scan: Failed loading library associated with ICD JSON /usr/lib/i386-linux-gnu/libvulkan_intel_hasvk.so. Ignoring this JSON
Warning: /usr/lib/i386-linux-gnu/libvulkan_intel.so: wrong ELF-class: ELFCLASS32
Warning: loader_icd_scan: Failed loading library associated with ICD JSON /usr/lib/i386-linux-gnu/libvulkan_intel.so. Ignoring this JSON
Warning: /usr/lib/i386-linux-gnu/libvulkan_radeon.so: wrong ELF-class: ELFCLASS32
Warning: loader_icd_scan: Failed loading library associated with ICD JSON /usr/lib/i386-linux-gnu/libvulkan_radeon.so. Ignoring this JSON
Although the code works I feel that I should solve the warnings. I have been on it all day and apart from pointing me to some issue with gcc compiler, neither google nor stackoverflow have helped me so far.