How do you store data server side that is specific to a client in Meteor?

后端 未结 6 821
陌清茗
陌清茗 2021-02-13 02:15

Express implements a server side session object that lets you store data specific to a client. How would you do the equivalent in Meteor?

strack recommended using a coll

6条回答
  •  日久生厌
    2021-02-13 02:51

    The user-session smart package I wrote for Meteor is designed exactly for this. It provides all the methods of the Meteor Session API (with the exception of setDefault), and some additional ones as well. It's reactive, and all the changes are persistent. Best of all, it's available both on the client, and on the server with an additional userId argument.

提交回复
热议问题