Excluding view templates for Spina resources
When creating a view_template
in a Spina CMS Rails app there is an option of exclude_from
that will take an array of strings. For any resources included in this array, that view template will not be available to pages of that resource.
Here is an example:
theme.view_templates = [
{
# The rest of your view template...
exclude_from: ["main", "blog_resource"]
}
]
TweetNote: If you want to exclude templates from being used on main spina pages, you can just exclude from the implicit "main" resource.