Generators: add ability to destroy generated files
See original GitHub issueIn Rails there is a destroy
command that acts as the evil twin of generate
:
rails generate scaffold Post
rails destroy scaffold Post
Let’s do the same thing in Redwood. The generators themselves just return a list of files/routes so we should be able to use those lists in a destroy
process to remove the files created and match and remove the routes.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:3
- Comments:10 (7 by maintainers)
Top Results From Across the Web
C# Source Generators Remove Files Before Build
An easy work around for this is to remove the generated types from compilation. This is not desired because the devs will loose...
Read more >Allow overriding generator template files · Issue #8914 · nrwl/nx
I would like for consumers to know which files are created from the generator (including the ability to copy the template, so they...
Read more >Saving source generator output in source control
In this post I show how to emit your source generator output to disk, so you can include it in source control and...
Read more >How to Use Generators and yield in Python
In this step-by-step tutorial, you'll learn about generators and yielding in Python. You'll create generator functions and generator expressions using ...
Read more >Python Generators (With Examples) - Programiz
Example 2: Python Generator Expression ... Here, we have created the generator object that will produce the squares of the numbers 0 through...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@antonmoiseev That would be amazing
Can I help with finishing this up? I’ve quickly prototyped
destroy
command for a couple of components, it looks like something I could do.