I have made some changes to the MainTemplate files for MVC views under the folder AspNetZeroRadTool/FileTemplates/Client/Mvc. When I run the tool, the template files are changed back to the way they were before I made my changes and the new views are generated without the changes. How can I prevent this from occurring?
2 Answer(s)
-
0
How To Edit Pre-defined Templates Or Create A New Template? The templates are inside "/AspNetZeroRadTool/FileTemplates" directory in your project's root directory. Every template is split into three files: "MainTemplate.txt", "PartialTemplates.txt" and "TemplateInfo.txt". If you want to edit any file, just copy it in same directory and change it's extension to ".custom.txt" from ".txt". For example, you can create "MainTemplate.custom.txt" to override "MainTemplate.txt" in same directory. Please don't make any changes to the original templates.
To create a new template, do the same process as editing a pre-defined template. The tool doesn't know any info about templates and discovers them in the "/FileTemplates" directory every time it is run. This means your new template will be processed like the pre-defined ones. (".custom" extension is not needed for new templates.)
https://docs.aspnetzero.com/documents/common/latest/Development-Guide-Rad-Tool#how-to-edit-pre-defined-templates-or-create-a-new-template
-
0
Holy Moley! I totally missed that nuance. How embarrassing! Thanks!