I'm getting errors after upgrading bs-platform from v5.0.4 to v.5.0.5
TypeError: Cannot set property 'tag' of undefined
at Object.variant (/Users/banacorn/github/agda-mode/node_modules/bs-platform/lib/js/caml_chrome_debugger.js:189:10)
at Object.<anonymous> (/Users/banacorn/github/agda-mode/lib/js/src/View/Root.bs.js:30:67)
....
It turned out that Caml_chrome_debugger.variant is expecting 3 arguments:
However, the generated code is given only 2 arguments.
Here's an example:
var initialState_000 = /* mountAt : Bottom */Caml_chrome_debugger.variant("Bottom", [createBottomPanel(/* () */0)]);
Removing the -bs-g flag from bsconfigs.json would strip all Caml_chrome_debugger away, and thus preventing this from happening as expected.
EDIT: grammar
hi @banacorn sorry for the inconvenience, will make a bug fix release this weekend
fixed in #3637