Book Image

Vue.js 2 Web Development Projects

By : CHAU GUILLAUME
Book Image

Vue.js 2 Web Development Projects

By: CHAU GUILLAUME

Overview of this book

Do you want to make your web application amazingly responsive? Are you unhappy with your app's performance and looking forward to trying out ways to make your app more powerful? Then Vue.js, a framework for building user interfaces, is a great choice, and this book is the ideal way to put it through its paces. This book's project-based approach will get you to build six stunning applications from scratch and gain valuable insights in Vue.js 2.5. You'll start by learning the basics of Vue.js and create your first web app using directives along with rich and attractive user experiences. You will learn about animations and interactivity by creating a browser-based game. Using the available tools and preprocessor, you will learn how to create multi-page apps with plugins. You will create highly efficient and performant functional components for your app. Next, you will create your own online store and optimize it. Finally, you will integrate Vue.js with the real-time Meteor library and create a dashboard showing real-time data. By the end of this book you will have enough skills and will have worked through enough examples of real Vue.js projects to create interactive professional web applications with Vue.js 2.5.
Table of Contents (15 chapters)

Rules of the game


Here are the rules we will implement in the game:

  • Two players play turn by turn
  • Each player starts the game with 10 health, 10 food, and a 5-card hand
  • The players can't have more than 10 health and 10 food
  • A player loses when their food or health reaches zero
  • Both the players can lose in a draw
  • During one player's turn, each player's only possible action is to play a card, which is then put in the discard pile
  • Each player draws a card from the draw pile at the beginning of the turn (except for their first turn)
  • Thanks to the two preceding rules, each player has exactly five cards in their hand when they start their turn
  • If the draw pile is empty when the player draws a card, the draw pile is refilled with the discard pile
  • Cards can modify the health and food of the player or their opponent
  • Some cards can also make a player skip their turn

The gameplay is built around the facts that players must play one and only one card each turn and that most of the cards will have a negative effect...