BSC.exe: Wrong Argument. -bs-jsx expects an integer
All .re files report an error at the first symbol of the file.
Occurred after creating a project with bsb-init app -theme react-hooks
Issue occurs across multiple machines, and over several version of bs-platform and reason-vscode.
Code still builds without issue.
C:\Users\Brothersr\Desktop\WorkBench\ReasonReact\app\node_modules\bs-platform\lib\bsc.exe: wrong argument '3''; option '-bs-jsx' expects an integer.
Usage: bsc <options> <files>
Options are:
-bs-super-errors Better error message combined with other tools
-bs-jsx Set jsx version
-bs-re-out Print compiler output in Reason syntax
-bs-gentype Pass gentype command
-bs-suffix Set suffix to .bs.js
-bs-no-implicit-include Don't include current dir implicitly
-bs-assume-has-mli (internal) Assume mli always exist
-bs-assume-no-mli (internal) Don't lookup whether mli exist or not
-bs-D Define conditional variable e.g, -D DEBUG=true

This seems to be an issue on Windows, and I ran into the same problem. The way I solved it is by going into your .merlin auto-generated configuration file, and removing the quotes from around the FLG -ppx 'C:\Users\Brothersr\Desktop\WorkBench\ReasonReact\app\node_modules\bs-platform\lib\bsppx.exe -bs-jsx 3'
So mine looks like this:
FLG -ppx C:\Users\tom\dev\myproj\node_modules\bs-platform\lib\bsppx.exe -bs-jsx 3
The issue comes down to using quotes to guard against spaces in windows path names. It lumps the second ' in with the integer at the end (3).
This is probably more of an issue with the bucklescript compiler than with this extension. See: https://github.com/BuckleScript/bucklescript/issues/3588
I know this issue was opened two weeks ago, but I came across it while investigating the same issue, so I'll leave the answer in case anyone else does the same.
hi @tac44 , this is prioritized and will be fixed soon
This issue still occurs in windows 10 and it seems not resolved yet. Any progress?
@Paosder it is fixed in beta release