Skip to content

Instantly share code, notes, and snippets.

Avatar

Sámal Rasmussen samal-rasmussen

  • PIcnic Ventures
  • London
View GitHub Profile
@samal-rasmussen
samal-rasmussen / gist:910ef2238eb5ea81fdca8eeba4ae29d1
Created April 21, 2017 09:16
Simple Rxjs subject load tester
View gist:910ef2238eb5ea81fdca8eeba4ae29d1
const subjectCount = 500000;
const subjects = [];
for(let i = 0 ; i < subjectCount; i++) {
subjects[i] = new Subject();
subjects[i].subscribe(
(next) => console.log('next ' + i + ' ' + next),
(error) => console.log('error ' + i + ' ' + error),
() => console.log('close ' + i)
);
}