1. vue-fort-model-loader

vue-fort-model-loader

vue-fort-model-loader

A webpack loader for the VueFort models.

Supports hot-reloading during development.

setup

 npm i vue-fort-model-loader

usage

Use named exports to export the model options.

 export function state() {
  return {
    count: 0,
  };
}

export const getters = {
  countDouble() {
    return this.count * 2;
  },
};

export const methods = {
  inc() {
    this.count++;
  },
};

Use the loader to define and import the model.

 import model from 'vue-fort-model-loader!./path/to/model';