anychan icon indicating copy to clipboard operation
anychan copied to clipboard

Repackaging this application for PWA/Native

Open BradKML opened this issue 4 years ago • 3 comments

Google has made this feauter in https://developer.chrome.com/blog/new-in-chrome-73/

Progressive Web Apps provide an installable, app-like experience, built and delivered directly via the web. In Chrome 73, we've added support for macOS, bringing support for Progressive Web Apps to all desktop platforms - Mac, Windows, Chrome OS and Linux, as well as mobile, simplifying web app development.

A Progressive Web App is fast, and reliably so; always loading and performing at the same speed, regardless of network connection. They provide rich, engaging experiences via modern web features that take full advantage of the device capabilities.

BradKML avatar May 09 '21 04:05 BradKML

Hmmm, so we don't need to learn Electron anymore? I was planning on making an Electron version of this app in order to circumvent the limitation of having to go through a proxy server (that is not compatible with Google ReCaptcha by the way). I have a "universal app" feature planned for after I finish message posting API. That could come somewhere late summer I guess. Thx for the tip.

catamphetamine avatar May 09 '21 12:05 catamphetamine

In some sense, yes, Electron is obsolete, however since it is a PWA it does not package every asset in one pre-downloaded application (which is why it is good for media apps but not JS-based utilities).

BradKML avatar May 09 '21 12:05 BradKML

Actually, looks like "Progressive Web Applications" don't ignore the CORS stuff so I guess it's not an option then.

Looks like Electron does have an option to ignore CORS: https://github.com/electron/electron/issues/23664

Something like:

app.commandLine.appendSwitch('disable-features', 'OutOfBlinkCors');

or:

const mainWindow = new BrowserWindow({
  webPreferences: {
    webSecurity: false
  }
})

catamphetamine avatar May 09 '21 14:05 catamphetamine