Open-sourcing Flipper: a new extensible debugging tool

One challenge that comes from having many engineers working collaboratively on larger apps is that typically no single person knows how every module works. This segmentation of knowledge and expert…

Emil Sjölander
5 min readintermediate
--
View Original

Overview

The article discusses the open-sourcing of Flipper, an extensible cross-platform debugging tool developed by Facebook to help engineers manage complexity in app development. It highlights Flipper's features, its architecture, and the benefits of using it over previous tools like Stetho.

What You'll Learn

1

How to use Flipper to inspect the structure and behavior of mobile applications

2

Why Flipper is preferred over Stetho for debugging mobile apps

3

How to create custom plugins for Flipper

Prerequisites & Requirements

  • Understanding of mobile application development concepts
  • Familiarity with React and Electron(optional)

Key Questions Answered

What is Flipper and how does it help engineers?
Flipper is an extensible debugging tool that allows engineers to inspect and understand the structure and behavior of their iOS and Android applications. It provides a visual and interactive experience, making it easier to develop features, investigate bugs, and optimize performance.
What are the main components of Flipper's architecture?
Flipper consists of a desktop client and a mobile SDK. The desktop client, built on Electron, interacts with the mobile SDK installed in the application, which transmits data for debugging purposes.
How can engineers extend Flipper's functionality?
Engineers can extend Flipper by creating custom plugins. A desktop client plugin is developed using React, while a mobile SDK plugin is created in the platform's native language, allowing for a wide range of tools tailored to specific needs.
What are some use cases for Flipper in mobile app development?
Flipper has been used to provide engineers with accurate view hierarchies, surface GraphQL requests, and track performance markers in real-time, enhancing the debugging process and improving app performance.

Technologies & Tools

Some links below are affiliate links. We may earn a commission if you make a purchase.

Frontend
Electron
Used to build the desktop client of Flipper.
Frontend
React.js
Utilized for developing the UI components of the desktop client plugins.
Backend
Rsocket
Used in both the mobile SDK and desktop client for data transmission.
Tools
Yarn
Used for managing dependencies in the Flipper project.
Backend
Folly
Utilized within the mobile SDK for performance optimization.

Key Actionable Insights

1
Utilize Flipper for real-time performance tracking to identify bottlenecks in your mobile applications.
This allows developers to quickly address performance issues as they arise, improving overall application efficiency and user experience.
2
Leverage Flipper's extensibility by creating custom plugins tailored to your project's specific debugging needs.
By building plugins, you can enhance Flipper's capabilities, making it a more powerful tool for your development team.
3
Transition from Stetho to Flipper for a more interactive and visual debugging experience.
Flipper offers improved features and a richer user experience, making it a better choice for modern mobile app development.

Common Pitfalls

1
Neglecting to explore Flipper's plugin architecture can limit your debugging capabilities.
Many engineers may stick to default tools without realizing the potential of custom plugins, which can significantly enhance their debugging process.