I have spun up a Create React Application and any time I import a single module from arcgis/core e.g:
import Graphic from '@arcgis/core/Graphic'
my build process runs out of memory.
I have also tried building the sample React app here:
and am getting the same issue.
I think it has something to do with Tree Shaking: https://webpack.js.org/guides/tree-shaking/
I'm pretty sure that by importing a single module it imports the entire arcgis/core dependency. I don't know if I'm not importing the modules correctly or if it isn't possible to import just the modules I need.
Is there something that I'm missing?
Same for me, I'm not able to build my project anymore. Though I've sucessfully built https://github.com/Esri/jsapi-resources/tree/master/esm-samples/jsapi-create-react-app, I get around 250 js chunks with this sample... Using esri_loader I had around 5 chunks.