sindresorhus/opn

Do you want to work on this issue?

You can request for a bounty in order to promote it!

support new format data:text/html #208

g8up posted onGitHub

data:text/html;charset=utf-8,${html} can be render by chrome. maybe it can be supported.

eg.

"C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --args --new-window --app="data:text/html,<h1>Hello</h1>"


Any update on this?

posted by mmahalwy almost 4 years ago

As I delete the quotes in --app, and test it under Win10 64bit, It works!😀

const open = require('open');

open('', {app: {name: 'chrome', arguments: ['--new-window', `--app=data:text/html,<h1>Hello</h1>`]}})

@mmahalwy

posted by g8up almost 4 years ago

oh nice @g8up ! Love it!

posted by mmahalwy almost 4 years ago

Can't find a solution for MacOS

posted by fritx over 2 years ago

I wrote an alternative solution here which creates a temporary file before calling open(): https://github.com/olalonde/open-html

posted by olalonde about 2 years ago

Fund this Issue

$0.00
Funded
Only logged in users can fund an issue

Pull requests