I am writing a React/TypeScript project that uses Azure Media Player. Per the docs under Referencing the Player, I should be able to reference the player like this:
var myPlayer = amp('vid1');
I then get a compiler error:
TypeScript error in C:/<file path>/<file name>.tsx(47,17):
Cannot find namespace 'amp'. TS2503
I see that this is a TypeScript error, but the docs are written for JavaScript.
So I try TypeScript:
let player: amp.Player = amp("player");
Same compiler error.
How do I reference the AMP player in my React/TypeScript project?