ProductiveRage/Bridge.React

Issue with metadata in v4.2.0

Closed this issue · 4 comments

bridge.js:1321 Uncaught TypeError: Cannot read property 'split' of undefined
at Object.unroll (bridge.js:1321)
at setMetadata (bridge.js:3496)
at Bridge.React.meta.js:7
at Object.Bridge.assembly (bridge.js:3372)
at Bridge.React.meta.js:1
unroll @ bridge.js:1321
setMetadata @ bridge.js:3496
(anonymous) @ Bridge.React.meta.js:7
Bridge.assembly @ bridge.js:3372
(anonymous) @ Bridge.React.meta.js:1

This seems to be a change in Bridge between 17.1 and 17.6 - I couldn't find anything in their breaking changes docs about it but I'm hoping to release an update to this library that builds against Bridge's latest point release. (In the meantime, I would suggest trying to change your project to use Bridge 17.1 if possible)

Ok thanks, I am testing it at the moment to see if it will work for us, so I can try the older version.

It also works fine if I leave the .meta.js file out. What are the .meta files used for anyway as they don't seem to be needed?

I've published Bridge.React 5.0.0 which fixes this. It will only work with Bridge 17.6.0 because Bridge introduced a breaking change in how those meta data files are structured.

The metadata files enable reflection from Bridge code. It may not be required for the majority of Bridge.React projects but there may be some that do want it and so it's included in the package.

Excellent. And thanks for the info about metadata. Makes sense now, that it would be used if C# code wants to use the reflection API's.