Skip to content

Instantly share code, notes, and snippets.

View sebakerckhof's full-sized avatar

Seba Kerckhof sebakerckhof

  • Happy Rainbow Factory
  • Belgium
View GitHub Profile
import { Meteor } from 'meteor/meteor';
import { Tracker } from 'meteor/tracker';
import { useEffect } from 'react';
const hashSubscriptionArguments = (pubName, args) => EJSON.stringify([pubName, args]);
const contexts = new Map();
const getOrCreateSubscription = (pubName, args) => {
const subHash = hashSubscriptionArguments(pubName, args);