ampli pull should generate typescript file with "// @ts-nocheck"

  • 26 December 2022
  • 10 replies

I used ampli to generate typescript file.


But generated file does not pass our typescript checker.

(Error will vary based on tsconfig.json)

I would be nice generated typescript file contains “// @ts-nocheck” to skip typescript check

10 replies

Userlevel 6
Badge +9

Thanks for this idea @Beren. I’ve just submitted it to the team for review! 😁


seeing this too, any updates on this issue ?


Userlevel 5
Badge +8

@Tom Hollander apologies for the delay! I’ve asked the technical support team for an update on this!

Userlevel 5
Badge +9

Hello @Tom Hollander happy to help!

Would you mind providing the following information, please?

  • What version of the Typescript SDK are you running?
  • What is the version of the Ampli CLI?

"typescript": "4.0.8",

@amplitude/ampli/1.31.5 darwin-arm64 node-v12.22.12

Userlevel 5
Badge +9

Hello @Tom Hollander thank you for the information!

Currently working with the engineering team on this. By chance do you have a screenshot of the error you’re seeing? 


Hope to hear from you soon!



when generating the ampli wrapper , we get this ts error in the code in the ‘load’ method -> “Property 'configuration' does not exist on type '{ configuration?: BrowserOptions; }”


Userlevel 5
Badge +9

Hi @Tom Hollander thank you so much for your help thus far! I have a couple of action items for you to try,


  1. Could you please try changing the /* tslint:disable */ at the top of /ampli/index.ts to be // @ts-nocheck? Let me know if that helps with the current file that is returning the error.
  2. If the above does not work, engineering released an update to resolve this behavior. You can do ampli pull and the issue shouldn’t be there. 


For #1 would be good for us to know if you could do us the favor in trying that out. Thank you!

Userlevel 5
Badge +9

@Tom Hollander Happy Friday! If you were able to try #1 above please let us know the results :) 


Hey Eddie,

  1. ampli pull fixed it , thanks!