KT.INVALID_PACKAGE_DECLARATION

File location does not match the declared package

Reports when the file location does not match the declared package.

Options

  • rootPackage (default: ``)

    if specified this part of the package structure is ignored

  • requireRootInDeclaration (default: False)

    requires the declaration to start with the specified rootPackage

The content on this page is adapted from the Detekt Docs. Copyright ©2022 The Detekt Team. All rights reserved. https://detekt.dev/comments.html