Replies: 4 comments 6 replies
-
Hi @nojaf , regarding
AFAIK, jihchi/vite-plugin-rescript does not write files to disk. Could you please elaborate on that? What the plugin does is to simply spawn a process of the ReScript compiler in the background and redirect error logs from the |
Beta Was this translation helpful? Give feedback.
-
Sure, if I have a |
Beta Was this translation helpful? Give feedback.
-
There are two issues:
|
Beta Was this translation helpful? Give feedback.
-
So, I just saw the intro to the compiler by @cristianoc. Running If my hunch is correct, where could I find where |
Beta Was this translation helpful? Give feedback.
-
Hello,
As someone new to ReScript, I'm trying to find an optimal integration with Vite. The current approaches are either to run a separate terminal or to use jihchi/vite-plugin-rescript.
Running a separate terminal is less than ideal. The
vite-plugin-rescript
approach, which writes files to disk, poses its own problems. For instance, if there's an error in the ReScript code, the plugin might resort to using an outdated file, leading to confusion and loss of React state.I'm curious about the feasibility of compiling ReScript code in-memory to address these issues. Such a method would ensure the Vite plugin always has access to the latest version of the code and might also enhance performance by reducing I/O operations.
I've initiated this discussion as I'm unsure if in-memory compilation is currently feasible with ReScript. I'm open to being corrected on this.
I'm also curious if you considered this @jihchi?
Beta Was this translation helpful? Give feedback.
All reactions