@factorial/stack-vue

0.3.1 • Public • Published

@factorial/stack-vue

This is the Vue plugin for @factorial/stack-core.

It provides a linting task. The configuration files for that can be found in eslint.

Please be aware that this package not only lints .vue, but also .js, .mjs and .cjs files. This means that you do not need the @factorial/stack-javascript package.

Installation

You can install it via:

yarn factorial init

or manually via:

yarn add @factorial/stack-vue

Make sure it is added to your .factorialrc.js like this:

// .factorialrc.js

module.exports = {
  use: [require("@factorial/stack-vue")],
};

And add a .eslintrc.js:

// .eslintrc.js

module.exports = {
  root: true,
  extends: [
    require.resolve("@factorial/stack-javascript/eslint"),
    require.resolve("@factorial/stack-vue/eslint/v3"),
  ],
};

Available configurations:

  • @factorial/stack-vue/eslint/v2: Vue 2
  • @factorial/stack-vue/eslint/v3: Vue 3

Extending or overwriting linting rules

If you need to extend or overwrite the linting rules, you can do that like this:

// .eslintrc.js

module.exports = {
  root: true,
  extends: [],
  rules: {
    ...
  },
};

Usage

You can run:

yarn factorial lint

This will also run other linting tasks provided by other packages (in case you installed some).

If you want to only lint .vue files, you can run:

yarn factorial lint --only vue

Readme

Keywords

none

Package Sidebar

Install

npm i @factorial/stack-vue

Weekly Downloads

2

Version

0.3.1

License

MIT

Unpacked Size

8.43 kB

Total Files

10

Last publish

Collaborators

  • mvsde
  • dnnsjrng
  • mmatull
  • mlnmln
  • mgrsskls
  • andrewbeng89