I am recently studying Meteor which is absolutely convenient and powerful. But so far it is still not clear what is the entry point of a Meteor APP, in other words, which file/function will be executed first?
A simple example:
client/hello.jsx:
import React from 'react';
export const Welcome = ({name}) => (
<div>
Hello, {name}.
</div>
);
client/routes.jsx:
import React from 'react';
import {mount} from 'react-mounter';
import {Layout, Welcome} from './hello.jsx';
FlowRouter.route("/", {
action() {
mount(Layout,
{content: (<Welcome name="My Shining Name" />)}
);
}
});
then I use command:
meteor -p 12345
Then a webpage is launched! It looks pretty magic: where is the server running? how the webpage is generated? Most importantly, which piece of code will be executed first?
Thanks
Derek