问题
I want to navigate via href in <a> elements in electron.
Which works like a charm in Firefox throws following exception in Electron/Chromium: Not allowed to navigate top frame to data URL
The element (transformed via XSLT stylesheet from an XML, so I can't really change it) looks e.g. like this: <a href="#idPFMOB">Mobility</a> where the element with the id idPFMOB is an <h2>-Tag.
As I said, this works in Firefox when I open the file there, but throws given exception in Chromium.
Is there a fix for it? I can't really use the <iframe> workaround suggested here
来源:https://stackoverflow.com/questions/54946393/navigate-on-same-page-via-element-id-in-electron