I haven’t read anything for a long time. I’ve been cooped up at home for two weeks. I finally have some time to think.

Recent plans

I’ve been doing some work on Flutter recently and have compiled a set of “Flutter strategies” that will make you walk sideways in front of the product.

The purpose of doing these things, is actually in the process of learning, thinking, and the architecture of technical solution and at the same time, the study of the existing schemes, and summed up a set of best practices, to me is not only a raise, also to others in the process of practice, can have very good guidance, if can have a practice feedback, will let me get feedback.

This series, can be found in the public menu, I hope to help you.

The UI component library

Although I have written a lot of articles on Android and Flutter’s UI, I will not be doing any of the open source so-called “UI component libraries”.

For developers, in the company of no company UI library can be perfect in another company (except for a few small startups, of course, don’t care about the UI style, just function implementation), why, because the design style of an App, is often linked with company, from the color, components, interaction, Large companies have formed a system of its own style, so, if you want to do a set of open source component library, then certainly will need to increase the vast number of configurations, various colors, shapes and shadows, and so on, these things once formed configuration, increase the complexity of the components will be unlimited, even if these things, and within a company, may be a one-time setup, But to make a universal UI component library, you need to add a lot of boring configuration.

So, my perception of “UI component library” is the company interior design style is unified on the basis of implementing a “company level UI component library”, so that the basic components of the style is actually a fixed, also need not too many configuration, also easy to maintain, more importantly, it is redundant, they don’t have those fancy configuration, also no useless functions.

For such a set of “UI component library”, there is no need to open source, what I did is to teach it, learn the design method of component library, implement a set of company-level component library, it is not difficult.

firefighters

There used to be a joke:

Marquis Wen of Wei asked Bian Que, “Which of your three brothers is the best in software development?” Bian Que said, “Eldest brother is the best, second brother is the next, and I am the worst.” The Marquis was puzzled. Bian explained: “My brother has been well considered in the design stage, so there is no room for bugs. The second brother solved the Bug as soon as it appeared, so the reputation did not spread to the technical department. Every day, I put out fires everywhere like whack-a-mole. Sometimes, I solved a bug and introduced a new bug. KPI was filled in a straight line and my name was widely known.

The result: Because the eldest brother came off work on the hour every day instead of staying up late to work overtime, and he did not look busy at work, the leader thought that he did not agree with the corporate culture, did not do his best to create value for the company, and was marginalized.

The joke is always a joke, but it also illustrates the difficulty of technical people. How do you measure the value of a development?

A team, definitely not like “que” firefighters, they can have time on the first line of fire, find problems and solve the problem, but a team, certainly not like “eldest brother, second brother” development, if everyone can have a development like the quality, so the fire come from?

I hope there is no disease in the world

Shanggong cures no illness, but “shanggong” needs a bole who can resist downforce and find out who is really “shanggong”.

circle

Recently, I found a strange problem that many mobile developers are very resistant to Flutter and Compose. This can be seen from the dozens of Flutter articles I recently posted. The number of Flutter articles read is less than half that of the ads, and the “drop rate” is even higher than the ads.

Perhaps many of them are still stuck in native development, relying on the technology used for several years to continue to muddle through, but the fact is cruel, traditional native development, no longer meet the needs of today’s development.

For a small company, Flutter can quickly trial and error, without losing the performance of the native development, more can improve the efficiency of doubling, for a large company, Flutter in some special UI requirements, have more abundant than native and easy implementation, at the same time, that type of design patterns, has gradually become the mainstream of the development of a few years later, Whether you use Flutter or Compose, this is a hurdle that must be overcome.

So there’s no need to worry about how many “{}” there is in Flutter, or why Flutter has chosen the “Dart” language, or why Flutter can’t do thermal updates. If you don’t understand these questions, try lowering your posture. Try to understand the design of Flutter first, and then examine your question.

For now, Flutter is the only promising direction I can see among many cross-platform technologies.

These new technologies are always welcomed as honey, and hated as arsenic. There is no need to try to convince others of your point of view, time will tell.

Standardization of business code

It’s really a question of whether business code is difficult to write.

In my opinion, business code is not difficult to write, but the difficulty is to write business code like a dead dog.

After you’ve been around a company long enough, you can even gain the ability to guess whose code it is based on its code style.

Yes, different programmers, when coding, have their own style, is likely to be named style, also may be code style, and even the annotation style, over time, you will be able to “see the code is the person”, so different people, in fulfilling the needs of the business, will also have a different approach, so many different approaches, relative merits and how to judge?

In most cases, it’s a matter of “time”. The longer someone has been with the company, the greater the chance that their code will be copied as a template.

A company still needs such a role to standardize the standardized process of business code, such as an information list display interface, from loading to network request, from data display to paging, whether to use LiveData, ViewModel or Flow, and how adapter and Activity interact. Status bar, dark mode processing, pull-down refresh, pull-up loading, the specific code of these business related processes how to write, a hundred Hamlets, must also be unified in one writing method.

Some would argue that even having to write all of this code is completely limiting development.

Business code is not about individual performance, it’s about “stability”, “stability”, or “f * * king stability”.

Once business processes are standardized, there are no problems caused by individual play, and development becomes the tool man who screws up the assembly line. Aren’t you fucking limiting your personal development?

In fact, if you are new, then in skilled screw, you can learn this process very well, this set of time tested, after everyone repeatedly deliberate process, can let you learn a lot. So if you are the big guy, you can better improve the process, introduce Flow, replace the IMPLEMENTATION of RxJava, introduce VB, VM, etc.

Realizing this process is like the “strategic layout” in a battle. Once the core strategy is determined, it is not so important whether to fight “Jinzhou” or “Shenyang”. You can play to your advantages on the basis of the strategy.

However, the formulation of this “strategy” is a rigorous process, which not only requires the participation of team members, but also requires everyone to review the plan round by round, and finally form a plan approved by all members. In this way, in the process of advancing, we can make everyone united.

The standardization of business code is not to make everyone become tool people, but to enable all levels of development to quickly and steadily meet business requirements, give play to their expertise, and do something they love to do.

I would like to recommend my website xuyisheng. Top/focusing on Android-Kotlin-flutter welcome you to visit