Feature stapling is an approach used to associate custom features with a site definition. This feature will be activated automatically when a new site is created from the associated site definition. The Id attribute contains Ids of "Staplee" feature.
"Staplee" – the feature associated with a site definition or the feature that applies the customization.
reSP allows you to select from the drop-down list.
Just use Ctrl+Space shortcut.
Feature stapling concept itself is fairly easy to use, but an important aspect in feature stapling is the order in which a site is provisioned:
- global onet.xml
- Site-scoped features defined in onet.xml, in the order they are defined in the file.
- Site-scoped stapled features, activated asynchronously, on multiple threads
- Web-scoped features defined in onet.xml, in the order they are defined in the file.
- Web-scoped stapled features, activated asynchronously, on multiple threads
- List instances defined in onet.xml
- Modules defined in onet.xml