├── examples
├── create-vue-ts
│ ├── env.d.ts
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── tsconfig.json
│ ├── src
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── components
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── .eslintrc.cjs
│ ├── index.html
│ ├── tsconfig.app.json
│ ├── .gitignore
│ ├── vite.config.ts
│ ├── tsconfig.node.json
│ ├── package.json
│ └── README.md
├── vue-cli-cypress-ts
│ ├── public
│ │ ├── robots.txt
│ │ ├── favicon.ico
│ │ ├── img
│ │ │ └── icons
│ │ │ │ ├── favicon-16x16.png
│ │ │ │ ├── favicon-32x32.png
│ │ │ │ ├── mstile-150x150.png
│ │ │ │ ├── apple-touch-icon.png
│ │ │ │ ├── android-chrome-192x192.png
│ │ │ │ ├── android-chrome-512x512.png
│ │ │ │ ├── apple-touch-icon-120x120.png
│ │ │ │ ├── apple-touch-icon-152x152.png
│ │ │ │ ├── apple-touch-icon-180x180.png
│ │ │ │ ├── apple-touch-icon-60x60.png
│ │ │ │ ├── apple-touch-icon-76x76.png
│ │ │ │ ├── msapplication-icon-144x144.png
│ │ │ │ ├── android-chrome-maskable-192x192.png
│ │ │ │ ├── android-chrome-maskable-512x512.png
│ │ │ │ └── safari-pinned-tab.svg
│ │ └── index.html
│ ├── .browserslistrc
│ ├── cypress.json
│ ├── babel.config.js
│ ├── jest.config.js
│ ├── src
│ │ ├── assets
│ │ │ └── logo.png
│ │ ├── views
│ │ │ ├── AboutView.vue
│ │ │ └── HomeView.vue
│ │ ├── shims-vue.d.ts
│ │ ├── main.ts
│ │ ├── store
│ │ │ └── index.ts
│ │ ├── App.vue
│ │ ├── router
│ │ │ └── index.ts
│ │ └── registerServiceWorker.ts
│ ├── vue.config.js
│ ├── tests
│ │ ├── e2e
│ │ │ ├── .eslintrc.js
│ │ │ ├── specs
│ │ │ │ └── test.js
│ │ │ ├── support
│ │ │ │ ├── index.js
│ │ │ │ └── commands.js
│ │ │ └── plugins
│ │ │ │ └── index.js
│ │ └── unit
│ │ │ └── example.spec.ts
│ ├── tsconfig.eslint.json
│ ├── .gitignore
│ ├── .eslintrc.cjs
│ ├── README.md
│ ├── tsconfig.json
│ └── package.json
├── create-vue-ts-allow-js
│ ├── env.d.ts
│ ├── src
│ │ ├── foo.js
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── components
│ │ │ ├── JsxInVue.vue
│ │ │ ├── TsxInVue.vue
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── tsconfig.json
│ ├── .eslintrc.cjs
│ ├── index.html
│ ├── .gitignore
│ ├── tsconfig.app.json
│ ├── vite.config.ts
│ ├── tsconfig.node.json
│ ├── package.json
│ └── README.md
├── create-vue-ts-cypress
│ ├── env.d.ts
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── cypress
│ │ ├── fixtures
│ │ │ └── example.json
│ │ ├── e2e
│ │ │ ├── example.cy.ts
│ │ │ └── tsconfig.json
│ │ └── support
│ │ │ ├── component-index.html
│ │ │ ├── e2e.ts
│ │ │ ├── component.ts
│ │ │ └── commands.ts
│ ├── src
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── components
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── __tests__
│ │ │ │ └── HelloWorld.cy.ts
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── tsconfig.json
│ ├── index.html
│ ├── tsconfig.app.json
│ ├── tsconfig.cypress-ct.json
│ ├── cypress.config.ts
│ ├── vite.config.ts
│ ├── .gitignore
│ ├── tsconfig.node.json
│ ├── .eslintrc.cjs
│ └── package.json
├── create-vue-ts-allow-js-in-vue
│ ├── env.d.ts
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── tsconfig.json
│ ├── src
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── components
│ │ │ ├── JsxInVue.vue
│ │ │ ├── TsxInVue.vue
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── .eslintrc.cjs
│ ├── index.html
│ ├── .gitignore
│ ├── tsconfig.app.json
│ ├── vite.config.ts
│ ├── tsconfig.node.json
│ ├── package.json
│ └── README.md
├── create-vue-ts-allow-jsx-in-vue
│ ├── env.d.ts
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── tsconfig.json
│ ├── src
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── components
│ │ │ ├── JsxInVue.vue
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── .eslintrc.cjs
│ ├── index.html
│ ├── .gitignore
│ ├── tsconfig.app.json
│ ├── vite.config.ts
│ ├── tsconfig.node.json
│ ├── package.json
│ └── README.md
├── create-vue-ts-allow-tsx-in-vue
│ ├── env.d.ts
│ ├── .vscode
│ │ └── extensions.json
│ ├── public
│ │ └── favicon.ico
│ ├── tsconfig.json
│ ├── src
│ │ ├── views
│ │ │ ├── HomeView.vue
│ │ │ └── AboutView.vue
│ │ ├── components
│ │ │ ├── JsxInVue.vue
│ │ │ ├── TsxInVue.vue
│ │ │ ├── icons
│ │ │ │ ├── IconSupport.vue
│ │ │ │ ├── IconTooling.vue
│ │ │ │ ├── IconCommunity.vue
│ │ │ │ ├── IconDocumentation.vue
│ │ │ │ └── IconEcosystem.vue
│ │ │ ├── HelloWorld.vue
│ │ │ └── WelcomeItem.vue
│ │ ├── assets
│ │ │ ├── logo.svg
│ │ │ └── main.css
│ │ ├── main.ts
│ │ ├── stores
│ │ │ └── counter.ts
│ │ ├── router
│ │ │ └── index.ts
│ │ └── App.vue
│ ├── .eslintrc.cjs
│ ├── index.html
│ ├── .gitignore
│ ├── tsconfig.app.json
│ ├── vite.config.ts
│ ├── tsconfig.node.json
│ ├── package.json
│ └── README.md
├── vue-cli-js
│ ├── .browserslistrc
│ ├── babel.config.js
│ ├── public
│ │ ├── favicon.ico
│ │ └── index.html
│ ├── src
│ │ ├── assets
│ │ │ └── logo.png
│ │ ├── views
│ │ │ ├── AboutView.vue
│ │ │ └── HomeView.vue
│ │ ├── main.js
│ │ ├── App.vue
│ │ └── router
│ │ │ └── index.js
│ ├── vue.config.js
│ ├── .gitignore
│ ├── jsconfig.json
│ ├── README.md
│ ├── .eslintrc.js
│ └── package.json
├── vue-cli-ts
│ ├── .browserslistrc
│ ├── babel.config.js
│ ├── public
│ │ ├── favicon.ico
│ │ └── index.html
│ ├── src
│ │ ├── assets
│ │ │ └── logo.png
│ │ ├── views
│ │ │ ├── AboutView.vue
│ │ │ └── HomeView.vue
│ │ ├── main.ts
│ │ ├── shims-vue.d.ts
│ │ ├── App.vue
│ │ └── router
│ │ │ └── index.ts
│ ├── vue.config.js
│ ├── .eslintrc.js
│ ├── .gitignore
│ ├── README.md
│ ├── package.json
│ └── tsconfig.json
└── create-vue-js
│ ├── .vscode
│ └── extensions.json
│ ├── public
│ └── favicon.ico
│ ├── src
│ ├── views
│ │ ├── HomeView.vue
│ │ └── AboutView.vue
│ ├── assets
│ │ ├── logo.svg
│ │ └── main.css
│ ├── main.js
│ ├── components
│ │ ├── icons
│ │ │ ├── IconSupport.vue
│ │ │ ├── IconTooling.vue
│ │ │ ├── IconCommunity.vue
│ │ │ ├── IconDocumentation.vue
│ │ │ └── IconEcosystem.vue
│ │ ├── HelloWorld.vue
│ │ └── WelcomeItem.vue
│ ├── stores
│ │ └── counter.js
│ ├── router
│ │ └── index.js
│ └── App.vue
│ ├── index.html
│ ├── .gitignore
│ ├── vite.config.js
│ ├── .eslintrc.cjs
│ ├── package.json
│ └── README.md
├── pnpm-workspace.yaml
├── packages
├── eslint-config-airbnb
│ ├── index.js
│ ├── createAliasSetting.js
│ ├── rules
│ │ └── misc.js
│ ├── CHANGELOG.md
│ ├── .eslintrc.js
│ └── package.json
└── eslint-config-airbnb-with-typescript
│ ├── allow-jsx-in-vue.js
│ ├── CHANGELOG.md
│ ├── LICENSE
│ ├── createAliasSetting.js
│ ├── allow-js-in-vue.js
│ └── package.json
├── .vscode
└── settings.json
├── package.json
├── .changeset
├── config.json
└── README.md
├── README.md
└── LICENSE
/examples/create-vue-ts/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/robots.txt:
--------------------------------------------------------------------------------
1 | User-agent: *
2 | Disallow:
3 |
--------------------------------------------------------------------------------
/pnpm-workspace.yaml:
--------------------------------------------------------------------------------
1 | packages:
2 | - 'packages/*'
3 | - 'examples/*'
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb/index.js:
--------------------------------------------------------------------------------
1 | module.exports = require('./.eslintrc');
2 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/.browserslistrc:
--------------------------------------------------------------------------------
1 | > 1%
2 | last 2 versions
3 | not dead
4 | not ie 11
5 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/.browserslistrc:
--------------------------------------------------------------------------------
1 | > 1%
2 | last 2 versions
3 | not dead
4 | not ie 11
5 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/foo.js:
--------------------------------------------------------------------------------
1 | const foo = 'foo';
2 |
3 | export default foo;
4 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/.browserslistrc:
--------------------------------------------------------------------------------
1 | > 1%
2 | last 2 versions
3 | not dead
4 | not ie 11
5 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/cypress.json:
--------------------------------------------------------------------------------
1 | {
2 | "pluginsFile": "tests/e2e/plugins/index.js"
3 | }
4 |
--------------------------------------------------------------------------------
/.vscode/settings.json:
--------------------------------------------------------------------------------
1 | {
2 | "eslint.workingDirectories": [
3 | "./examples/*",
4 | "./packages/*"
5 | ]
6 | }
7 |
--------------------------------------------------------------------------------
/examples/create-vue-js/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/babel.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | presets: [
3 | '@vue/cli-plugin-babel/preset',
4 | ],
5 | };
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/babel.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | presets: [
3 | '@vue/cli-plugin-babel/preset',
4 | ],
5 | };
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-js/public/favicon.ico
--------------------------------------------------------------------------------
/examples/vue-cli-ts/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-ts/public/favicon.ico
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/babel.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | presets: [
3 | '@vue/cli-plugin-babel/preset',
4 | ],
5 | };
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-js/src/assets/logo.png
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-ts/src/assets/logo.png
--------------------------------------------------------------------------------
/examples/create-vue-js/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-js/public/favicon.ico
--------------------------------------------------------------------------------
/examples/create-vue-ts/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts/public/favicon.ico
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/jest.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | preset: '@vue/cli-plugin-unit-jest/presets/typescript-and-babel',
3 | };
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/.vscode/extensions.json:
--------------------------------------------------------------------------------
1 | {
2 | "recommendations": ["Vue.volar", "Vue.vscode-typescript-vue-plugin"]
3 | }
4 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/favicon.ico
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/src/assets/logo.png
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts-allow-js/public/favicon.ico
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts-cypress/public/favicon.ico
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "private": true,
3 | "devDependencies": {
4 | "@changesets/changelog-github": "^0.5.0",
5 | "@changesets/cli": "^2.27.1"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts-allow-js-in-vue/public/favicon.ico
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts-allow-jsx-in-vue/public/favicon.ico
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/create-vue-ts-allow-tsx-in-vue/public/favicon.ico
--------------------------------------------------------------------------------
/examples/vue-cli-js/vue.config.js:
--------------------------------------------------------------------------------
1 | const { defineConfig } = require('@vue/cli-service');
2 |
3 | module.exports = defineConfig({
4 | transpileDependencies: true,
5 | });
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/vue.config.js:
--------------------------------------------------------------------------------
1 | const { defineConfig } = require('@vue/cli-service');
2 |
3 | module.exports = defineConfig({
4 | transpileDependencies: true,
5 | });
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/vue.config.js:
--------------------------------------------------------------------------------
1 | const { defineConfig } = require('@vue/cli-service');
2 |
3 | module.exports = defineConfig({
4 | transpileDependencies: true,
5 | });
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/favicon-16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/favicon-16x16.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/favicon-32x32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/favicon-32x32.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/mstile-150x150.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/mstile-150x150.png
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/main.js:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import App from './App.vue';
3 | import router from './router';
4 |
5 | createApp(App).use(router).mount('#app');
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import App from './App.vue';
3 | import router from './router';
4 |
5 | createApp(App).use(router).mount('#app');
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-192x192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-192x192.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-512x512.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-120x120.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-120x120.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-152x152.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-152x152.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-180x180.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-180x180.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-60x60.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-60x60.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-76x76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/apple-touch-icon-76x76.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/msapplication-icon-144x144.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/msapplication-icon-144x144.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-maskable-192x192.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-maskable-192x192.png
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-maskable-512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/vuejs/eslint-config-airbnb/HEAD/examples/vue-cli-cypress-ts/public/img/icons/android-chrome-maskable-512x512.png
--------------------------------------------------------------------------------
/examples/create-vue-js/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | }
10 | ]
11 | }
12 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/shims-vue.d.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | declare module '*.vue' {
3 | import type { DefineComponent } from 'vue'
4 | const component: DefineComponent<{}, {}, any>
5 | export default component
6 | }
7 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress/fixtures/example.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "Using fixtures to represent data",
3 | "email": "hello@cypress.io",
4 | "body": "Fixtures are a great way to mock data for responses to routes"
5 | }
6 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/shims-vue.d.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable */
2 | declare module '*.vue' {
3 | import type { DefineComponent } from 'vue'
4 | const component: DefineComponent<{}, {}, any>
5 | export default component
6 | }
7 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | }
10 | ]
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | }
10 | ]
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | }
10 | ]
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | }
10 | ]
11 | }
12 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/e2e/.eslintrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | plugins: [
3 | 'cypress',
4 | ],
5 | env: {
6 | mocha: true,
7 | 'cypress/globals': true,
8 | },
9 | rules: {
10 | strict: 'off',
11 | },
12 | };
13 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/JsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/TsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/JsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/JsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/JsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/TsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import App from './App.vue';
3 | import './registerServiceWorker';
4 | import router from './router';
5 | import store from './store';
6 |
7 | createApp(App).use(store).use(router).mount('#app');
8 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/store/index.ts:
--------------------------------------------------------------------------------
1 | import { createStore } from 'vuex';
2 |
3 | export default createStore({
4 | state: {
5 | },
6 | getters: {
7 | },
8 | mutations: {
9 | },
10 | actions: {
11 | },
12 | modules: {
13 | },
14 | });
15 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/.eslintrc.js:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | ],
9 | };
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/TsxInVue.vue:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress/e2e/example.cy.ts:
--------------------------------------------------------------------------------
1 | // https://docs.cypress.io/api/introduction/api.html
2 |
3 | describe('My First Test', () => {
4 | it('visits the app root url', () => {
5 | cy.visit('/');
6 | cy.contains('h1', 'You did it!');
7 | });
8 | });
9 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | ],
9 | };
10 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | ],
9 | };
10 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/img/icons/safari-pinned-tab.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tsconfig.eslint.json:
--------------------------------------------------------------------------------
1 | {
2 | // extend your base config so you don't have to redefine your compilerOptions
3 | "extends": "./tsconfig.json",
4 | "include": [
5 | "./"
6 | ],
7 | "compilerOptions": {
8 | "allowJs": true
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/e2e/specs/test.js:
--------------------------------------------------------------------------------
1 | // https://docs.cypress.io/api/table-of-contents
2 |
3 | describe('My First Test', () => {
4 | it('Visits the app root url', () => {
5 | cy.visit('/');
6 | cy.contains('h1', 'Welcome to Your Vue.js + TypeScript App');
7 | });
8 | });
9 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress/e2e/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["./**/*", "../support/**/*"],
4 | "compilerOptions": {
5 | "isolatedModules": false,
6 | "target": "es5",
7 | "lib": ["es5", "dom"],
8 | "types": ["cypress"]
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/main.js:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from '@/App.vue';
5 | import router from './router';
6 |
7 | import '@/assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/views/AboutView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
This is an about page
4 |
5 |
6 |
7 |
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | '@vue/eslint-config-airbnb-with-typescript/allow-js-in-vue',
9 | ],
10 | };
11 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | '@vue/eslint-config-airbnb-with-typescript/allow-jsx-in-vue',
9 | ],
10 | };
11 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | '@vue/eslint-config-airbnb-with-typescript/allow-tsx-in-vue',
9 | ],
10 | };
11 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/assets/logo.svg:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/main.ts:
--------------------------------------------------------------------------------
1 | import { createApp } from 'vue';
2 | import { createPinia } from 'pinia';
3 |
4 | import App from './App.vue';
5 | import router from './router';
6 |
7 | import './assets/main.css';
8 |
9 | const app = createApp(App);
10 |
11 | app.use(createPinia());
12 | app.use(router);
13 |
14 | app.mount('#app');
15 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "files": [],
3 | "references": [
4 | {
5 | "path": "./tsconfig.node.json"
6 | },
7 | {
8 | "path": "./tsconfig.app.json"
9 | },
10 | {
11 | "path": "./tsconfig.cypress-ct.json"
12 | }
13 | ],
14 | "compilerOptions": {
15 | "module": "NodeNext"
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | node_modules
3 | /dist
4 |
5 |
6 | # local env files
7 | .env.local
8 | .env.*.local
9 |
10 | # Log files
11 | npm-debug.log*
12 | yarn-debug.log*
13 | yarn-error.log*
14 | pnpm-debug.log*
15 |
16 | # Editor directories and files
17 | .idea
18 | .vscode
19 | *.suo
20 | *.ntvs*
21 | *.njsproj
22 | *.sln
23 | *.sw?
24 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | node_modules
3 | /dist
4 |
5 |
6 | # local env files
7 | .env.local
8 | .env.*.local
9 |
10 | # Log files
11 | npm-debug.log*
12 | yarn-debug.log*
13 | yarn-error.log*
14 | pnpm-debug.log*
15 |
16 | # Editor directories and files
17 | .idea
18 | .vscode
19 | *.suo
20 | *.ntvs*
21 | *.njsproj
22 | *.sln
23 | *.sw?
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/icons/IconSupport.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/stores/counter.js:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/jsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "es5",
4 | "module": "esnext",
5 | "baseUrl": "./",
6 | "moduleResolution": "node",
7 | "paths": {
8 | "@/*": [
9 | "src/*"
10 | ]
11 | },
12 | "lib": [
13 | "esnext",
14 | "dom",
15 | "dom.iterable",
16 | "scripthost"
17 | ]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/stores/counter.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia';
2 |
3 | export const useCounterStore = defineStore({
4 | id: 'counter',
5 | state: () => ({
6 | counter: 0,
7 | }),
8 | getters: {
9 | doubleCount: (state) => state.counter * 2,
10 | },
11 | actions: {
12 | increment() {
13 | this.counter += 1;
14 | },
15 | },
16 | });
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress/support/component-index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Components App
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/.changeset/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://unpkg.com/@changesets/config@2.1.0/schema.json",
3 | "changelog": [
4 | "@changesets/changelog-github",
5 | { "repo": "vuejs/eslint-config-airbnb" }
6 | ],
7 | "commit": false,
8 | "fixed": [],
9 | "linked": [],
10 | "access": "restricted",
11 | "baseBranch": "main",
12 | "updateInternalDependencies": "patch",
13 | "ignore": []
14 | }
15 |
--------------------------------------------------------------------------------
/examples/create-vue-js/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "baseUrl": ".",
10 | "paths": {
11 | "@/*": ["./src/*"]
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | node_modules
3 | /dist
4 |
5 | /tests/e2e/videos/
6 | /tests/e2e/screenshots/
7 |
8 |
9 | # local env files
10 | .env.local
11 | .env.*.local
12 |
13 | # Log files
14 | npm-debug.log*
15 | yarn-debug.log*
16 | yarn-error.log*
17 | pnpm-debug.log*
18 |
19 | # Editor directories and files
20 | .idea
21 | .vscode
22 | *.suo
23 | *.ntvs*
24 | *.njsproj
25 | *.sln
26 | *.sw?
27 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Vite App
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "baseUrl": ".",
10 | "paths": {
11 | "@/*": ["./src/*"]
12 | }
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/tsconfig.cypress-ct.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.app.json",
3 | "include": [
4 | "env.d.ts",
5 | "src/**/*",
6 | "src/**/*.vue",
7 | "cypress/support/component.*",
8 | "cypress/support/commands.ts"
9 | ],
10 | "exclude": [],
11 | "compilerOptions": {
12 | "composite": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.cypress-ct.tsbuildinfo"
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/unit/example.spec.ts:
--------------------------------------------------------------------------------
1 | import { shallowMount } from '@vue/test-utils';
2 | import HelloWorld from '@/components/HelloWorld.vue';
3 |
4 | describe('HelloWorld.vue', () => {
5 | it('renders props.msg when passed', () => {
6 | const msg = 'new message';
7 | const wrapper = shallowMount(HelloWorld, {
8 | props: { msg },
9 | });
10 | expect(wrapper.text()).toMatch(msg);
11 | });
12 | });
13 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/__tests__/HelloWorld.cy.ts:
--------------------------------------------------------------------------------
1 | import HelloWorld from '../HelloWorld.vue';
2 |
3 | describe('HelloWorld', () => {
4 | it('playground', () => {
5 | cy.mount(HelloWorld, { props: { msg: 'Hello Cypress' } });
6 | });
7 |
8 | it('renders properly', () => {
9 | cy.mount(HelloWorld, { props: { msg: 'Hello Cypress' } });
10 | cy.get('h1').should('contain', 'Hello Cypress');
11 | });
12 | });
13 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/README.md:
--------------------------------------------------------------------------------
1 | # vue-cli-js
2 |
3 | ## Project setup
4 | ```
5 | yarn install
6 | ```
7 |
8 | ### Compiles and hot-reloads for development
9 | ```
10 | yarn serve
11 | ```
12 |
13 | ### Compiles and minifies for production
14 | ```
15 | yarn build
16 | ```
17 |
18 | ### Lints and fixes files
19 | ```
20 | yarn lint
21 | ```
22 |
23 | ### Customize configuration
24 | See [Configuration Reference](https://cli.vuejs.org/config/).
25 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
19 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/README.md:
--------------------------------------------------------------------------------
1 | # vue-cli-ts
2 |
3 | ## Project setup
4 | ```
5 | yarn install
6 | ```
7 |
8 | ### Compiles and hot-reloads for development
9 | ```
10 | yarn serve
11 | ```
12 |
13 | ### Compiles and minifies for production
14 | ```
15 | yarn build
16 | ```
17 |
18 | ### Lints and fixes files
19 | ```
20 | yarn lint
21 | ```
22 |
23 | ### Customize configuration
24 | See [Configuration Reference](https://cli.vuejs.org/config/).
25 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress.config.ts:
--------------------------------------------------------------------------------
1 | import { defineConfig } from 'cypress';
2 |
3 | export default defineConfig({
4 | e2e: {
5 | specPattern: 'cypress/e2e/**/*.{cy,spec}.{js,jsx,ts,tsx}',
6 | baseUrl: 'http://localhost:4173',
7 | },
8 | component: {
9 | specPattern: 'src/**/__tests__/*.{cy,spec}.{js,ts,jsx,tsx}',
10 | devServer: {
11 | framework: 'vue',
12 | bundler: 'vite',
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-js/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-js/vite.config.js:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "allowJs": true,
10 |
11 | "baseUrl": ".",
12 | "paths": {
13 | "@/*": ["./src/*"]
14 | }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "allowJs": true,
10 |
11 | "baseUrl": ".",
12 | "paths": {
13 | "@/*": ["./src/*"]
14 | }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "allowJs": true,
10 |
11 | "baseUrl": ".",
12 | "paths": {
13 | "@/*": ["./src/*"]
14 | }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | .DS_Store
12 | dist
13 | dist-ssr
14 | coverage
15 | *.local
16 |
17 | /cypress/videos/
18 | /cypress/screenshots/
19 |
20 | # Editor directories and files
21 | .vscode/*
22 | !.vscode/extensions.json
23 | .idea
24 | *.suo
25 | *.ntvs*
26 | *.njsproj
27 | *.sln
28 | *.sw?
29 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/tsconfig.app.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@vue/tsconfig/tsconfig.dom.json",
3 | "include": ["env.d.ts", "src/**/*", "src/**/*.vue"],
4 | "exclude": ["src/**/__tests__/*"],
5 | "compilerOptions": {
6 | "composite": true,
7 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.app.tsbuildinfo",
8 |
9 | "allowJs": true,
10 |
11 | "baseUrl": ".",
12 | "paths": {
13 | "@/*": ["./src/*"]
14 | }
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/vite.config.ts:
--------------------------------------------------------------------------------
1 | import { fileURLToPath, URL } from 'node:url';
2 |
3 | import { defineConfig } from 'vite';
4 | import vue from '@vitejs/plugin-vue';
5 | import vueJsx from '@vitejs/plugin-vue-jsx';
6 |
7 | // https://vitejs.dev/config/
8 | export default defineConfig({
9 | plugins: [vue(), vueJsx()],
10 | resolve: {
11 | alias: {
12 | '@': fileURLToPath(new URL('./src', import.meta.url)),
13 | },
14 | },
15 | });
16 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/.eslintrc.js:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | const path = require('node:path');
4 | const createAliasSetting = require('@vue/eslint-config-airbnb/createAliasSetting');
5 |
6 | module.exports = {
7 | root: true,
8 | extends: [
9 | 'plugin:vue/vue3-essential',
10 | '@vue/eslint-config-airbnb',
11 | ],
12 |
13 | settings: {
14 | ...createAliasSetting({
15 | '@': `${path.resolve(__dirname, './src')}`,
16 | }),
17 | },
18 | };
19 |
--------------------------------------------------------------------------------
/examples/create-vue-js/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | const path = require('node:path');
4 | const createAliasSetting = require('@vue/eslint-config-airbnb/createAliasSetting');
5 |
6 | module.exports = {
7 | root: true,
8 | extends: [
9 | 'plugin:vue/vue3-essential',
10 | '@vue/eslint-config-airbnb',
11 | ],
12 |
13 | settings: {
14 | ...createAliasSetting({
15 | '@': `${path.resolve(__dirname, './src')}`,
16 | }),
17 | },
18 | };
19 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
19 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/views/HomeView.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
19 |
--------------------------------------------------------------------------------
/.changeset/README.md:
--------------------------------------------------------------------------------
1 | # Changesets
2 |
3 | Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
4 | with multi-package repos, or single-package repos to help you version and publish your code. You can
5 | find the full documentation for it [in our repository](https://github.com/changesets/changesets)
6 |
7 | We have a quick list of common questions to get you started engaging with this project in
8 | [our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
9 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "@tsconfig/node20/tsconfig.json",
3 | "include": [
4 | "vite.config.*",
5 | "vitest.config.*",
6 | "cypress.config.*",
7 | "nightwatch.conf.*",
8 | "playwright.config.*"
9 | ],
10 | "compilerOptions": {
11 | "composite": true,
12 | "noEmit": true,
13 | "tsBuildInfoFile": "./node_modules/.tmp/tsconfig.node.tsbuildinfo",
14 |
15 | "module": "ESNext",
16 | "moduleResolution": "Bundler",
17 | "types": ["node"]
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | ],
9 | overrides: [
10 | {
11 | files: [
12 | '**/__tests__/*.{cy,spec}.{js,ts,jsx,tsx}',
13 | 'cypress/e2e/**.{cy,spec}.{js,ts,jsx,tsx}',
14 | ],
15 | extends: [
16 | 'plugin:cypress/recommended',
17 | ],
18 | },
19 | ],
20 | };
21 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/.eslintrc.cjs:
--------------------------------------------------------------------------------
1 | require('@rushstack/eslint-patch/modern-module-resolution');
2 |
3 | module.exports = {
4 | root: true,
5 | extends: [
6 | 'plugin:vue/vue3-essential',
7 | '@vue/eslint-config-airbnb-with-typescript',
8 | ],
9 | overrides: [
10 | {
11 | files: [
12 | '**/__tests__/*.{cy,spec}.{js,ts,jsx,tsx}',
13 | 'cypress/e2e/**.{cy,spec}.{js,ts,jsx,tsx}',
14 | ],
15 | extends: [
16 | 'plugin:cypress/recommended',
17 | ],
18 | },
19 | ],
20 | };
21 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/README.md:
--------------------------------------------------------------------------------
1 | # vue-cli-cypress-ts
2 |
3 | ## Project setup
4 | ```
5 | yarn install
6 | ```
7 |
8 | ### Compiles and hot-reloads for development
9 | ```
10 | yarn serve
11 | ```
12 |
13 | ### Compiles and minifies for production
14 | ```
15 | yarn build
16 | ```
17 |
18 | ### Run your unit tests
19 | ```
20 | yarn test:unit
21 | ```
22 |
23 | ### Run your end-to-end tests
24 | ```
25 | yarn test:e2e
26 | ```
27 |
28 | ### Lints and fixes files
29 | ```
30 | yarn lint
31 | ```
32 |
33 | ### Customize configuration
34 | See [Configuration Reference](https://cli.vuejs.org/config/).
35 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb-with-typescript/allow-jsx-in-vue.js:
--------------------------------------------------------------------------------
1 | const { defineConfig } = require('eslint-define-config');
2 |
3 | module.exports = defineConfig({
4 | extends: [
5 | require.resolve('./allow-js-in-vue'),
6 | require.resolve('./allow-tsx-in-vue'),
7 | ],
8 | overrides: [
9 | {
10 | files: ['*.vue'],
11 | rules: {
12 | 'vue/block-lang': [
13 | 'error', {
14 | script: {
15 | lang: ['jsx', 'ts', 'tsx'],
16 | allowNoLang: true,
17 | },
18 | },
19 | ],
20 | },
21 | },
22 | ],
23 | });
24 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/App.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 | Home |
4 | About
5 |
6 |
7 |
8 |
9 |
31 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/App.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 | Home |
4 | About
5 |
6 |
7 |
8 |
9 |
31 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/App.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 | Home |
4 | About
5 |
6 |
7 |
8 |
9 |
31 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/assets/main.css:
--------------------------------------------------------------------------------
1 | @import "./base.css";
2 |
3 | #app {
4 | max-width: 1280px;
5 | margin: 0 auto;
6 | padding: 2rem;
7 |
8 | font-weight: normal;
9 | }
10 |
11 | a,
12 | .green {
13 | text-decoration: none;
14 | color: hsla(160, 100%, 37%, 1);
15 | transition: 0.4s;
16 | }
17 |
18 | @media (hover: hover) {
19 | a:hover {
20 | background-color: hsla(160, 100%, 37%, 0.2);
21 | }
22 | }
23 |
24 | @media (min-width: 1024px) {
25 | body {
26 | display: flex;
27 | place-items: center;
28 | }
29 |
30 | #app {
31 | display: grid;
32 | grid-template-columns: 1fr 1fr;
33 | padding: 0 2rem;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | <%= htmlWebpackPlugin.options.title %>
9 |
10 |
11 |
12 | We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | <%= htmlWebpackPlugin.options.title %>
9 |
10 |
11 |
12 | We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/public/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 | <%= htmlWebpackPlugin.options.title %>
9 |
10 |
11 |
12 | We're sorry but <%= htmlWebpackPlugin.options.title %> doesn't work properly without JavaScript enabled. Please enable it to continue.
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/router/index.js:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const router = createRouter({
5 | history: createWebHistory(import.meta.env.BASE_URL),
6 | routes: [
7 | {
8 | path: '/',
9 | name: 'home',
10 | component: HomeView,
11 | },
12 | {
13 | path: '/about',
14 | name: 'about',
15 | // route level code-splitting
16 | // this generates a separate chunk (About.[hash].js) for this route
17 | // which is lazy-loaded when the route is visited.
18 | component: () => import('../views/AboutView.vue'),
19 | },
20 | ],
21 | });
22 |
23 | export default router;
24 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/src/router/index.js:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const routes = [
5 | {
6 | path: '/',
7 | name: 'home',
8 | component: HomeView,
9 | },
10 | {
11 | path: '/about',
12 | name: 'about',
13 | // route level code-splitting
14 | // this generates a separate chunk (about.[hash].js) for this route
15 | // which is lazy-loaded when the route is visited.
16 | component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue'),
17 | },
18 | ];
19 |
20 | const router = createRouter({
21 | history: createWebHistory(process.env.BASE_URL),
22 | routes,
23 | });
24 |
25 | export default router;
26 |
--------------------------------------------------------------------------------
/examples/create-vue-js/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "create-vue-js",
3 | "private": true,
4 | "version": "0.0.0",
5 | "scripts": {
6 | "dev": "vite",
7 | "build": "vite build",
8 | "preview": "vite preview --port 4173",
9 | "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs --fix --ignore-path .gitignore"
10 | },
11 | "dependencies": {
12 | "pinia": "^2.1.7",
13 | "vue": "^3.3.13",
14 | "vue-router": "^4.2.5"
15 | },
16 | "devDependencies": {
17 | "@rushstack/eslint-patch": "^1.6.1",
18 | "@vitejs/plugin-vue": "^5.0.0",
19 | "@vitejs/plugin-vue-jsx": "^3.1.0",
20 | "@vue/eslint-config-airbnb": "workspace:*",
21 | "eslint": "^8.56.0",
22 | "eslint-plugin-vue": "^9.19.2",
23 | "vite": "^5.0.12"
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/examples/create-vue-js/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-js
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Customize configuration
10 |
11 | See [Vite Configuration Reference](https://vitejs.dev/config/).
12 |
13 | ## Project Setup
14 |
15 | ```sh
16 | pnpm install
17 | ```
18 |
19 | ### Compile and Hot-Reload for Development
20 |
21 | ```sh
22 | pnpm dev
23 | ```
24 |
25 | ### Compile and Minify for Production
26 |
27 | ```sh
28 | pnpm build
29 | ```
30 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const routes: Array = [
5 | {
6 | path: '/',
7 | name: 'home',
8 | component: HomeView,
9 | },
10 | {
11 | path: '/about',
12 | name: 'about',
13 | // route level code-splitting
14 | // this generates a separate chunk (about.[hash].js) for this route
15 | // which is lazy-loaded when the route is visited.
16 | component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue'),
17 | },
18 | ];
19 |
20 | const router = createRouter({
21 | history: createWebHistory(process.env.BASE_URL),
22 | routes,
23 | });
24 |
25 | export default router;
26 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/router/index.ts:
--------------------------------------------------------------------------------
1 | import { createRouter, createWebHistory, RouteRecordRaw } from 'vue-router';
2 | import HomeView from '../views/HomeView.vue';
3 |
4 | const routes: Array = [
5 | {
6 | path: '/',
7 | name: 'home',
8 | component: HomeView,
9 | },
10 | {
11 | path: '/about',
12 | name: 'about',
13 | // route level code-splitting
14 | // this generates a separate chunk (about.[hash].js) for this route
15 | // which is lazy-loaded when the route is visited.
16 | component: () => import(/* webpackChunkName: "about" */ '../views/AboutView.vue'),
17 | },
18 | ];
19 |
20 | const router = createRouter({
21 | history: createWebHistory(process.env.BASE_URL),
22 | routes,
23 | });
24 |
25 | export default router;
26 |
--------------------------------------------------------------------------------
/examples/vue-cli-js/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "vue-cli-js",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "serve": "vue-cli-service serve",
7 | "build": "vue-cli-service build",
8 | "lint": "vue-cli-service lint"
9 | },
10 | "dependencies": {
11 | "core-js": "^3.34.0",
12 | "vue": "^3.3.13",
13 | "vue-router": "^4.2.5"
14 | },
15 | "devDependencies": {
16 | "@babel/core": "^7.23.6",
17 | "@rushstack/eslint-patch": "^1.6.1",
18 | "@vue/cli-plugin-babel": "~5.0.8",
19 | "@vue/cli-plugin-eslint": "~5.0.8",
20 | "@vue/cli-plugin-router": "~5.0.8",
21 | "@vue/cli-service": "~5.0.8",
22 | "@vue/eslint-config-airbnb": "workspace:*",
23 | "eslint": "^8.56.0",
24 | "eslint-plugin-vue": "^9.19.2"
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/cypress/support/e2e.ts:
--------------------------------------------------------------------------------
1 | // ***********************************************************
2 | // This example support/index.js is processed and
3 | // loaded automatically before your test files.
4 | //
5 | // This is a great place to put global configuration and
6 | // behavior that modifies Cypress.
7 | //
8 | // You can change the location of this file or turn off
9 | // automatically serving support files with the
10 | // 'supportFile' configuration option.
11 | //
12 | // You can read more here:
13 | // https://on.cypress.io/configuration
14 | // ***********************************************************
15 |
16 | // Import commands.js using ES2015 syntax:
17 | import './commands';
18 |
19 | // Alternatively you can use CommonJS syntax:
20 | // require('./commands')
21 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/e2e/support/index.js:
--------------------------------------------------------------------------------
1 | // ***********************************************************
2 | // This example support/index.js is processed and
3 | // loaded automatically before your test files.
4 | //
5 | // This is a great place to put global configuration and
6 | // behavior that modifies Cypress.
7 | //
8 | // You can change the location of this file or turn off
9 | // automatically serving support files with the
10 | // 'supportFile' configuration option.
11 | //
12 | // You can read more here:
13 | // https://on.cypress.io/configuration
14 | // ***********************************************************
15 |
16 | // Import commands.js using ES2015 syntax:
17 | import './commands';
18 |
19 | // Alternatively you can use CommonJS syntax:
20 | // require('./commands')
21 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # ESLint [Shareable Configs](http://eslint.org/docs/developer-guide/shareable-configs) for [Airbnb JavaScript Style Guide](https://github.com/airbnb/javascript#readme) in [Vue.js](https://vuejs.org/) Projects
2 |
3 | [](https://github.com/airbnb/javascript)
4 |
5 | ## Usage
6 |
7 | This repo contains 2 packages:
8 |
9 | - If you are using ESLint in a JavaScript-only project, check the documentation of [`@vue/eslint-config-airbnb`](./packages/eslint-config-airbnb#readme)
10 | - If you are using ESLint in a TypeScript project, check the documentation of [`@vue/eslint-config-airbnb-with-typescript`](./packages/eslint-config-airbnb-with-typescript#readme)
11 |
12 | The [`examples` folder](./examples/) contains example ESLint configurations in projects created by `create-vue` or `@vue/cli`.
13 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
6 |
7 |
8 |
9 |
{{ msg }}
10 |
11 | You’ve successfully created a project with
12 | Vite +
13 | Vue 3 . What's next?
14 |
15 |
16 |
17 |
18 |
41 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/HelloWorld.vue:
--------------------------------------------------------------------------------
1 |
9 |
10 |
11 |
12 |
{{ msg }}
13 |
14 | You’ve successfully created a project with
15 | Vite +
16 | Vue 3 .
17 |
18 |
19 |
20 |
21 |
44 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "vue-cli-ts",
3 | "version": "0.1.0",
4 | "private": true,
5 | "scripts": {
6 | "serve": "vue-cli-service serve",
7 | "build": "vue-cli-service build",
8 | "lint": "vue-cli-service lint"
9 | },
10 | "dependencies": {
11 | "core-js": "^3.34.0",
12 | "vue": "^3.3.13",
13 | "vue-router": "^4.2.5"
14 | },
15 | "devDependencies": {
16 | "@babel/core": "^7.23.6",
17 | "@rushstack/eslint-patch": "^1.6.1",
18 | "@types/webpack-env": "^1.18.4",
19 | "@vue/cli-plugin-babel": "~5.0.8",
20 | "@vue/cli-plugin-eslint": "~5.0.8",
21 | "@vue/cli-plugin-router": "~5.0.8",
22 | "@vue/cli-plugin-typescript": "~5.0.8",
23 | "@vue/cli-service": "~5.0.8",
24 | "@vue/eslint-config-airbnb-with-typescript": "workspace:*",
25 | "eslint": "^8.56.0",
26 | "eslint-plugin-vue": "^9.19.2",
27 | "typescript": "~4.5.5"
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/examples/vue-cli-ts/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "esnext",
4 | "module": "esnext",
5 | "strict": true,
6 | "jsx": "preserve",
7 | "moduleResolution": "node",
8 | "skipLibCheck": true,
9 | "esModuleInterop": true,
10 | "allowSyntheticDefaultImports": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "useDefineForClassFields": true,
13 | "sourceMap": true,
14 | "baseUrl": ".",
15 | "types": [
16 | "webpack-env"
17 | ],
18 | "paths": {
19 | "@/*": [
20 | "src/*"
21 | ]
22 | },
23 | "lib": [
24 | "esnext",
25 | "dom",
26 | "dom.iterable",
27 | "scripthost"
28 | ]
29 | },
30 | "include": [
31 | "src/**/*.ts",
32 | "src/**/*.tsx",
33 | "src/**/*.vue",
34 | "tests/**/*.ts",
35 | "tests/**/*.tsx"
36 | ],
37 | "exclude": [
38 | "node_modules"
39 | ]
40 | }
41 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "esnext",
4 | "module": "esnext",
5 | "strict": true,
6 | "jsx": "preserve",
7 | "moduleResolution": "node",
8 | "skipLibCheck": true,
9 | "esModuleInterop": true,
10 | "allowSyntheticDefaultImports": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "useDefineForClassFields": true,
13 | "sourceMap": true,
14 | "baseUrl": ".",
15 | "types": [
16 | "webpack-env",
17 | "jest"
18 | ],
19 | "paths": {
20 | "@/*": [
21 | "src/*"
22 | ]
23 | },
24 | "lib": [
25 | "esnext",
26 | "dom",
27 | "dom.iterable",
28 | "scripthost"
29 | ]
30 | },
31 | "include": [
32 | "src/**/*.ts",
33 | "src/**/*.tsx",
34 | "src/**/*.vue",
35 | "tests/**/*.ts",
36 | "tests/**/*.tsx"
37 | ],
38 | "exclude": [
39 | "node_modules"
40 | ]
41 | }
42 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/e2e/support/commands.js:
--------------------------------------------------------------------------------
1 | // ***********************************************
2 | // This example commands.js shows you how to
3 | // create various custom commands and overwrite
4 | // existing commands.
5 | //
6 | // For more comprehensive examples of custom
7 | // commands please read more here:
8 | // https://on.cypress.io/custom-commands
9 | // ***********************************************
10 | //
11 | //
12 | // -- This is a parent command --
13 | // Cypress.Commands.add("login", (email, password) => { ... })
14 | //
15 | //
16 | // -- This is a child command --
17 | // Cypress.Commands.add("drag", { prevSubject: 'element'}, (subject, options) => { ... })
18 | //
19 | //
20 | // -- This is a dual command --
21 | // Cypress.Commands.add("dismiss", { prevSubject: 'optional'}, (subject, options) => { ... })
22 | //
23 | //
24 | // -- This is will overwrite an existing command --
25 | // Cypress.Commands.overwrite("visit", (originalFn, url, options) => { ... })
26 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/icons/IconTooling.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
14 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/tests/e2e/plugins/index.js:
--------------------------------------------------------------------------------
1 | /* eslint-disable arrow-body-style */
2 | // https://docs.cypress.io/guides/guides/plugins-guide.html
3 |
4 | // if you need a custom webpack configuration you can uncomment the following import
5 | // and then use the `file:preprocessor` event
6 | // as explained in the cypress docs
7 | // https://docs.cypress.io/api/plugins/preprocessors-api.html#Examples
8 |
9 | // /* eslint-disable import/no-extraneous-dependencies, global-require */
10 | // const webpack = require('@cypress/webpack-preprocessor')
11 |
12 | module.exports = (on, config) => {
13 | // on('file:preprocessor', webpack({
14 | // webpackOptions: require('@vue/cli-service/webpack.config'),
15 | // watchOptions: {}
16 | // }))
17 |
18 | return {
19 | ...config,
20 | fixturesFolder: 'tests/e2e/fixtures',
21 | integrationFolder: 'tests/e2e/specs',
22 | screenshotsFolder: 'tests/e2e/screenshots',
23 | videosFolder: 'tests/e2e/videos',
24 | supportFile: 'tests/e2e/support/index.js',
25 | };
26 | };
27 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb/createAliasSetting.js:
--------------------------------------------------------------------------------
1 | const DEFAULT_RESOLVER_SETTING = {
2 | // https://github.com/benmosher/eslint-plugin-import/issues/1396
3 | // The default config is good enough, so just an empty object here
4 | [require.resolve('eslint-import-resolver-node')]: {},
5 | };
6 |
7 | /**
8 | * create an ESLint `settings` object
9 | * that help configure the import resolver with given aliases.
10 | * @param {Object} alias a key-value pair, key is the alias prefix,
11 | * value is the actual path. Note it's neither glob nor regex.
12 | * @returns an object to be spread into `settings` property of ESLint config.
13 | */
14 | module.exports = function createAliasSetting(alias) {
15 | return {
16 | 'import/resolver': {
17 | ...DEFAULT_RESOLVER_SETTING,
18 | [require.resolve('eslint-import-resolver-custom-alias')]: {
19 | alias,
20 | extensions: ['.mjs', '.js', '.jsx', '.json', '.node'],
21 | },
22 | },
23 | };
24 | };
25 |
26 | module.exports.DEFAULT_RESOLVER_SETTING = DEFAULT_RESOLVER_SETTING;
27 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb/rules/misc.js:
--------------------------------------------------------------------------------
1 | // These are some corresponding rules to those in
2 | // https://github.com/airbnb/javascript/blob/master/packages/eslint-config-airbnb/rules/react.js
3 | // that can't be categorized as either jsx- or template-specific rules.
4 | module.exports = {
5 | parser: require.resolve('vue-eslint-parser'),
6 | plugins: ['vue'],
7 | rules: {
8 | // https://eslint.vuejs.org/rules/require-default-prop.html
9 | // Corresponding to the `react/require-default-props` rule
10 | // https://github.com/airbnb/javascript/blob/cbf9ade10a2f6f06c9da6dbfa25b344bee4bbef6/packages/eslint-config-airbnb/rules/react.js#L390-L394
11 | 'vue/require-default-prop': 'error',
12 |
13 | // https://eslint.vuejs.org/rules/no-potential-component-option-typo.html
14 | // Corresponding to `react/no-typos` but a little bit different.
15 | // https://github.com/airbnb/javascript/blob/cbf9ade10a2f6f06c9da6dbfa25b344bee4bbef6/packages/eslint-config-airbnb/rules/react.js#L426-L428
16 | 'vue/no-potential-component-option-typo': 'error',
17 | },
18 | };
19 |
--------------------------------------------------------------------------------
/examples/vue-cli-cypress-ts/src/registerServiceWorker.ts:
--------------------------------------------------------------------------------
1 | /* eslint-disable no-console */
2 |
3 | import { register } from 'register-service-worker';
4 |
5 | if (process.env.NODE_ENV === 'production') {
6 | register(`${process.env.BASE_URL}service-worker.js`, {
7 | ready() {
8 | console.log(
9 | 'App is being served from cache by a service worker.\n'
10 | + 'For more details, visit https://goo.gl/AFskqB',
11 | );
12 | },
13 | registered() {
14 | console.log('Service worker has been registered.');
15 | },
16 | cached() {
17 | console.log('Content has been cached for offline use.');
18 | },
19 | updatefound() {
20 | console.log('New content is downloading.');
21 | },
22 | updated() {
23 | console.log('New content is available; please refresh.');
24 | },
25 | offline() {
26 | console.log('No internet connection found. App is running in offline mode.');
27 | },
28 | error(error) {
29 | console.error('Error during service worker registration:', error);
30 | },
31 | });
32 | }
33 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "create-vue-ts",
3 | "private": true,
4 | "version": "0.0.0",
5 | "scripts": {
6 | "dev": "vite",
7 | "build": "run-p type-check build-only",
8 | "preview": "vite preview --port 4173",
9 | "build-only": "vite build",
10 | "type-check": "vue-tsc --build --force",
11 | "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore"
12 | },
13 | "dependencies": {
14 | "pinia": "^2.1.7",
15 | "vue": "^3.3.13",
16 | "vue-router": "^4.2.5"
17 | },
18 | "devDependencies": {
19 | "@rushstack/eslint-patch": "^1.6.1",
20 | "@tsconfig/node20": "^20.1.2",
21 | "@types/node": "^20.10.5",
22 | "@vitejs/plugin-vue": "^5.0.0",
23 | "@vitejs/plugin-vue-jsx": "^3.1.0",
24 | "@vue/eslint-config-airbnb-with-typescript": "workspace:*",
25 | "@vue/tsconfig": "^0.5.1",
26 | "eslint": "^8.56.0",
27 | "eslint-plugin-vue": "^9.19.2",
28 | "npm-run-all": "^4.1.5",
29 | "typescript": "~5.3.3",
30 | "vite": "^5.0.12",
31 | "vue-tsc": "^1.8.27"
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/icons/IconCommunity.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "create-vue-ts-allow-js",
3 | "private": true,
4 | "version": "0.0.0",
5 | "scripts": {
6 | "dev": "vite",
7 | "build": "run-p type-check build-only",
8 | "preview": "vite preview --port 4173",
9 | "build-only": "vite build",
10 | "type-check": "vue-tsc --build --force",
11 | "lint": "eslint . --ext .vue,.js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts --fix --ignore-path .gitignore"
12 | },
13 | "dependencies": {
14 | "pinia": "^2.1.7",
15 | "vue": "^3.3.13",
16 | "vue-router": "^4.2.5"
17 | },
18 | "devDependencies": {
19 | "@rushstack/eslint-patch": "^1.6.1",
20 | "@tsconfig/node20": "^20.1.2",
21 | "@types/node": "^20.10.5",
22 | "@vitejs/plugin-vue": "^5.0.0",
23 | "@vitejs/plugin-vue-jsx": "^3.1.0",
24 | "@vue/eslint-config-airbnb-with-typescript": "workspace:*",
25 | "@vue/tsconfig": "^0.5.1",
26 | "eslint": "^8.56.0",
27 | "eslint-plugin-vue": "^9.19.2",
28 | "npm-run-all": "^4.1.5",
29 | "typescript": "~5.3.3",
30 | "vite": "^5.0.12",
31 | "vue-tsc": "^1.8.27"
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb-with-typescript/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | # @vue/eslint-config-airbnb-with-typescript
2 |
3 | ## 8.0.0
4 |
5 | ### Major Changes
6 |
7 | - Upgrade to @typescript-eslint v6
8 |
9 | ### Patch Changes
10 |
11 | - Updated dependencies []:
12 | - @vue/eslint-config-airbnb@8.0.0
13 |
14 | ## 7.0.1
15 |
16 | ### Patch Changes
17 |
18 | - Updated dependencies []:
19 | - @vue/eslint-config-airbnb@7.0.1
20 |
21 | ## 7.0.0
22 |
23 | ### Major Changes
24 |
25 | - When using the Airbnb Style in a TypeScript project, you no longer need to install both `@vue/eslint-config-airbnb` and `@vue/eslint-config-typescript`.
26 | You can just use the `@vue/eslint-config-airbnb-with-typescript` package.
27 |
28 | It also provides stricter rules for TypeScript.
29 |
30 | For example, by default, only `
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-ts
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Type Support for `.vue` Imports in TS
10 |
11 | TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12 |
13 | If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14 |
15 | 1. Disable the built-in TypeScript Extension
16 | 1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17 | 2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18 | 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19 |
20 | ## Customize configuration
21 |
22 | See [Vite Configuration Reference](https://vitejs.dev/config/).
23 |
24 | ## Project Setup
25 |
26 | ```sh
27 | pnpm install
28 | ```
29 |
30 | ### Compile and Hot-Reload for Development
31 |
32 | ```sh
33 | pnpm dev
34 | ```
35 |
36 | ### Type-Check, Compile and Minify for Production
37 |
38 | ```sh
39 | pnpm build
40 | ```
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/App.vue:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/App.vue:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/App.vue:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-ts-allow-js
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Type Support for `.vue` Imports in TS
10 |
11 | TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12 |
13 | If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14 |
15 | 1. Disable the built-in TypeScript Extension
16 | 1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17 | 2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18 | 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19 |
20 | ## Customize configuration
21 |
22 | See [Vite Configuration Reference](https://vitejs.dev/config/).
23 |
24 | ## Project Setup
25 |
26 | ```sh
27 | pnpm install
28 | ```
29 |
30 | ### Compile and Hot-Reload for Development
31 |
32 | ```sh
33 | pnpm dev
34 | ```
35 |
36 | ### Type-Check, Compile and Minify for Production
37 |
38 | ```sh
39 | pnpm build
40 | ```
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/App.vue:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/App.vue:
--------------------------------------------------------------------------------
1 |
5 |
6 |
7 |
19 |
20 |
21 |
22 |
23 |
86 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-ts-allow-js-in-vue
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Type Support for `.vue` Imports in TS
10 |
11 | TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12 |
13 | If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14 |
15 | 1. Disable the built-in TypeScript Extension
16 | 1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17 | 2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18 | 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19 |
20 | ## Customize configuration
21 |
22 | See [Vite Configuration Reference](https://vitejs.dev/config/).
23 |
24 | ## Project Setup
25 |
26 | ```sh
27 | pnpm install
28 | ```
29 |
30 | ### Compile and Hot-Reload for Development
31 |
32 | ```sh
33 | pnpm dev
34 | ```
35 |
36 | ### Type-Check, Compile and Minify for Production
37 |
38 | ```sh
39 | pnpm build
40 | ```
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-ts-allow-jsx-in-vue
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Type Support for `.vue` Imports in TS
10 |
11 | TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12 |
13 | If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14 |
15 | 1. Disable the built-in TypeScript Extension
16 | 1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17 | 2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18 | 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19 |
20 | ## Customize configuration
21 |
22 | See [Vite Configuration Reference](https://vitejs.dev/config/).
23 |
24 | ## Project Setup
25 |
26 | ```sh
27 | pnpm install
28 | ```
29 |
30 | ### Compile and Hot-Reload for Development
31 |
32 | ```sh
33 | pnpm dev
34 | ```
35 |
36 | ### Type-Check, Compile and Minify for Production
37 |
38 | ```sh
39 | pnpm build
40 | ```
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/README.md:
--------------------------------------------------------------------------------
1 | # create-vue-ts-allow-tsx-in-vue
2 |
3 | This template should help get you started developing with Vue 3 in Vite.
4 |
5 | ## Recommended IDE Setup
6 |
7 | [VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin).
8 |
9 | ## Type Support for `.vue` Imports in TS
10 |
11 | TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin) to make the TypeScript language service aware of `.vue` types.
12 |
13 | If the standalone TypeScript plugin doesn't feel fast enough to you, Volar has also implemented a [Take Over Mode](https://github.com/johnsoncodehk/volar/discussions/471#discussioncomment-1361669) that is more performant. You can enable it by the following steps:
14 |
15 | 1. Disable the built-in TypeScript Extension
16 | 1) Run `Extensions: Show Built-in Extensions` from VSCode's command palette
17 | 2) Find `TypeScript and JavaScript Language Features`, right click and select `Disable (Workspace)`
18 | 2. Reload the VSCode window by running `Developer: Reload Window` from the command palette.
19 |
20 | ## Customize configuration
21 |
22 | See [Vite Configuration Reference](https://vitejs.dev/config/).
23 |
24 | ## Project Setup
25 |
26 | ```sh
27 | pnpm install
28 | ```
29 |
30 | ### Compile and Hot-Reload for Development
31 |
32 | ```sh
33 | pnpm dev
34 | ```
35 |
36 | ### Type-Check, Compile and Minify for Production
37 |
38 | ```sh
39 | pnpm build
40 | ```
41 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/WelcomeItem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
87 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/App.vue:
--------------------------------------------------------------------------------
1 |
7 |
8 |
9 |
21 |
22 |
23 |
24 |
25 |
88 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "@vue/eslint-config-airbnb",
3 | "version": "8.0.0",
4 | "description": "eslint-config-standard for Vue.js projects",
5 | "main": "index.js",
6 | "exports": {
7 | ".": "./index.js",
8 | "./createAliasSetting": "./createAliasSetting.js",
9 | "./package.json": "./package.json",
10 | "./rules/imports": "./rules/imports.js",
11 | "./rules/jsx": "./rules/jsx.js",
12 | "./rules/jsx-a11y": "./rules/jsx-a11y.js",
13 | "./rules/template": "./rules/template.js",
14 | "./rules/template-a11y": "./rules/template-a11y.js",
15 | "./rules/misc": "./rules/misc.js"
16 | },
17 | "publishConfig": {
18 | "access": "public"
19 | },
20 | "repository": {
21 | "type": "git",
22 | "url": "git+https://github.com/vuejs/eslint-config-airbnb.git",
23 | "directory": "packages/eslint-config-airbnb"
24 | },
25 | "keywords": [
26 | "vue",
27 | "eslint",
28 | "airbnb"
29 | ],
30 | "author": "Evan You",
31 | "license": "MIT",
32 | "bugs": {
33 | "url": "https://github.com/vuejs/eslint-config-airbnb/issues"
34 | },
35 | "homepage": "https://github.com/vuejs/eslint-config-airbnb/blob/main/packages/eslint-config-airbnb#readme",
36 | "scripts": {
37 | "test": "eslint . --no-fix"
38 | },
39 | "dependencies": {
40 | "eslint-config-airbnb-base": "^15.0.0",
41 | "eslint-import-resolver-custom-alias": "^1.3.2",
42 | "eslint-import-resolver-node": "^0.3.9",
43 | "eslint-plugin-import": "^2.29.1",
44 | "eslint-plugin-jsx-a11y": "^6.8.0",
45 | "eslint-plugin-react": "^7.33.2",
46 | "eslint-plugin-vuejs-accessibility": "^2.0.0",
47 | "vue-eslint-parser": "^9.3.2"
48 | },
49 | "peerDependencies": {
50 | "eslint": "^8.2.0",
51 | "eslint-plugin-vue": "^9.2.0"
52 | },
53 | "devDependencies": {
54 | "eslint": "^8.56.0",
55 | "eslint-plugin-vue": "^9.19.2"
56 | }
57 | }
58 |
--------------------------------------------------------------------------------
/examples/create-vue-js/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-cypress/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-js-in-vue/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-jsx-in-vue/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/examples/create-vue-ts-allow-tsx-in-vue/src/components/icons/IconEcosystem.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/packages/eslint-config-airbnb-with-typescript/allow-js-in-vue.js:
--------------------------------------------------------------------------------
1 | const { defineConfig } = require('eslint-define-config');
2 |
3 | module.exports = defineConfig({
4 | overrides: [
5 | {
6 | files: ['*.vue'],
7 | rules: {
8 | // In the `-with-typescript` ruleset,
9 | // some rules are turned off because TypeScript can handle those case (e.g. `no-undef`).
10 | // But these rules won't apply to `