Warning
This package is no longer maintained. It will not receive updates, fixes or support. PostHTML itself can be used directly: https://github.com/posthtml/posthtml
npm i -S electron-posthtmlThis modules intercepts the file:// Protocol using Electrons Protocol API. All HTML files will automatically processed by PostHTML.
'use strict'
import { app, BrowserWindow } from 'electron'
import posthtml from 'electron-posthtml'
// Use PostHTML
posthtml([/* Plugins */])
app.on('ready', () => {
const view = new BrowserWindow({ width: 800, height: 600 })
view.loadUrl(`file://${__dirname}/index.html`)
})|
Michael Ciniawsky |
See PostHTML Guidelines and contribution guide.