-
Notifications
You must be signed in to change notification settings - Fork 365
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generate .d.ts file #609
Comments
I think you're trying to load ts file with a js loader. If you use webpack, by default it will treat files in node_modules as js. |
@krzkaczor thank you, let me check, but in case if I want to have .d.ts file? What should I do ? |
Yes. TC generally (apart from factories...) generates only typings. You need to create runtime object and later cast it to the desired type. Here are some examples:
Also you might find eth-sdk useful if you're interacting with already deployed, mainnet contracts. |
thank you @krzkaczor |
Hi there,
As I understand, from now typechain only generate .ts file instead of .d.ts file, but when I try to import .ts file , I always get error below. And if I want to use .d.ts file? How could I generate that with current newest version ?
The text was updated successfully, but these errors were encountered: