You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I'm trying to write perf test but TS throws error
import{intercept}from'@salutejs/perftool';// long non-standard importimporttype{PerftoolComponent}from'@salutejs/perftool/dist/client/measurement/runner';exportconstDefault: PerftoolComponent=()=>{return<div></div>;};Default.beforeTest=async()=>{awaitintercept({method: 'GET',responseType: 'file',// TS2322: Type "file" is not assignable to type FakeResponseType | undefinedsource: '**/some.client.js',response: 'public/js/some.client.js',});};
I tried to use FakeResponseType directly, but its value is not exported from the package...
I can write something like this, but it looks like workaround but not as intended.
Describe the solution you'd like
Would be great if you add export of FakeResponseType object and type PerftoolComponent, so I will be able to just import them as usual:
Is your feature request related to a problem? Please describe.
I'm trying to write perf test but TS throws error
I tried to use
FakeResponseType
directly, but its value is not exported from the package...I can write something like this, but it looks like workaround but not as intended.
Describe the solution you'd like
Would be great if you add export of
FakeResponseType
object and typePerftoolComponent
, so I will be able to just import them as usual:Describe alternatives you've considered
Or you may allow to pass common strings
'file' | 'json' | 'abort'
instead ofconst enum
The text was updated successfully, but these errors were encountered: