meteorhacks / inject-data

A way to inject data to the client with initial HTML
MIT License
18 stars 28 forks source link

Meteor@1.4 + doesn't work any more #13

Open parhelium opened 7 years ago

parhelium commented 7 years ago

Example from docs :

Picker.route("/", function(params, req, res, next) {
  var ejsonData = {aa: 10};
  InjectData.pushData(res, "some-key", ejsonData);
  // make sure to move the routing forward.
  next();
});

AND

InjectData.getData("some-key", function(data) {
  console.log(data);
});

doesn't work. On client data is undefined and should be {{aa:10}}

What is more important, this bug breaks FastRender !

parhelium commented 7 years ago
screen shot 2016-12-07 at 09 29 19
theosp commented 7 years ago

Use the great fork by @abecks .

https://github.com/abecks/meteor-inject-data

https://atmospherejs.com/staringatlights/inject-data

Thanks @abecks !

-Daniel