You mentioned the restrictions on ES6, naming and defaults, just wanted to touch on these.
For naming, is there a reason you can't key the __jsxHot object entirely by pluginArgument as that is a completely unique identifier?
For the exports - perhaps it is possible to iterate the different exports on the export object, to see if one is a React class, perhaps via obj instanceof React.Component? I'm sure there are lots of other ways out there to do this as well. That would cover the default and any others.
Then I'm still not quite sure I follow why we are restricted to ES6 modules for these JSX components as well.
You mentioned the restrictions on ES6, naming and defaults, just wanted to touch on these.
For naming, is there a reason you can't key the
__jsxHotobject entirely bypluginArgumentas that is a completely unique identifier?For the exports - perhaps it is possible to iterate the different exports on the export object, to see if one is a React class, perhaps via
obj instanceof React.Component? I'm sure there are lots of other ways out there to do this as well. That would cover the default and any others.Then I'm still not quite sure I follow why we are restricted to ES6 modules for these JSX components as well.