Add generated files to a different path #922
amoghyermalkar123
started this conversation in
General
Replies: 1 comment 1 reply
-
If you're using VSCode it's possible to use the nesting functionality to 'hide' the generated files (while still allowing access if required). Add the following into the VSCode config: "explorer.fileNesting.enabled": true,
"explorer.fileNesting.expand": false,
"explorer.fileNesting.patterns": {
"*.templ": "${basename}_templ.*",
}, Example: I also use this to hide what I call meta files in the root of the project, things like go.mod, go.sum, tailwind.config.js, env files etc. by using this rule: ".meta": "go.*, *.yml, .git*, *.ts, *.md, *.json,*.js,Dockerfile*,.env,*.env,*.txt, *.service, *.http,*.sh,*.csv, *.toml,*.db, LICENSE" This ends up giving me access but keeping the root looking clean: Simply create an empty file named Bear in mind that the nesting is only visual, no files were harmed or moved in the nesting process. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is there any way where i can seperate my .templ files from my autogenerated _templ.go files? After a certain point as the project gets a bit bigger/ modular, the generated files all start cluttering my tree view of the folder structure.
If i can hide them that would also work but i guess the better way would be for me to provide a flag with a folder path to keep the generated files in, if i dont care about their package.
Any ideas/ ways?
Beta Was this translation helpful? Give feedback.
All reactions