[Vuejs]-Vue: Component :prop="object[key]" aren't reactive

0👍

For some reason, removing this initialization code in my beforeCreate fixed it. If someone could provide some insight on why this is the case, I would greatly appreciate it.

  async beforeCreate () {
    let {blobs} = await (await fetch('http://localhost:3000/api/blobs')).json()

    // init tickedEmoji map (fixes code when this loop is removed)
    for (let key of blobs) {
      this.tickedEmoji[key] = false
    }

    this.emoji = blobs
  }

Leave a comment