Closed mashaal closed 9 years ago
nm- I found a solution using https://www.npmjs.com/package/open
Hi, just out of curiosity, your need was opening the url from the client or server side of your meteor app?
And how you ended up doing, with this package you found?
I have a link-sharing feature in my app, and wanted to open in browser (using target=blank opens in a new electron instance). I found that adding the NPM package (https://github.com/meteorhacks/npm), along with the Open package (linked above), that I can create a meteor method on the server that will then open in the default browser.
open = Meteor.npmRequire('open')
Meteor.methods 'link': (url) ->
open(url)
return
Oh I see, very nice.
Tks for the infos.
Loading the entire npm package AND another package just to open a link seems awfully inefficient. Surely there must be a simpler way.
Thanks for this package- I'm trying to open links defined in my app in the user's default browser. I found this electron documentation, but unsure if it's possible call from meteor side?
https://github.com/atom/electron/blob/master/docs/api/shell.md