As I mentioned, I think it is a “worthwhile goal” to be able to build a React based addon using both the ACE and
create-react-app frameworks if possible, mostly so that we can then worry about writing the addon instead of the dev framework
I have an experimental solution working now.
First, I had to fork ACE with a tweak to make it possible to add a catchall route after ACE route configuration.
With that in place, it appears very simple to proxy all React related calls to the web server.
The resulting “starter project” is here if anyone is interested.
It’s very important to note that this is experimental: it might be flawed because I don’t necessarily know what I’m doing!
Therefore, I’d be delighted if it helps someone else get started too - as long as you understand that, but
…I’d be even more delighted if someone who is more intimate with ACE was able to take a look and spot flaws.
Fortunately it doesn’t seem to matter if it is flawed: any addon development done using it will be fine anyhow, it just might need something like alexter’s skelton replacing this, should there be an issue later with this way of running the dev environment.
So I am pressing on building on top of it.
One thing I’ve noticed is that the Atlassian Connect
all.js appears to cause some interesting traffic to the React server even though the React app doesn’t try to use any AC functions yet.
GET /static/js/bundle.js 200 69.239 ms - 342092
 GET /sockjs-node/info?t=1509075873554 200 8.830 ms - 79
 GET /static/media/logo.5d5d9eef.svg 200 15.343 ms - 1308
 GET /sockjs-node/iframe.html 200 7.122 ms - 449
 GET /__webpack_dev_server__/sockjs.bundle.js 200 16.494 ms - -
 GET /__webpack_dev_server__/sockjs.bundle.js 304 8.537 ms - -
 POST /sockjs-node/272/a4hue25n/xhr?t=1509075889235 200 7.507 ms - 2
 POST /sockjs-node/272/a4hue25n/xhr?t=1509075891695 200 6.463 ms - 145
I’m vaguely wary about whether these are sync or async, and if that is affecting the ACE server delivering API requests.
If anyone can suggest if this is something to worry about or not, that too would be great