That’s if you want to create a brand-new BP component by extending the base BP_Component class.
This makes things way easy to manage and develop going forward!
You can find examples throughout the BP 1.5 codebase (look at each subdirectory for bp-x-loader.php and stare at it until it melts into your head!).
Easiest thing to do is check out the phpDoc in the code itself.
https://buddypress.trac.wordpress.org/browser/trunk/bp-core/bp-core-component.php#L6
Basically it requires a few basic parameters to identify the component, and calls the parent class function to put them into action.
Should have looked first, man oh man the component code is so much cleaner. Well done, gents!
Ok, so tried to move some code from core to create a custom component and nothing worked. Never got a page to create and not sure how to link it to template files.
For example: in bp-activity it has a file bp-activity-template.php and in include array there’s an entry ‘template’. Is this pointing to that file? Do we need to include all these files listed in the array? If I had bp-example-template.php in my array id still use ‘template’?
To me it seemed much easier to create components before. I know I can still use old method but that won’t last forever.
Can somebody update the skeleton component to reflect the new method?