Skip to content

Sample State

theimberger edited this page Oct 23, 2017 · 1 revision
{
  entities: {

    users: {
      id: {
        id: 1,
        username: "Sam",
        channels: [...channelIds...],
        messages: [...messageIds...]
      }
      ...
    },

    channels: {
      id: {
        id: 1,
        title: "Company Chat",
        description: "a chat for company",
        users: [...userIds...],
        messages: [...messageIds...]
      },
      ...
    }

    messages: {
      id: {
        id: 1,
        body: "Hi sam.",
        channel: channelId,
        author: userId
      },
      ...
    }
  },

  ui: {
    dropdowns: [ ... active dropdowns ...]
  },

  errors: {},

  session: {
    id: id,
    username: "sam",
  }

}
Clone this wiki locally