Provide information from Meteor onto a separate static site

I have two websites. My meteor application, and my static information site.

The static site uses plain HTML, JS, and jQuery, without Meteor.

Basically, I want to display the length of a collection (the number of items) from my Meteor app on my static website.

What would be the easiest way to acomplish this? is working pretty well.

edit: or which is lower level but lighter.

Not sure what you are looking for, but it seems to me, that your current static site is just delivered from server to browser. So no scripting or background processing. That would make it a little more complicate to get values from meteor for you.

You may add DDP to your static client and script connection etc. but why not do it the easy way.

Just deliver your static web site from meteor. You will just create one template around your current page. Then you can use for example all the blaze options to access all meteor vars.

My suggestion to you.


To clarify. I have two websites:

  • A meteor application
  • A static site, using python SimpleHTTPServer

I want to deliver a number from the meteor application, to the static (SimpleHTTPServer) site.

I am aware you can use a meteor call to get the value to a client page, and jQuery to change the value on the static site, but how do I get the number from the application to the static site.

@therealnate try this:

Then you can call a method on your Meteor app server using jQuery, and display the result.

1 Like