Importaciones no utilizadas
qmllint denomina esta categoría de advertencia « [unused-imports] ».
Importación no utilizada
¿Qué ha pasado?
Has utilizado una instrucción de importación para importar un módulo QML, pero no has utilizado ninguno de sus tipos.
¿Por qué es un problema?
La instrucción de importación establece una dependencia con un módulo QML que, en realidad, no es necesario. Esto afecta a la legibilidad del código y al rendimiento del motor QML y de las herramientas, ya que les obliga a procesar un módulo QML innecesario.
Ejemplo
import QtQuick
import QtQuick.Controls
Item {}Para solucionar esta advertencia, elimina la importación que no se utiliza:
import QtQuick
Item {}© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.