rescript-lang / rescript-lang/rescript-vscode
Added the command of overwriting interface files
Nobody has claimed this yet.
- Dominant language
- ReScript
- Stars
- 354
- Forks
- 63
- Avg merge
- 11h 29m
- Merged PRs (30d)
- 1
Description
Added the command of overwriting interface files
I need to update the .resi interface file from time to time while using the plugin. However, in each operation, I had to delete the old file before using the plug-in command to create a new .resi interface file, which was really uncomfortable. Therefore, I have the following improvement requirements.
- When a
.resifile exists, the command can override the contents of the original file. - If the file does not exist, the
.resifile is created, and the behavior is the same as that of creating an interface file.
In terms of implementation
I looked at the source code, and adding a command doesn't add much complexity.
Other things
I am very sorry that I have not learned the TS code, so I cannot submit the relevant code implementation. Thank you very much for your earnest and dedication.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with client/src/commands/create_interface.ts, the command source named in the issue. Trace how it handles an existing .resi file and a missing one, then verify that existing files are overwritten while missing files retain the current creation behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript, vscode
- Domain
- developer-experience, tooling
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100