The BFF Pattern (Backend for Frontend): An Introduction

The BFF Pattern (Backend for Frontend): An Introduction

The BFF Pattern (Backend for Frontend): An Introduction - Imagine a scenario where you need to build an e-Commerce application using microservices. You may have microservices for Customers, Orders, Products, Shopping carts, etc. The microservices will exposes APIs to be used by the frontend.

Get to know the benefits of using the BFF pattern in practice

Imagine a scenario where you need to build an e-Commerce application using microservices. You may have microservices for Customers, Orders, Products, Shopping carts, etc. The microservices will exposes APIs to be used by the frontend.

However, the data returned to the frontend by the Microservices may not be formatted or filtered according to the exact way the frontend needs to represent them.

In that case, the frontend needs to have some logic on its own to re-format these data. Having such logic in the frontend will use up more browser resources.

In a situation like this, we can use a BFF in order to shift some of this front-end logic to an intermediate layer. The intermediate layer is the BFF. When a frontend requests some data, it will call an API in the BFF.

The BFF will do the following.

  • Call the relevant microservices APIs and obtain the needed data
  • Format the data based on the frontend representation
  • Send the formatted data to the frontend

microservices javascript

Bootstrap 5 Complete Course with Examples

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

Building a simple Applications with Vue 3

Deno Crash Course: Explore Deno and Create a full REST API with Deno

How to Build a Real-time Chat App with Deno and WebSockets

Convert HTML to Markdown Online

HTML entity encoder decoder Online

Hire Dedicated JavaScript Developers -Hire JavaScript Developers

Hire dedicated JavaScript Developers who are proficient in AngularJS, ReactJS, NodeJS, & VueJS frameworks. Get flexible hiring models as per your business requirements.

JavaScript Shopping Cart - Javascript Project for Beginners

JavaScript Shopping Cart - javascript shopping cart tutorial for beginnersBuy me a coffee 🍺 https://www.paypal.com/paypalme/ziddahSource Code: https://bit....

The essential JavaScript concepts that you should understand

The essential JavaScript concepts that you should understand - For successful developing and to pass a work interview

Popular JavaScript Frameworks to Build API and Microservices

In this post, we will discuss the most popular JavaScript frameworks used to build APIs and Microservices.

Testing Microservices Applications

In this article, look at different ways to test microservices and how you can have a suitable testing strategy to begin with.