Routing example 

A routed attraction detail page, from the content element to the URL. Replace myvendor with your own vendor name.

The content element 

The attraction detail content element wires its CType to the TouristAttractionShow plugin, as all content elements do, see Content element example:

EXT:myextension/ContentBlocks/ContentElements/attraction-show/setup.typoscript
tt_content.myvendor_attractionshow =< lib.contentBlock
tt_content.myvendor_attractionshow {
    20 =< lib.myvendorThuecatPlugin
    20 {
        pluginName = TouristAttractionShow
    }
}
Copied!

The route 

The site configuration imports the route of the detail plugin:

config/sites/<your-site>/config.yaml
imports:
  - { resource: 'EXT:thuecat/Configuration/Routes/TouristAttractionShow.yaml' }
Copied!

The page role 

The page carrying the content element gets Tourist attraction detail as its ThüCAT page role. Its uid is the site setting thuecat.pois.pid_show, so list links and the sitemap point there.

The mapping 

The site set's page TSconfig maps the content element type to the role, so the page module tells editors when the role is missing:

EXT:myextension/Configuration/Sets/MySet/page.tsconfig
tx_thuecat.pageRoles.myvendor_attractionshow = thuecat_touristattractionshow
Copied!

The result 

A list linking to the attraction "Stadtmuseum Erfurt" on the detail page /ausflugsziel produces /ausflugsziel/stadtmuseum-erfurt, and that URL renders the attraction.