The virtual component provides an easy way to use custom code and point menu's to it without the need to embed it into a module or a page.
I will use the Amazon Store as an example of how to use to the virtual component.
Go directly to the menu manager and create a menu you want to point to your custom code.
As you can see there are numerous slots you can choose from, so simply create a new menu and then select a slot.
Putting in your code
Now give the component a name (this is for your own reference and wont show in the front end) then paste the code into the larger box and hit save.
Now if you click your new menu it will go directly to the Amazon Store.
To see an example of this check under the menu at the top of the page:
Demos/Virtual Component or click here.
Virtual Component 1.0.3