Web Audio OfflineAudioContext not found

I’m using ionic 4 with Web Audio feature on iOS.

I need OfflineAudioContext to process the audio file, but it seems not supported.

const sampleRate = 44100;
const audioCtx = new OfflineAudioContext(1, sampleRate, sampleRate);


ReferenceError: Can't find variable: OfflineAudioContext

Is this related to ionic, or iOS webview doesn’t support this? And it also doesn’t work for AudioContext.

What is the full error message?

Thanks. I fixed by adding declare var AudioContext;