The reason of getting this error may because of the behavior of the backing field. It is private by default and the field identifier can only be used in the accessors of the property. That's why you got @ViewById cannot be used on a private element.

The reason of why lateinit works is because it change the accessibility of the field. According to Kotlin doc:

Late-Initialized properties are also exposed as fields. The visibility of the field will be the same as the visibility of lateinit property setter.

So, @JvmField is another solution for this problem.

@JvmField var helloTextView: TextView? = null

It also changes the visibility of the field as what the doc states:

If you need to expose a Kotlin property as a field in Java, you need to annotate it with the @JvmField annotation. The field will have the same visibility as the underlying property. You can annotate a property with @JvmField if it has a backing field, is not private, does not have open, override or const modifiers, and is not a delegated property.

You may also refer to this example and Kotlin docs about Android frameworks using annotation processing.