Closed FormalSnake closed 8 months ago
It only sets it on one Desktop. Here is my code:
import { getWallpaper, setWallpaper } from "wallpaper"; import fs from "fs" var files = fs.readdirSync('./wallpapers/') const options = { screen: 'all' }; export function changePaper(){ let img = "wallpapers/" + files[Math.floor(Math.random() * files.length)] setWallpaper(img, options) console.log(img) } changePaper()
Duplicate of https://github.com/sindresorhus/wallpaper/issues/31
It only sets it on one Desktop. Here is my code: