meteor create todos
cd todos
meteor npm install --save react react-dom react-router-dom history
meteor add react-meteor-data
meteor remove blaze-html-templates
meteor add static-html
meteor add alexwine:bootstrap-4
meteor add msavin:mongol
meteor remove insecure autopublish
meteor add accounts-password
/client/main.html
<head>
</head>
<body>
<div id="target-render"></div>
</body>
/client/main.js
import React from 'react';
import ReactDOM from 'react-dom';
import App from '/imports/ui/App';
Meteor.startup(() => {
ReactDOM.render(
<App/>,
document.getElementById('target-render')
)
});
/imports/ui/App.js
import React, {Component} from 'react';
class App extends Component {
render() {
return (
<div>
App
</div>
);
}
}
export default App;
meteor