• Practical Redux, Part 0: Introduction
  • Originally written by Mark Erikson
  • The Nuggets translation Project
  • Translator: luoyaqifei
  • Proofreader: Xuxiaokang, Richardo2016

Practice Redux, Part 0: Introduction

The beginning of a series of Redux technology summaries based on personal experience

Series directory

  • Part 0: Series introduction
  • Part 1: Redux-ORM Fundamentals
  • Part 2: Redux-ORM concepts and techniques

I spent a lot of time learning about Redux and consulted many different sources. Much of my early learning came from reading documents, searching online tutorials, and lurking in Reactiflux chat channels. As I became more familiar with Redux, I gained some experience answering questions and researching how to help Reactiflux, StackOverflow, and others on Reddit. In maintaining my React/Redux linked list and the Redux plugin directory, I tried to find articles that delve into the complexities and problems of creating real-world applications, as well as libraries that would make writing Redux applications easier. Finally, I studied it through the myriad issues and discussions in the Redux warehouse (as a result, I even became Redux’s official maintainer).

In addition to all this research, I also spent most of the last year using Redux in my work application. In the process of developing this application, I encountered various challenges and developed some interesting tools and techniques in the process. Since I’ve learned so much from others’ articles, I wanted to start giving back and share some of what I’ve learned from my own experience.

This series of articles on “Practicing Redux” will include tips, techniques, and concepts I used to develop my own applications. Since I can’t really share the specifics of development at work, I’ll create a few sample scenarios to help me illustrate these ideas. I’ll take a look at examples derived from concepts in the Battletech game universe:

  • Battlemech is a flying walking robot equipped with a variety of weapons such as missiles, lasers and automatic guns. A Battlemech has one pilot.
  • There are several different types of Battlemech. Each type has a different size and a set of data Settings, including the weapons and other equipment it carries.
  • Battlemech is organized into groups of four MECH, each known as “Lance”. The three Lance forms a company.

As the series progresses, I hope to actually start creating a small application that shows some examples in a real working environment. Tentative plans are for an app to track pilots and their MEChs serving in virtual combat units, like a miniature version of the existing MekHQ game activity tracking app. These screenshots from MekHQ show some of the concepts and UI I wanted to emulate:

  • MekHQ: List of available pilots and details of selected pilots
  • MekHQ: Organization tree of mech and pilots in the army
  • MekHQ: Battlemech details and statistics

I certainly don’t want to strictly reconstruct a MekHQ, but it should serve as a source of inspiration and ideas from which my example will be built.

The first two articles will discuss ways to use the Redux-ORM library to help manage canonical state. In these articles, I hope to discuss ways to manage “draft” data (data generated during entry editing, tree view creation, form entry, and other situations). In the meantime, I plan to discuss some topics that aren’t exclusive to Redux.

I’d love to hear from you, whether it’s in the comments, on Twitter, in Reactiflux, or elsewhere!