Skip to main content

7 posts tagged with "how-to"

View All Tags

· 3 min read
Wen Bo

Originally published on strongloop.com

Part 7: Wrap-Up​

In This Episode​

This is the final episode of this series. We've used LoopBack 4 to build an online web text-based adventure game. We've built the foundation with LoopBack, and I am going to summarize what we have achieved so far, and how can you apply all of this to your own project.

What We Have Achieved​

In episode 1, we created a simple APIs. You can do the same to create a start point for your own project, for example, a student registration system which has a student model with properties like studentId, name, major, and course. Then we connected our project to MongoDB. You have the freedom to choose any database you want. LB4 supports most databases very well.

· 16 min read
Wen Bo

Originally published on strongloop.com

Part 6: Front-end with React​

In This Episode​

Now our project is on IBM Cloud. But you may notice there is not anything that we can actually play with. It's just some APIs. How can we call it a game without front-end UI?

In this episode, I will build signup, login, and home pages with React.

You can check here for the code from this episode.

· 9 min read
Wen Bo

Originally published on strongloop.com

Part 5: Deploying our Application to Kubernetes on IBM Cloud​

In This Episode​

Now that our project has basic features that allow us to create our own characters and log in, it's time to deploy it to cloud! So, we will first run our project in Docker and then push it to Kubernetes cluster on IBM Cloud.

Docker images are lightweight, portable, and self-sufficient. Once you create a Docker image, you can run it almost everywhere. On the other hand, Kubernetes will handle those high level concepts such as storage, network and scale-up.

You can check here for the code from this episode.

· 16 min read
Wen Bo

Originally published on strongloop.com

Part 4: User Authentication and Role-Based Access Control​

In This Episode​

We already have some APIs that allow users to customize their characters. However, a user should not get access to characters that belong to other users. With that in mind, we will add user authentication and role-based access control to this project.

You can check here for this episode's code.

· 8 min read
Wen Bo

Originally published on strongloop.com

Part 3: Customizing APIs in Controller​

Introduction​

In this series, I’m going to help you learn LoopBack 4 and how to use it to easily build your own API and web project. We’ll create a new project I’ve been working on: an online web text-based adventure game. In this game, you can create your own account to build characters, fight monsters and find treasures. You will be able to control your character to take a variety of actions: attacking enemies, casting spells, and getting loot. This game also allows multiple players to log in and play with their friends.

Previously on Building an Online Game With LoopBack 4​

In the last episode, we used a third-party library to generate UUID and built relations between character, weapon, armor, and skill.

Here are the previous episodes:

· 9 min read
Wen Bo

Originally published on strongloop.com

Part 2: Generating Universally Unique ID and Managing Models Relationships​

Introduction​

In this series, I’m going to help you learn LoopBack 4 and how to use it to easily build your own API and web project. We’ll create a new project I’ve been working on: an online web text-based adventure game. In this game, you can create your own account to build characters, fight monsters and find treasures. You will be able to control your character to take a variety of actions: attacking enemies, casting spells, and getting loot. This game also allows multiple players to log in and play with their friends.

Previously on Building an Online Game With LoopBack 4​

In the previous episode, we created a foundation for our project. Now we have some basic APIs to create, edit, and delete a character.

Here is the previous episode:

· 10 min read
Wen Bo

Originally published on strongloop.com

Part 1: Building a Simple LoopBack Project With MongoDB​

Introduction​

"Ready to build amazing things?" asks the LoopBack 4 homepage before encouraging you to try the open source framework.

"Try LoopBack 4 now."

In this series, I'm going to do exactly that! Join me as I create an API web game using LoopBack 4.