true Usage

Om.xml dependency dependent effect inside the element tag optional

For example, the introduction of dependent parent project

<dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
            <optional>true</optional> <!-- 表示依赖不会传递 -->
        </dependency>

Then the child can not inherit the project introduced spring-boot-devtools

Avoid relying on the conflict, if it is false in case it will not set the optional introduction of inheritance

Published 22 original articles · won praise 21 · views 10000 +

Guess you like

Origin blog.csdn.net/corleone_4ever/article/details/104021435