Morning, we want to use the MediaQueryObserver method from a typescript file.
Based on the official documentation, "MediaQueryObserver" is available for version 2.11.1 and higher. When we check our version with: wx.getSystemInfoSync ().SDKVersion it shows 2.18.0, however, the wx.createMediaQueryObserver method is not available. This is what is detailed on the IDE
Property 'createMediaQueryObserver' does not exist on type 'Wx'.ts(2339)
Using the IDE version
(env: Windows,mp,1.05.2109222; lib: 2.18.0)
Any hint on how we could WA it? Regards
use this.createMediaQueryObserver
https://developers.weixin.qq.com/miniprogram/dev/reference/api/Component.html#%E5%8F%82%E6%95%B0