Forward rescript compiler colors to vite process

Hello,

I’m trying to use Vite & ReScript together with this plugin.

But the colors is not forwarded to the main process, I tried various way

  • stdio set to inherit display color but doesn’t allow me to use the stdout
  • FORCE_COLOR env set to true doesn’t change anything

The main advantage of this plugin is it’s wait the end of the rescript compilation in order to run the vite build.

If by chance, someone has some knowledge about this, it’s welcome :slight_smile:

Cheers

1 Like

Hi,

As a temporary work-around, you could try to set NINJA_ANSI_FORCED to "1", for example:

NINJA_ANSI_FORCED=1 npm start

(It works for vitejs-template-react-rescript)

1 Like

Hi !

Indeed I have the colors when the compilation fails !
I assumed it was not working with working code :sweat_smile:

Thanks for the plugin btw :slight_smile:

1 Like

The main advantage of this plugin is it’s wait the end of the rescript compilation in order to run the vite build.

I have wanted this in other settings like next and webpack. Sounds cool.

The main advantage of this plugin is it’s wait the end of the rescript compilation in order to run the vite build.

Does this plugin wait until after each round of compilation before invoking the rest of the vite build, or does it only wait for the first round of rescript compilation?