I started a bare app, added one component written as such:
import React from 'react';
import ReactDOM from 'react-dom';
const Comp = () => (
<div>
Hello World.
</div>
);
Meteor.startup(() => {
const div = document.createElement('div');
document.body.appendChild(div);
ReactDOM.render(<Comp />, div);
});
I get a React is not defined error unless I put React somewhere, like this for instance:
Meteor.startup(() => {
React;
const div = document.createElement('div');
document.body.appendChild(div);
ReactDOM.render(<Comp />, div);
});