Hello everyone, Im facing an really weird issue.
My case is this, I am making an application in react. I saw that it is possible to generate a single file bundle using the --compact flag, since in my use case it is preferable to use a singe file from a private CDN to serve all the Threekit + React App javascript.
The problem I’m having is that in my local development, everything is working correctly, but when I run the yarn build-react
command the application renders fine, but the attributes part returns an array with empty values to be selected. Which shows an empty dropdown, this doesn’t happen in my local version.
Even the attribute id matches the selected ones, but in the production version, the values are empty
Example of the attributes Object
// Local Dev enviroment
{
attributes: {
Color: {
assetType: 'item',
blacklist: [],
defaultValue: { configuration: '' },
disabledValues: [],
enabled: true,
hiddenValues: [],
id: '757dd8f5-e05c-4301-8726-38220665c3d4',
label: 'Color',
name: 'Color',
type: 'Asset',
value: { configuration: '' },
values: [{...}, {..}], // <--- I have two values here
visible: true,
},
},
}
// Production Bundle
{
attributes: {
Color: {
assetType: 'item',
blacklist: [],
defaultValue: { configuration: '' },
disabledValues: [],
enabled: true,
hiddenValues: [],
id: '757dd8f5-e05c-4301-8726-38220665c3d4',
label: 'Color',
name: 'Color',
type: 'Asset',
value: { configuration: '' },
values: [], // <--- This is empty
visible: true,
},
},
}
Does anyone have a similar problem?