Has anyone tried to create a desktop Meteor application, in a similar way to how NW.js / node-webkit (http://nwjs.io/) does for font-end frameworks?
If so, what sort of success have you had? I’m about to start working on some of the administration features of my web app and there’s no need to have it online, plus the guys that will be using it are generally happier with it being a desktop app. So this is something I could consider if it was available…?
I’m happy you bring up this topic. I already thought about that and did some research. I found people playing around with demeteorize (from Modulus) which basically isn’t made for this of course but seemed to partly work.
But probably this is something that MDG could think about supporting directly. I think there could be quite some use cases where local applications could be useful at JS definitely is coming to the desktop too these days and having Meteor there could be a real value.
Desktop apps written in Javascript (sort-of like the Cordova model for Mobile) (as Siyfion mentions in the original post nw.js)
Native Desktop implementations that use parts of Meteor’s stack, like DDP.
For 1. This guy has a great post that lists solutions like TideSDK, AppJS, (he doesn’t mention Atom Shell, which looks good) and that Windows 8 and 10 have built-in support for Native Runtime apps built with Javascript. http://clintberry.com/2013/html5-apps-desktop-2013/
A quick StackOverflow and Github search shows there’s been interest and probably success in doing things this way for desktop… It’d be great to hear if anyone has had real success with this approach.
For 2. I’ve also heard of the implementation of DDP in Objective-C that people are using with ios apps and which I suppose could be used for a Mac app. There’s also a less-developed implementation of DDP out there for C#. You’d basically develop your desktop app as normal, but have it use the native implementations of DDP for the data.
I would think using nw.js for desktop apps would be a better approach. It’s easier for cross-platform building and has been proven to perform well enough for a majority of desktop applications. But, yes, I love the idea of being able to run meteor add-platform desktop and boom. Desktop application.
Would using Meteor with Webix be an interesting alternative? Webix is a UI components library made specifically for desktop apps (but also works nicely on mobile); sort of a modern-day ExtJS/Dojo with a Material Design theme. It’s highly concise and expressive - check out the 10-lines of code demo at http://webix.com.
You could package it as a Chrome app for more of a desktop experience.
PS: the Webix demo linked from my repo is a bit broken now, but don’t let that deter you. I’ll fix it over the weekend. Plenty of good Webix demos at http://webix.com/demos/.
That wouldn’t necessarily make it a desktop application though. It is a web application that is packaged as a chrome app. I was thinking more along the lines of a desktop native-like experience like nw.js offers by giving users a downloadable executable.
I think for macs we should try https://github.com/MacGapProject/MacGap1 which is what Slack is currently using for their Mac app. I never tried it so I don’t know if it would work with meteor apps.
My use case for a desktop app is has these requirements:
– 100% distributed to end users on a USB thumb drive.
– run on Mac or PC with no installation required of dependencies like NodeJS.
– All data is also on the thumb drive, it needs to work offline.
– End users are not technical at all. Grandma should be able to use it without calling tech support.
Not at all, nwjs can do all of the above or you could give a try to atom shell. The biggest problem/roadblock is Meteors build system, which is not ready to pack for “platform desktop”. Maybe a PR for platform desktop using nwjs.
Create a meteor directory in that workspace for your regular meteor app.
Change the main.js file to open an atom-shell window that loads your meteor app by modifying this line: mainWindow.loadUrl('http://localhost:3000');
Run the meteor dev server cd meteor && meteor so it listens on port 3000.
Run the app with ./Atom.app/Contents/MacOS/Atom your-app/ .
Deploying is a bigger challenge. You’ll need to modify main.js quite a bit more and use child_process to start the meteor and mongo servers before calling loadUrl. This is how we did it: https://github.com/kitematic/kitematic/blob/v0.4.5/index.js