Skip to content

Sample State

Michelle Naim edited this page Oct 14, 2020 · 6 revisions
{
  entities: {
    movies: {
      1: {
        id: 1,
        title: "The Silence Of The Lambs",
        description: "FBI trainee Clarice Starling ventures into a maximum-security asylum to pick the diseased brain of Hannibal Lecter, a psychiatrist turned cannibal.",
        year: 1991, 
        rating: "R", 
        runtime: "1h58", 
        url: "https://www.youtube.com/watch?v=W6Mm8Sbe__o&ab_channel=MovieclipsClassicTrailers", 
      },
      2: {
        id: 2,
        title: "Enola Holmes",
        description: "While searching for her missing mother, intrepid teen Enola Holmes uses her sleuthing skills to outsmart big brother Sherlock and help a runaway lord.",
        year: 2020, 
        rating: "PG 13", 
        runtime: "2h03", 
        url: "https://www.youtube.com/watch?v=1d0Zf9sXlHk&ab_channel=Netflix", 
      },
      3: {
        id: 3,
        title: "The Irishman",
        description: "Hit man Frank Sheeran looks back at the secrets he kept as a loyal member of the Bufalino crime family in this acclaimed film from Martin Scorsese.",
        year: 2019, 
        rating: "R", 
        runtime: "3h29", 
        url: "https://www.youtube.com/watch?v=RS3aHkkfuEI&ab_channel=Netflix", 
      },
    },
    users: {
      11: {
        id: 11,
        email: "pink_elephant@gmail.com",      
      },
      25: {
        id: 25,
        email: "blue_dino@hotmail.com",
      }
    },
    genre: {
      1: {
        id: 1,
         name: "Horror",      
      },
      2: {
        id: 2,
         name: "Thriller",      
      },
      3: {
        id: 3,
         name: "Drama",      
      },
      4: {
        id: 4,
         name: "Fiction",      
      },
    }
    moviegenre: {
      1: {
        id: 1,
        genreId: 1, 
        movieId: 1,
      },
      2: {
        id: 2,
        genreId: 2, 
        movieId: 1,
      },
      3: {
        id: 3,
        genreId: 4, 
        movieId: 2,
      },
      4: {
        id: 4,
        genreId: 3, 
        movieId: 3,
      },
    }
    list: {
      1: {
        id: 1,
        userId: 11, 
        movieId: 3,
      },
      2: {
        id: 1,
        userId: 11, 
        movieId: 2,
      },
      3: {
        id: 3,
        userId: 25, 
        movieId: 1,
      },
    }
  },
  ui: {
    loading: true/false
  },
  errors: {
    login: ["Incorrect email/password combination"],
  },
  session: { currentUserId: 25 }
}

Clone this wiki locally