/vue-cli-plugin-nuxt-typescript

Nuxt.js with TypeScript support through vue-cli 3

Primary LanguageJavaScriptMIT LicenseMIT

Note! Native Nuxt TypeScript support

As of 2.4.0, Nuxt has native TypeScript support, effectively making this plugin redundant. Consider using that version of Nuxt rather than this plugin.

vue-cli-plugin-nuxt-typescript

Nuxt.js with TypeScript support

Usage

Prerequisite

Installation

Create a new Vue.js project with vue-cli:

vue create my-app
cd my-app

Use vue-cli to add this plugin

vue add nuxt-typescript

Prompts

Use nuxt-property-decorators? (Y/n)

Whether or not to use nuxt-property-decorators, where the default answer is Yes. The provided examples will respect this choice.

Move source files to src/ folder? (Y/n)

When creating a Nuxt.js app the default configuration is to not use the src/ folder, however TypeScript and Vue.js prefers using it.

If this option is enabled, any existing files in src/ will be moved to legacy/ instead.

Linting

If you have ESLint enabled in your initial Vue project, the plugin respects that and modifies the configuration files accordingly. So far, I have not used TSLint myself, so I haven't included that option yet.

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

License

This project is licensed under the MIT License - see the LICENSE file for details