mirror of
https://github.com/vale981/tridactyl
synced 2025-03-04 17:11:40 -05:00
Fix jsonview with about:blank newtab
This commit is contained in:
parent
64c3547034
commit
c07b9bf216
1 changed files with 1 additions and 1 deletions
|
@ -4267,7 +4267,7 @@ export function viewconfig(...key: string[]) {
|
|||
*/
|
||||
//#background
|
||||
export async function jsonview(...json: string[]) {
|
||||
const tab = await tabopen("-w")
|
||||
const tab = await tabopen("-w", browser.runtime.getURL("static/newtab.html"))
|
||||
const url = "data:application/json," + encodeURIComponent(json.join(" "))
|
||||
return browser.tabs.executeScript(tab.id, { code: `window.location.href = "${url}";` })
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue