Compilation warning handling: autoprefixer: start value has mixed support, consider using flex-start instead

Chapter 1 Problem Analysis

  • When the project is started, there is this warning on the console:

  • It does not affect normal operation, but it is very awkward for programmers to see these errors and warnings. So how do we solve it?

        ​​​—View warning location:

        -In this file, then we go to the file to find a question: 

  1. module warning: template warning
  2. postcss-loader: css processor
  3. I translated this sentence. It actually means that start is replaced by flex-start.

          css, start, flex-start, indicating the error reported in the style. flex-start uses the retractable layout flex, so let's search for:

I found that justify-content: start was written, and there were many similar ones. Obviously, they caused it! !

        -The change: All changes:

        - The warning is removed 

Chapter 2 Problem Summary

When justify-content and align-items are in telescopic layout: their starting position and end position distribution based on the main axis/side axis are flex-start and flex-end. This is the standard way of writing, and it can be achieved even if we write start and end. Effective, but it is easy for us to misunderstand. At the same time, we will habitually write like this in the future, which can easily make us develop bad writing habits.

at last! ! Standard writing is also important! !

Guess you like

Origin blog.csdn.net/qq_45796592/article/details/134239996