TS2686

'ko' refers to a UMD global, but the current file is a module. Consider adding an import instead.

Broken Code ❌

const downloadProgress = ko.observable();

Fixed Code ✔️

import ko from 'knockout';
 
const downloadProgress = ko.observable();

'sinon' refers to a UMD global, but the current file is a module. Consider adding an import instead.

Broken Code ❌

import { SinonFakeServer } from 'sinon';
let server: SinonFakeServer;

Fixed Code ✔️

import * as sinon from 'sinon';
let server: sinon.SinonFakeServer;

'React' refers to a UMD global, but the current file is a module. Consider adding an import instead.

Broken Code ❌

import { FC } from 'react';
 
const App: FC = (): JSX.Element => {
  return <></>;
};

Fixed Code ✔️

Use default import for React:

import React from 'react';
 
const App: React.FC = (): JSX.Element => {
  return <></>;
};