Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

opening links in default browser? #5

Closed
mashaal opened this issue Aug 29, 2015 · 5 comments
Closed

opening links in default browser? #5

mashaal opened this issue Aug 29, 2015 · 5 comments
Labels

Comments

@mashaal
Copy link

mashaal commented Aug 29, 2015

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

@mashaal
Copy link
Author

mashaal commented Aug 29, 2015

nm- I found a solution using https://www.npmjs.com/package/open

@mashaal mashaal closed this as completed Aug 29, 2015
@arboleya
Copy link
Owner

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?

@mashaal
Copy link
Author

mashaal commented Aug 31, 2015

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

@arboleya
Copy link
Owner

Oh I see, very nice.

Tks for the infos.

@cosmin-novac
Copy link

Loading the entire npm package AND another package just to open a link seems awfully inefficient. Surely there must be a simpler way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants