Angular 9 can't bind to 'x' since it isn't a known property of 'y'

Ran into a very strange problem while migrating from Angular 8 to 9. Angular 9 requires certain base classes to be decorated with at least @Directive() in order for the compiler to have necessary metadata.

error NG8002: Can't bind to 'label' since it isn't a known property of 'checkbox-input'.

This was the error I was receiving after upgrading to Angular 9. The ng update tool is smart enough to find undecorated base classes and inject a @Directive(), but for some reason it missed one element-base.ts base class that was used by custom form controls.

Spent two days trying to find the reason, then I looked at the imports

import { Input } from "../../../node_modules/@angular/core";
This was the issue

For some reason the Input was imported in a weird archaic way, possibly by a very old VSCode. After fixing the import the error went away.

import { Input, Directive } from "@angular/core";
import { ControlValueAccessor } from "@angular/forms";

export abstract class ElementBase<TValue> implements ControlValueAccessor {}