Trying to use an image in a TypeScript 2 file like this:
import image = require("../assets/images/image.jpg");
Results in the following error:
[at-loader] ./src/components/app.tsx:3:30
TS2532: Object is possibly 'undefined'.
How can I safely utilize an asset without risking it being undefined? Keep in mind, I do not want to ignore the warning.