Skip to content

Vite plugin

This library has a Vite plugin that can improve DX when using the library.

Installation

bash
npm install mobx-view-model-vite-plugin
bash
yarn add mobx-view-model-vite-plugin
bash
pnpm add mobx-view-model-vite-plugin

Usage

Open your vite.config.ts and add this plugin

ts
import { mobxViewModel } from "mobx-view-model-vite-plugin";
...
  plugins: [
    mobxViewModel({
      reloadOnChangeViewModel: true
    })
  ]
...

Features

reloadOnChangeViewModel

This option enables reload page after your ViewModel change

Released under the MIT License.