import { defineStore } from 'pinia'
const useMessageRoomStore = defineStore('useMessageRoomStore', {
  state: () => ({
    messageRoom: {
      id:undefined,
      createUserId:undefined,
      content:[]
    }
  }),
  actions: {
    setMessage(item) {
      if (this.messageRoom.content.length >= 35) return
      this.messageRoom.content.push(item)
    },
    resetList(obj){
      this.messageRoom = obj
    }
  }
})


export default useMessageRoomStore