-
Notifications
You must be signed in to change notification settings - Fork 7
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
Meteor build client-only #6
Comments
@zol maybe the connection could be optional - eg. if bundling for cdn's we might still want the connection but not the hot code push. # No connection - client-only
$ meteor add platform client-only
# For CDN deployment
$ meteor add platform client-only -h "http://my.app.com"
# Or
$ meteor build client-only |
👍 |
👍 With the appearance of DDP on other server stacks, devs using already made server (Wordpress, Prestashop, ...) could switch gradually to Meteor with confidence. Actually, porting DDP to the major other server stack could also really help breakthrough in adoption. |
👍 I suggest to specify just the |
Thanks @Slava its linked under "references" in the top description |
Been a while since I added anything to Meteorpedia... added those initial instructions plus a ref to the intended pattern and this thread at http://www.meteorpedia.com/read/Building_for_the_client_only |
Just a note - would something like
|
I quite like that. Short and sweet. Although I admit I've never had the need for this before, so could be missing something. I'd also suggest |
Hi, Currently if you look into the separating the two this way would help to host meteor on other server infrastructures, or of example to use the meteor ddp connection only for specific actions (even by multiple and native apps) I think this, with the right showcases and tutorials would do a great deal for meteor adoption! |
+1 billion if possible |
+1 |
1 similar comment
+1 |
I would love that as well. I opened a discussion about this on the mailing list some time ago. I think this would be great with combination of WebRTC for DDP protocol so one could use it to talk between browsers directly. A simple list of peers served together with static index.html could make the trick. (That list of peers could be maintained with any other server-side software, much simpler than Meteor or node.js itself.) |
Related: meteor/meteor#1223 |
I found this Standalone Blaze Generator, and tweaked it to bundle minimongo, blaze and session packages in a single js file for the browser, with no sockjs connection error or the need for Haven't tested it at all beyond this example on gh-pages. Is this useful for anyone? Make any sense? |
Looks very good, thanks. Any ideas how to precompile all the templates? Personally i love the meteor command line tool, so i don't have to link, minify, concatenate and require.js all the files ... again. I just found ractive.js, which looks very similar to Spacebars, though i love the reactive helpers and Tracker better. |
Hi, I am making a Cordova app using Meteor to communicate with a bluetooth device. We do not need a server, or any internet connection. I currently plan on just using Meteor.disconnect but that means I would still be shipping connection code even though i am not using it. I want to take this out. How can I do this before submitting to the app store? Thanks in advance! |
I think one approach is to see which packages the Then instead of using But this might not work because a lot of packages actually depend in connection logic as you can I'm talking about core packages. |
A bit tangential, but I made this package once when I needed to compile custom Meteor package and then inject the resulted JS into the client only: https://github.com/peerlibrary/meteor-package-builder Maybe you could use to build the client JS and then use only that. |
My 5 cents... Our use case for client side only build: |
Some of this would be interesting to integrate with Meteor: |
I finally did it myself :) |
@frozeman Can this work to build a cordova mobile app that is for the client only? It looks like it is only for web currently. |
@frozeman Awesome work! 👍 |
@sferoze isn't the meteor native cordova deploy not enough? |
@frozeman Well when you build your app for Cordova you are expected to input a mobile server address. This is because the DDP package is still part of the mobile app. Currently I have in the client code Meteor.disconnect() so the app does not use the DDP package. But this is still not optimal. |
The client side part generated with Its not ideal, but it works. |
This is a great idea. +1 |
Any idea if you can make some kind of routing for client-side only? |
Use iron-router or flow-router. |
Obviously, I forgot to say I don't wanna use meteor for it, just blaze for static content |
Look at my tool: https://www.npmjs.com/package/meteor-build-client This lets you develop you app with meteor, and get on the end static files with index.html ;) |
Hi @sferoze what you put on --server flag when you build meteor cordova client only? |
Fabian Vogelsteller (@frozeman):
I was requesting this feature a while back, but with the new platform system of Meteor it is very possible now.
I would like to have a client-only platform, where it creates a bundle with only the client side files and an "index.html" as start file.
This would allow to host the client side part of a meteor app on any static server, as well as use it in a native app bundler like tideSDK, or Sentenza Desktop.
I would like to see the following command possible:
Which then produces a bundles tar ball containing only the index.html, bundle.js and bundle.css.
This would make meteor also immediately available for people who want to use it as fronted library instead of angularjs (growing user base ;)
Zoltan Olah (@zol):
The outstanding issue is that by default the DDP package assumes there is a server to connect back to. Would MDG be open to changing this behavior - perhaps passing something in via meteor_runtime_config that disables the autoconnect?
Ref:
https://github.com/SpaceCapsule/packmeteor/issues/32
https://groups.google.com/forum/#!topic/meteor-core/Pa2Zi0rA7Sg
The text was updated successfully, but these errors were encountered: