Ghost/ghost/member-events
2023-02-16 22:15:50 +00:00
..
lib
test
.eslintrc.js
index.js
package.json Update dependency c8 to v7.13.0 2023-02-16 22:15:50 +00:00
README.md

Member Events

Usage

const {MemberEntryViewEvent} = require('@tryghost/member-events');

const event = MemberEntryViewEvent.create({
    memberId: member.id,
    memberStatus: member.status,
    entryId: post.id,
    entryUrl: post.url
});

const DomainEvents = require('@tryghost/domain-events');

DomainEvents.dispatch(event);