Hope this helps. I just had superb results embedding my entire component with Salesforce data tables,html, etc. into a visualforce page...not just a button calling a js script.
Step 1:
your aura application should be global and extend ltng:outApp:
<aura:application access="GLOBAL" extends="ltng:outApp">
Step 2:
add a dependency to your application:
<aura:dependency resource="c:MyAuraLgtComponent"/>
Step 3:
In your visualforce page:
<apex:includeScript value="/lightning/lightning.out.js" />
Step 4:
In your visualforce page:
<div id="lightning" />
<script>
$Lightning.use("c:MyApp", function() {
$Lightning.createComponent("yourNamespace:MyAuraLgtComponent",
{ label : "" },
"lightning",
function(cmp) {
// do some stuff
});
});
</script>
Make sure that the component you are creating with $Lightning.createComponent() has the same name as the component you would like to display on the visual force page.
Best Answer
Based on your comments around requirements (as below), you are looking to be able to dynamically reflect the page layout for creating a record using a Lightning Component.
You need to use force:createRecord event for this purpose. This is what the documentation for this event mentions:
Now, that you want to be able to display the page layout based on the record type, you will need to use the recordTypeId attribute of the event for that purpose. You just need to pass the record type's id that was selected in the previous page and it will render the page layout associated with that record type.
Note - Though the documentation does not explicitly mention that it opens associated page layout with a record type, but once you provide the record type id, it takes care of opening the correct page layout based on the assignment (I have verified this as a test).
This is how your code should look like: