Exclude/ignore paths and contentTypes


#1

Hi.

I’m currently adding a contentSelector to a part, and as far as I know there are options to allowPath and allowContentType. But is there any way to instead exclude content types and paths/paths and children? If not, this would be a very useful feature!

I.e. I have a site with a sub-site in another language, and I would like the contentSelector in the top-level site to ignore all content from the sub-site.


#2

Old issue and still not aplied hahaha


#3

I think Mads has a better use case. In the linked case I would add the content selector as a mixin to only have to add new content types once.

Blacklisting would only invert the problem, as every time a new content type is added (possibly also through other apps?) that you do not want added, you need to blacklist it everywhere. Whitelisting ensures you know how to handle the particular content type. Blacklisting could lead to unwanted results…


#4

Interesting requirement @mads , you would like to ignore content from subsites. Any suggestions on how such a configuration could look?


#5

I agree that the use cases are a lot more limited in terms of content types it_vegard. Although I do see a possibility that there might exist some specific cases where you only want to blacklist a few specific content types, while allowing the rest.

However, my case is more related to paths. My problem is that I want all content in the top-level site to be available in the content selector, while any content from sub-level sites are ignored. I am certainly not sure how to solve that issue, but from the top of my head I remember that I was looking for some option similar to the ‘:not’ css pseudo-selector. Now, I don’t know the possibilities and limitations, but something like the following?
<allowPath> ${site}/* </allowPath>
<notAllowPath> ${site}/subsite <notAllowPath>

or even as part of the current configuration:

<allowPath> not: ${site}/subsite </allowPath>
<allowPath> ${site}/* not: ${site}/subsite </allowPath>


#6

We plan to add a query parameter to make this more flexible.


#7