From 8ff0fbfafa6be6391ff2155c4cd938f76c8f9cc5 Mon Sep 17 00:00:00 2001 From: Christoph Knittel Date: Thu, 5 Jan 2023 18:47:42 +0100 Subject: [PATCH] Fix jsx mode being ignored when set via @@jsxConfig --- cli/reactjs_jsx_ppx.ml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cli/reactjs_jsx_ppx.ml b/cli/reactjs_jsx_ppx.ml index 4da2cae1..5c2a9597 100644 --- a/cli/reactjs_jsx_ppx.ml +++ b/cli/reactjs_jsx_ppx.ml @@ -28,7 +28,8 @@ let getJsxConfigByKey ~key ~type_ recordFields = Some value | ( String, {txt = Lident k}, - {pexp_desc = Pexp_constant (Pconst_string (value, None))} ) + (* accept both normal strings and "js" strings *) + {pexp_desc = Pexp_constant (Pconst_string (value, _))} ) when k = key -> Some value | _ -> None)