-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
fix: generate types for create fuels
users when extracted
#3175
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Skipped Deployment
|
CodSpeed Performance ReportMerging #3175 will improve performances by 41.67%Comparing Summary
Benchmarks breakdown
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but I wonder we should add a pretest
equivalent build step that will generate these at least every build (perhaps at the root of the templates folder) if not each time we make a change to typegen or we when we release a new fuels
version, otherwise we could run the risk of these becoming outdated
Good catch @maschad but this will be slightly more tricky than our usual |
@Dhaiwat10 I think we should always generate and override all files while not shipping pre-generated files in our repo. For example, we can have one If I got it right, @maschad meant adding something like: {
"scripts": {
"pretest": "fuels build",
},
} |
@arboleya two questions:
|
|
@Dhaiwat10 essentially yes, what I am suggesting is a workflow that will:
|
types-pr-screen.mp4@petertonysmith94 this video should demonstrate the purpose of this PR. As you can see, the |
Coverage Report:
Changed Files:
|
Beautiful video @Dhaiwat10, thanks for that. What screen grabber do you use to record this? |
Summary
Currently, the artifacts generated by typegen are ignored by git. But in order for someone to deploy their dapp's frontend to the cloud, they will need these artifacts to be included in their git repo - if they follow the instructions listed on our Deploying to Testnet guide.
There is no other way to deploy the frontend since we deprecated the built-in binaries for users. This is why we need to remove these artifacts from the gitignore of the template, and include them in the source.
This PR generates these types for users when the template is extracted, and removes these files from gitignore, hence 'fixes' our deploying to testnet guide.
Checklist