Skip to content

Fattafatta/rescript-v12-test

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ReScript V12 JSX Test

Development

Run ReScript in dev mode:

npm run dev

Problem with JSX

You can switch between the working and broken version by changing rescript.json.

// working
"jsx": {
  "version": 4,
  "module": "JSXWorking"
}
// broken
"jsx": {
  "version": 4,
  "module": "JSXBroken"
}

The only differences between the working version and the broken version are the missing @module("dummy") lines. But in one case the output contains JSX as expected, in the other case, the output contains only function calls.

Problem with fragments

Even in the working version, fragments are compiled to <Fragement>...</Fragment> but it should be <>...</>. When removing the "module": "JSXWorking" line completely:

"jsx": {
  "version": 4,
}

fragments are generated as expected.

About

Test of JSX preserve mode

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published