Tracking de l'application VApp (IHM du jeu)

This commit is contained in:
2025-05-11 18:04:12 +02:00
commit 89e9db9b62
17763 changed files with 3718499 additions and 0 deletions

21
VApp/node_modules/vue-eslint-parser/LICENSE generated vendored Normal file
View File

@ -0,0 +1,21 @@
MIT License
Copyright (c) 2016 Toru Nagashima
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

330
VApp/node_modules/vue-eslint-parser/README.md generated vendored Normal file
View File

@ -0,0 +1,330 @@
# vue-eslint-parser
[![npm version](https://img.shields.io/npm/v/vue-eslint-parser.svg)](https://www.npmjs.com/package/vue-eslint-parser)
[![Downloads/month](https://img.shields.io/npm/dm/vue-eslint-parser.svg)](http://www.npmtrends.com/vue-eslint-parser)
[![Build Status](https://github.com/vuejs/vue-eslint-parser/workflows/CI/badge.svg)](https://github.com/vuejs/vue-eslint-parser/actions)
[![Coverage Status](https://codecov.io/gh/vuejs/vue-eslint-parser/branch/master/graph/badge.svg)](https://codecov.io/gh/vuejs/vue-eslint-parser)
The ESLint custom parser for `.vue` files.
## ⤴️ Motivation
This parser allows us to lint the `<template>` of `.vue` files. We can make mistakes easily on `<template>` if we use complex directives and expressions in the template. This parser and the rules of [eslint-plugin-vue](https://github.com/vuejs/eslint-plugin-vue) would catch some of the mistakes.
## 💿 Installation
```bash
npm install --save-dev eslint vue-eslint-parser
```
- Requires Node.js ^14.17.0, 16.0.0 or later.
- Requires ESLint 6.0.0 or later.
## 📖 Usage
1. Write `parser` option into your `.eslintrc.*` file.
2. Use glob patterns or `--ext .vue` CLI option.
```json
{
"extends": "eslint:recommended",
"parser": "vue-eslint-parser"
}
```
```console
$ eslint "src/**/*.{js,vue}"
# or
$ eslint src --ext .vue
```
## 🔧 Options
`parserOptions` has the same properties as what [espree](https://github.com/eslint/espree#usage), the default parser of ESLint, is supporting.
For example:
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"sourceType": "module",
"ecmaVersion": 2018,
"ecmaFeatures": {
"globalReturn": false,
"impliedStrict": false,
"jsx": false
}
}
}
```
### parserOptions.parser
You can use `parserOptions.parser` property to specify a custom parser to parse `<script>` tags.
Other properties than parser would be given to the specified parser.
For example:
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"parser": "@babel/eslint-parser",
"sourceType": "module"
}
}
```
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"parser": "@typescript-eslint/parser",
"sourceType": "module"
}
}
```
You can also specify an object and change the parser separately for `<script lang="...">`.
```jsonc
{
"parser": "vue-eslint-parser",
"parserOptions": {
"parser": {
// Script parser for `<script>`
"js": "espree",
// Script parser for `<script lang="ts">`
"ts": "@typescript-eslint/parser",
// Script parser for vue directives (e.g. `v-if=` or `:attribute=`)
// and vue interpolations (e.g. `{{variable}}`).
// If not specified, the parser determined by `<script lang ="...">` is used.
"<template>": "espree",
}
}
}
```
When using JavaScript configuration (`.eslintrc.js`), you can also give the parser object directly.
```js
const tsParser = require("@typescript-eslint/parser")
const espree = require("espree")
module.exports = {
parser: "vue-eslint-parser",
parserOptions: {
// Single parser
parser: tsParser,
// Multiple parser
parser: {
js: espree,
ts: tsParser,
}
},
}
```
If the `parserOptions.parser` is `false`, the `vue-eslint-parser` skips parsing `<script>` tags completely.
This is useful for people who use the language ESLint community doesn't provide custom parser implementation.
### parserOptions.vueFeatures
You can use `parserOptions.vueFeatures` property to specify how to parse related to Vue features.
For example:
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"vueFeatures": {
"filter": true,
"interpolationAsNonHTML": true,
"styleCSSVariableInjection": true,
"customMacros": []
}
}
}
```
### parserOptions.vueFeatures.filter
You can use `parserOptions.vueFeatures.filter` property to specify whether to parse the Vue2 filter. If you specify `false`, the parser does not parse `|` as a filter.
For example:
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"vueFeatures": {
"filter": false
}
}
}
```
If you specify `false`, it can be parsed in the same way as Vue 3.
The following template parses as a bitwise operation.
```vue
<template>
<div>{{ a | b }}</div>
</template>
```
However, the following template that are valid in Vue 2 cannot be parsed.
```vue
<template>
<div>{{ a | valid:filter }}</div>
</template>
```
### parserOptions.vueFeatures.interpolationAsNonHTML
You can use `parserOptions.vueFeatures.interpolationAsNonHTML` property to specify whether to parse the interpolation as HTML. If you specify `true`, the parser handles the interpolation as non-HTML (However, you can use HTML escaping in the interpolation). Default is `true`.
For example:
```json
{
"parser": "vue-eslint-parser",
"parserOptions": {
"vueFeatures": {
"interpolationAsNonHTML": true
}
}
}
```
If you specify `true`, it can be parsed in the same way as Vue 3.
The following template can be parsed well.
```vue
<template>
<div>{{a<b}}</div>
</template>
```
But, it cannot be parsed with Vue 2.
### parserOptions.vueFeatures.styleCSSVariableInjection
If set to `true`, to parse expressions in `v-bind` CSS functions inside `<style>` tags. `v-bind()` is parsed into the `VExpressionContainer` AST node and held in the `VElement` of `<style>`. Default is `true`.
See also to [here](https://github.com/vuejs/rfcs/blob/master/active-rfcs/0043-sfc-style-variables.md).
### parserOptions.vueFeatures.customMacros
Specifies an array of names of custom macros other than Vue standard macros.
For example, if you have a custom macro `defineFoo()` and you want it processed by the parser, specify `["defineFoo"]`.
Note that this option only works in `<script setup>`.
### parserOptions.templateTokenizer
**This is an experimental feature. It may be changed or deleted without notice in the minor version.**
You can use `parserOptions.templateTokenizer` property to specify custom tokenizers to parse `<template lang="...">` tags.
For example to enable parsing of pug templates:
```jsonc
{
"parser": "vue-eslint-parser",
"parserOptions": {
"templateTokenizer": {
// template tokenizer for `<template lang="pug">`
"pug": "vue-eslint-parser-template-tokenizer-pug",
}
}
}
```
This option is only intended for plugin developers. **Be careful** when using this option directly, as it may change behaviour of rules you might have enabled.
If you just want **pug** support, use [eslint-plugin-vue-pug](https://github.com/rashfael/eslint-plugin-vue-pug) instead, which uses this option internally.
See [implementing-custom-template-tokenizers.md](./docs/implementing-custom-template-tokenizers.md) for information on creating your own template tokenizer.
## 🎇 Usage for custom rules / plugins
- This parser provides `parserServices` to traverse `<template>`.
- `defineTemplateBodyVisitor(templateVisitor, scriptVisitor, options)` ... returns ESLint visitor to traverse `<template>`.
- `getTemplateBodyTokenStore()` ... returns ESLint `TokenStore` to get the tokens of `<template>`.
- `getDocumentFragment()` ... returns the root `VDocumentFragment`.
- `defineCustomBlocksVisitor(context, customParser, rule, scriptVisitor)` ... returns ESLint visitor that parses and traverses the contents of the custom block.
- `defineDocumentVisitor(documentVisitor, options)` ... returns ESLint visitor to traverses the document.
- [ast.md](./docs/ast.md) is `<template>` AST specification.
- [mustache-interpolation-spacing.js](https://github.com/vuejs/eslint-plugin-vue/blob/b434ff99d37f35570fa351681e43ba2cf5746db3/lib/rules/mustache-interpolation-spacing.js) is an example.
### `defineTemplateBodyVisitor(templateBodyVisitor, scriptVisitor, options)`
*Arguments*
- `templateBodyVisitor` ... Event handlers for `<template>`.
- `scriptVisitor` ... Event handlers for `<script>` or scripts. (optional)
- `options` ... Options. (optional)
- `templateBodyTriggerSelector` ... Script AST node selector that triggers the templateBodyVisitor. Default is `"Program:exit"`. (optional)
```ts
import { AST } from "vue-eslint-parser"
export function create(context) {
return context.parserServices.defineTemplateBodyVisitor(
// Event handlers for <template>.
{
VElement(node: AST.VElement): void {
//...
}
},
// Event handlers for <script> or scripts. (optional)
{
Program(node: AST.ESLintProgram): void {
//...
}
},
// Options. (optional)
{
templateBodyTriggerSelector: "Program:exit"
}
)
}
```
## ⚠️ Known Limitations
Some rules make warnings due to the outside of `<script>` tags.
Please disable those rules for `.vue` files as necessary.
- [eol-last](http://eslint.org/docs/rules/eol-last)
- [linebreak-style](http://eslint.org/docs/rules/linebreak-style)
- [max-len](http://eslint.org/docs/rules/max-len)
- [max-lines](http://eslint.org/docs/rules/max-lines)
- [no-trailing-spaces](http://eslint.org/docs/rules/no-trailing-spaces)
- [unicode-bom](http://eslint.org/docs/rules/unicode-bom)
- Other rules which are using the source code text instead of AST might be confused as well.
## 📰 Changelog
- [GitHub Releases](https://github.com/vuejs/vue-eslint-parser/releases)
## 🍻 Contributing
Welcome contributing!
Please use GitHub's Issues/PRs.
If you want to write code, please execute `npm install && npm run setup` after you cloned this repository.
The `npm install` command installs dependencies.
The `npm run setup` command initializes ESLint as git submodules for tests.
### Development Tools
- `npm test` runs tests and measures coverage.
- `npm run build` compiles TypeScript source code to `index.js`, `index.js.map`, and `index.d.ts`.
- `npm run coverage` shows the coverage result of `npm test` command with the default browser.
- `npm run clean` removes the temporary files which are created by `npm test` and `npm run build`.
- `npm run lint` runs ESLint.
- `npm run setup` setups submodules to develop.
- `npm run update-fixtures` updates files in `test/fixtures/ast` directory based on `test/fixtures/ast/*/source.vue` files.
- `npm run watch` runs `build`, `update-fixtures`, and tests with `--watch` option.

667
VApp/node_modules/vue-eslint-parser/index.d.ts generated vendored Normal file
View File

@ -0,0 +1,667 @@
// Generated by dts-bundle v0.7.3
// Dependencies for this module:
// ../eslint-scope
// ../@typescript-eslint/utils
// ../eslint-visitor-keys
declare module 'vue-eslint-parser' {
import * as AST from "vue-eslint-parser/ast";
export function parseForESLint(code: string, parserOptions: any): AST.ESLintExtendedProgram;
export function parse(code: string, options: any): AST.ESLintProgram;
export { AST };
export const meta: {
name: string;
version: string | undefined;
};
}
declare module 'vue-eslint-parser/ast' {
export * from "vue-eslint-parser/ast/errors";
export * from "vue-eslint-parser/ast/locations";
export * from "vue-eslint-parser/ast/nodes";
export * from "vue-eslint-parser/ast/tokens";
export * from "vue-eslint-parser/ast/traverse";
}
declare module 'vue-eslint-parser/ast/errors' {
export class ParseError extends SyntaxError {
code?: ErrorCode;
index: number;
lineNumber: number;
column: number;
static fromCode(code: ErrorCode, offset: number, line: number, column: number): ParseError;
static normalize(x: any): ParseError | null;
constructor(message: string, code: ErrorCode | undefined, offset: number, line: number, column: number);
static isParseError(x: any): x is ParseError;
}
export type ErrorCode = "abrupt-closing-of-empty-comment" | "absence-of-digits-in-numeric-character-reference" | "cdata-in-html-content" | "character-reference-outside-unicode-range" | "control-character-in-input-stream" | "control-character-reference" | "eof-before-tag-name" | "eof-in-cdata" | "eof-in-comment" | "eof-in-tag" | "incorrectly-closed-comment" | "incorrectly-opened-comment" | "invalid-first-character-of-tag-name" | "missing-attribute-value" | "missing-end-tag-name" | "missing-semicolon-after-character-reference" | "missing-whitespace-between-attributes" | "nested-comment" | "noncharacter-character-reference" | "noncharacter-in-input-stream" | "null-character-reference" | "surrogate-character-reference" | "surrogate-in-input-stream" | "unexpected-character-in-attribute-name" | "unexpected-character-in-unquoted-attribute-value" | "unexpected-equals-sign-before-attribute-name" | "unexpected-null-character" | "unexpected-question-mark-instead-of-tag-name" | "unexpected-solidus-in-tag" | "unknown-named-character-reference" | "end-tag-with-attributes" | "duplicate-attribute" | "end-tag-with-trailing-solidus" | "non-void-html-element-start-tag-with-trailing-solidus" | "x-invalid-end-tag" | "x-invalid-namespace" | "x-missing-interpolation-end";
}
declare module 'vue-eslint-parser/ast/locations' {
export interface Location {
line: number;
column: number;
}
export interface LocationRange {
start: Location;
end: Location;
}
export type Offset = number;
export type OffsetRange = [Offset, Offset];
export interface HasLocation {
range: OffsetRange;
loc: LocationRange;
start?: number;
end?: number;
}
}
declare module 'vue-eslint-parser/ast/nodes' {
import type { ScopeManager } from "eslint-scope";
import type { ParseError } from "vue-eslint-parser/ast/errors";
import type { HasLocation } from "vue-eslint-parser/ast/locations";
import type { Token } from "vue-eslint-parser/ast/tokens";
import type { TSESTree } from "@typescript-eslint/utils";
export interface HasParent {
parent?: Node | null;
}
export type Node = ESLintNode | VNode | VForExpression | VOnExpression | VSlotScopeExpression | VGenericExpression | VFilterSequenceExpression | VFilter;
export type ESLintNode = ESLintIdentifier | ESLintLiteral | ESLintProgram | ESLintSwitchCase | ESLintCatchClause | ESLintVariableDeclarator | ESLintStatement | ESLintExpression | ESLintProperty | ESLintAssignmentProperty | ESLintSuper | ESLintTemplateElement | ESLintSpreadElement | ESLintPattern | ESLintClassBody | ESLintMethodDefinition | ESLintPropertyDefinition | ESLintStaticBlock | ESLintPrivateIdentifier | ESLintModuleDeclaration | ESLintModuleSpecifier | ESLintImportExpression | ESLintLegacyRestProperty;
export interface ESLintExtendedProgram {
ast: ESLintProgram;
services?: {};
visitorKeys?: {
[type: string]: string[];
};
scopeManager?: ScopeManager;
}
export interface ESLintProgram extends HasLocation, HasParent {
type: "Program";
sourceType: "script" | "module";
body: (ESLintStatement | ESLintModuleDeclaration)[];
templateBody?: VElement & HasConcreteInfo;
tokens?: Token[];
comments?: Token[];
errors?: ParseError[];
}
export type ESLintStatement = ESLintExpressionStatement | ESLintBlockStatement | ESLintEmptyStatement | ESLintDebuggerStatement | ESLintWithStatement | ESLintReturnStatement | ESLintLabeledStatement | ESLintBreakStatement | ESLintContinueStatement | ESLintIfStatement | ESLintSwitchStatement | ESLintThrowStatement | ESLintTryStatement | ESLintWhileStatement | ESLintDoWhileStatement | ESLintForStatement | ESLintForInStatement | ESLintForOfStatement | ESLintDeclaration;
export interface ESLintEmptyStatement extends HasLocation, HasParent {
type: "EmptyStatement";
}
export interface ESLintBlockStatement extends HasLocation, HasParent {
type: "BlockStatement";
body: ESLintStatement[];
}
export interface ESLintExpressionStatement extends HasLocation, HasParent {
type: "ExpressionStatement";
expression: ESLintExpression;
}
export interface ESLintIfStatement extends HasLocation, HasParent {
type: "IfStatement";
test: ESLintExpression;
consequent: ESLintStatement;
alternate: ESLintStatement | null;
}
export interface ESLintSwitchStatement extends HasLocation, HasParent {
type: "SwitchStatement";
discriminant: ESLintExpression;
cases: ESLintSwitchCase[];
}
export interface ESLintSwitchCase extends HasLocation, HasParent {
type: "SwitchCase";
test: ESLintExpression | null;
consequent: ESLintStatement[];
}
export interface ESLintWhileStatement extends HasLocation, HasParent {
type: "WhileStatement";
test: ESLintExpression;
body: ESLintStatement;
}
export interface ESLintDoWhileStatement extends HasLocation, HasParent {
type: "DoWhileStatement";
body: ESLintStatement;
test: ESLintExpression;
}
export interface ESLintForStatement extends HasLocation, HasParent {
type: "ForStatement";
init: ESLintVariableDeclaration | ESLintExpression | null;
test: ESLintExpression | null;
update: ESLintExpression | null;
body: ESLintStatement;
}
export interface ESLintForInStatement extends HasLocation, HasParent {
type: "ForInStatement";
left: ESLintVariableDeclaration | ESLintPattern;
right: ESLintExpression;
body: ESLintStatement;
}
export interface ESLintForOfStatement extends HasLocation, HasParent {
type: "ForOfStatement";
left: ESLintVariableDeclaration | ESLintPattern;
right: ESLintExpression;
body: ESLintStatement;
await: boolean;
}
export interface ESLintLabeledStatement extends HasLocation, HasParent {
type: "LabeledStatement";
label: ESLintIdentifier;
body: ESLintStatement;
}
export interface ESLintBreakStatement extends HasLocation, HasParent {
type: "BreakStatement";
label: ESLintIdentifier | null;
}
export interface ESLintContinueStatement extends HasLocation, HasParent {
type: "ContinueStatement";
label: ESLintIdentifier | null;
}
export interface ESLintReturnStatement extends HasLocation, HasParent {
type: "ReturnStatement";
argument: ESLintExpression | null;
}
export interface ESLintThrowStatement extends HasLocation, HasParent {
type: "ThrowStatement";
argument: ESLintExpression;
}
export interface ESLintTryStatement extends HasLocation, HasParent {
type: "TryStatement";
block: ESLintBlockStatement;
handler: ESLintCatchClause | null;
finalizer: ESLintBlockStatement | null;
}
export interface ESLintCatchClause extends HasLocation, HasParent {
type: "CatchClause";
param: ESLintPattern | null;
body: ESLintBlockStatement;
}
export interface ESLintWithStatement extends HasLocation, HasParent {
type: "WithStatement";
object: ESLintExpression;
body: ESLintStatement;
}
export interface ESLintDebuggerStatement extends HasLocation, HasParent {
type: "DebuggerStatement";
}
export type ESLintDeclaration = ESLintFunctionDeclaration | ESLintVariableDeclaration | ESLintClassDeclaration;
export interface ESLintFunctionDeclaration extends HasLocation, HasParent {
type: "FunctionDeclaration";
async: boolean;
generator: boolean;
id: ESLintIdentifier | null;
params: ESLintPattern[];
body: ESLintBlockStatement;
}
export interface ESLintVariableDeclaration extends HasLocation, HasParent {
type: "VariableDeclaration";
kind: "var" | "let" | "const";
declarations: ESLintVariableDeclarator[];
}
export interface ESLintVariableDeclarator extends HasLocation, HasParent {
type: "VariableDeclarator";
id: ESLintPattern;
init: ESLintExpression | null;
}
export interface ESLintClassDeclaration extends HasLocation, HasParent {
type: "ClassDeclaration";
id: ESLintIdentifier | null;
superClass: ESLintExpression | null;
body: ESLintClassBody;
}
export interface ESLintClassBody extends HasLocation, HasParent {
type: "ClassBody";
body: (ESLintMethodDefinition | ESLintPropertyDefinition | ESLintStaticBlock)[];
}
export interface ESLintMethodDefinition extends HasLocation, HasParent {
type: "MethodDefinition";
kind: "constructor" | "method" | "get" | "set";
computed: boolean;
static: boolean;
key: ESLintExpression | ESLintPrivateIdentifier;
value: ESLintFunctionExpression;
}
export interface ESLintPropertyDefinition extends HasLocation, HasParent {
type: "PropertyDefinition";
computed: boolean;
static: boolean;
key: ESLintExpression | ESLintPrivateIdentifier;
value: ESLintExpression | null;
}
export interface ESLintStaticBlock extends HasLocation, HasParent, Omit<ESLintBlockStatement, "type"> {
type: "StaticBlock";
body: ESLintStatement[];
}
export interface ESLintPrivateIdentifier extends HasLocation, HasParent {
type: "PrivateIdentifier";
name: string;
}
export type ESLintModuleDeclaration = ESLintImportDeclaration | ESLintExportNamedDeclaration | ESLintExportDefaultDeclaration | ESLintExportAllDeclaration;
export type ESLintModuleSpecifier = ESLintImportSpecifier | ESLintImportDefaultSpecifier | ESLintImportNamespaceSpecifier | ESLintExportSpecifier;
export interface ESLintImportDeclaration extends HasLocation, HasParent {
type: "ImportDeclaration";
specifiers: (ESLintImportSpecifier | ESLintImportDefaultSpecifier | ESLintImportNamespaceSpecifier)[];
source: ESLintLiteral;
}
export interface ESLintImportSpecifier extends HasLocation, HasParent {
type: "ImportSpecifier";
imported: ESLintIdentifier | ESLintStringLiteral;
local: ESLintIdentifier;
}
export interface ESLintImportDefaultSpecifier extends HasLocation, HasParent {
type: "ImportDefaultSpecifier";
local: ESLintIdentifier;
}
export interface ESLintImportNamespaceSpecifier extends HasLocation, HasParent {
type: "ImportNamespaceSpecifier";
local: ESLintIdentifier;
}
export interface ESLintImportExpression extends HasLocation, HasParent {
type: "ImportExpression";
source: ESLintExpression;
}
export interface ESLintExportNamedDeclaration extends HasLocation, HasParent {
type: "ExportNamedDeclaration";
declaration?: ESLintDeclaration | null;
specifiers: ESLintExportSpecifier[];
source?: ESLintLiteral | null;
}
export interface ESLintExportSpecifier extends HasLocation, HasParent {
type: "ExportSpecifier";
local: ESLintIdentifier | ESLintStringLiteral;
exported: ESLintIdentifier | ESLintStringLiteral;
}
export interface ESLintExportDefaultDeclaration extends HasLocation, HasParent {
type: "ExportDefaultDeclaration";
declaration: ESLintDeclaration | ESLintExpression;
}
export interface ESLintExportAllDeclaration extends HasLocation, HasParent {
type: "ExportAllDeclaration";
exported: ESLintIdentifier | ESLintStringLiteral | null;
source: ESLintLiteral;
}
export type ESLintExpression = ESLintThisExpression | ESLintArrayExpression | ESLintObjectExpression | ESLintFunctionExpression | ESLintArrowFunctionExpression | ESLintYieldExpression | ESLintLiteral | ESLintUnaryExpression | ESLintUpdateExpression | ESLintBinaryExpression | ESLintAssignmentExpression | ESLintLogicalExpression | ESLintMemberExpression | ESLintConditionalExpression | ESLintCallExpression | ESLintNewExpression | ESLintSequenceExpression | ESLintTemplateLiteral | ESLintTaggedTemplateExpression | ESLintClassExpression | ESLintMetaProperty | ESLintIdentifier | ESLintAwaitExpression | ESLintChainExpression;
export interface ESLintIdentifier extends HasLocation, HasParent {
type: "Identifier";
name: string;
}
interface ESLintLiteralBase extends HasLocation, HasParent {
type: "Literal";
value: string | boolean | null | number | RegExp | bigint;
raw: string;
regex?: {
pattern: string;
flags: string;
};
bigint?: string;
}
export interface ESLintStringLiteral extends ESLintLiteralBase {
value: string;
regex?: undefined;
bigint?: undefined;
}
export interface ESLintBooleanLiteral extends ESLintLiteralBase {
value: boolean;
regex?: undefined;
bigint?: undefined;
}
export interface ESLintNullLiteral extends ESLintLiteralBase {
value: null;
regex?: undefined;
bigint?: undefined;
}
export interface ESLintNumberLiteral extends ESLintLiteralBase {
value: number;
regex?: undefined;
bigint?: undefined;
}
export interface ESLintRegExpLiteral extends ESLintLiteralBase {
value: null | RegExp;
regex: {
pattern: string;
flags: string;
};
bigint?: undefined;
}
export interface ESLintBigIntLiteral extends ESLintLiteralBase {
value: null | bigint;
regex?: undefined;
bigint: string;
}
export type ESLintLiteral = ESLintStringLiteral | ESLintBooleanLiteral | ESLintNullLiteral | ESLintNumberLiteral | ESLintRegExpLiteral | ESLintBigIntLiteral;
export interface ESLintThisExpression extends HasLocation, HasParent {
type: "ThisExpression";
}
export interface ESLintArrayExpression extends HasLocation, HasParent {
type: "ArrayExpression";
elements: (ESLintExpression | ESLintSpreadElement)[];
}
export interface ESLintObjectExpression extends HasLocation, HasParent {
type: "ObjectExpression";
properties: (ESLintProperty | ESLintSpreadElement | ESLintLegacySpreadProperty)[];
}
export interface ESLintProperty extends HasLocation, HasParent {
type: "Property";
kind: "init" | "get" | "set";
method: boolean;
shorthand: boolean;
computed: boolean;
key: ESLintExpression;
value: ESLintExpression | ESLintPattern;
}
export interface ESLintFunctionExpression extends HasLocation, HasParent {
type: "FunctionExpression";
async: boolean;
generator: boolean;
id: ESLintIdentifier | null;
params: ESLintPattern[];
body: ESLintBlockStatement;
}
export interface ESLintArrowFunctionExpression extends HasLocation, HasParent {
type: "ArrowFunctionExpression";
async: boolean;
generator: boolean;
id: ESLintIdentifier | null;
params: ESLintPattern[];
body: ESLintBlockStatement;
}
export interface ESLintSequenceExpression extends HasLocation, HasParent {
type: "SequenceExpression";
expressions: ESLintExpression[];
}
export interface ESLintUnaryExpression extends HasLocation, HasParent {
type: "UnaryExpression";
operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
prefix: boolean;
argument: ESLintExpression;
}
export interface ESLintBinaryExpression extends HasLocation, HasParent {
type: "BinaryExpression";
operator: "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "**" | "|" | "^" | "&" | "in" | "instanceof";
left: ESLintExpression | ESLintPrivateIdentifier;
right: ESLintExpression;
}
export interface ESLintAssignmentExpression extends HasLocation, HasParent {
type: "AssignmentExpression";
operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "**=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "||=" | "&&=" | "??=";
left: ESLintPattern;
right: ESLintExpression;
}
export interface ESLintUpdateExpression extends HasLocation, HasParent {
type: "UpdateExpression";
operator: "++" | "--";
argument: ESLintExpression;
prefix: boolean;
}
export interface ESLintLogicalExpression extends HasLocation, HasParent {
type: "LogicalExpression";
operator: "||" | "&&" | "??";
left: ESLintExpression;
right: ESLintExpression;
}
export interface ESLintConditionalExpression extends HasLocation, HasParent {
type: "ConditionalExpression";
test: ESLintExpression;
alternate: ESLintExpression;
consequent: ESLintExpression;
}
export interface ESLintCallExpression extends HasLocation, HasParent {
type: "CallExpression";
optional: boolean;
callee: ESLintExpression | ESLintSuper;
arguments: (ESLintExpression | ESLintSpreadElement)[];
}
export interface ESLintSuper extends HasLocation, HasParent {
type: "Super";
}
export interface ESLintNewExpression extends HasLocation, HasParent {
type: "NewExpression";
callee: ESLintExpression;
arguments: (ESLintExpression | ESLintSpreadElement)[];
}
export interface ESLintMemberExpression extends HasLocation, HasParent {
type: "MemberExpression";
optional: boolean;
computed: boolean;
object: ESLintExpression | ESLintSuper;
property: ESLintExpression | ESLintPrivateIdentifier;
}
export interface ESLintYieldExpression extends HasLocation, HasParent {
type: "YieldExpression";
delegate: boolean;
argument: ESLintExpression | null;
}
export interface ESLintAwaitExpression extends HasLocation, HasParent {
type: "AwaitExpression";
argument: ESLintExpression;
}
export interface ESLintTemplateLiteral extends HasLocation, HasParent {
type: "TemplateLiteral";
quasis: ESLintTemplateElement[];
expressions: ESLintExpression[];
}
export interface ESLintTaggedTemplateExpression extends HasLocation, HasParent {
type: "TaggedTemplateExpression";
tag: ESLintExpression;
quasi: ESLintTemplateLiteral;
}
export interface ESLintTemplateElement extends HasLocation, HasParent {
type: "TemplateElement";
tail: boolean;
value: {
cooked: string | null;
raw: string;
};
}
export interface ESLintClassExpression extends HasLocation, HasParent {
type: "ClassExpression";
id: ESLintIdentifier | null;
superClass: ESLintExpression | null;
body: ESLintClassBody;
}
export interface ESLintMetaProperty extends HasLocation, HasParent {
type: "MetaProperty";
meta: ESLintIdentifier;
property: ESLintIdentifier;
}
export type ESLintPattern = ESLintIdentifier | ESLintObjectPattern | ESLintArrayPattern | ESLintRestElement | ESLintAssignmentPattern | ESLintMemberExpression | ESLintLegacyRestProperty;
export interface ESLintObjectPattern extends HasLocation, HasParent {
type: "ObjectPattern";
properties: (ESLintAssignmentProperty | ESLintRestElement | ESLintLegacyRestProperty)[];
}
export interface ESLintAssignmentProperty extends ESLintProperty {
value: ESLintPattern;
kind: "init";
method: false;
}
export interface ESLintArrayPattern extends HasLocation, HasParent {
type: "ArrayPattern";
elements: ESLintPattern[];
}
export interface ESLintRestElement extends HasLocation, HasParent {
type: "RestElement";
argument: ESLintPattern;
}
export interface ESLintSpreadElement extends HasLocation, HasParent {
type: "SpreadElement";
argument: ESLintExpression;
}
export interface ESLintAssignmentPattern extends HasLocation, HasParent {
type: "AssignmentPattern";
left: ESLintPattern;
right: ESLintExpression;
}
export type ESLintChainElement = ESLintCallExpression | ESLintMemberExpression;
export interface ESLintChainExpression extends HasLocation, HasParent {
type: "ChainExpression";
expression: ESLintChainElement;
}
export interface ESLintLegacyRestProperty extends HasLocation, HasParent {
type: "RestProperty" | "ExperimentalRestProperty";
argument: ESLintPattern;
}
export interface ESLintLegacySpreadProperty extends HasLocation, HasParent {
type: "SpreadProperty" | "ExperimentalSpreadProperty";
argument: ESLintExpression;
}
export const NS: Readonly<{
HTML: "http://www.w3.org/1999/xhtml";
MathML: "http://www.w3.org/1998/Math/MathML";
SVG: "http://www.w3.org/2000/svg";
XLink: "http://www.w3.org/1999/xlink";
XML: "http://www.w3.org/XML/1998/namespace";
XMLNS: "http://www.w3.org/2000/xmlns/";
}>;
export type Namespace = typeof NS.HTML | typeof NS.MathML | typeof NS.SVG | typeof NS.XLink | typeof NS.XML | typeof NS.XMLNS;
export interface Variable {
id: ESLintIdentifier;
kind: "v-for" | "scope" | "generic";
references: Reference[];
}
export interface Reference {
id: ESLintIdentifier;
mode: "rw" | "r" | "w";
variable: Variable | null;
isValueReference?: boolean;
isTypeReference?: boolean;
}
export interface VForExpression extends HasLocation, HasParent {
type: "VForExpression";
parent: VExpressionContainer;
left: ESLintPattern[];
right: ESLintExpression;
}
export interface VOnExpression extends HasLocation, HasParent {
type: "VOnExpression";
parent: VExpressionContainer;
body: ESLintStatement[];
}
export interface VSlotScopeExpression extends HasLocation, HasParent {
type: "VSlotScopeExpression";
parent: VExpressionContainer;
params: ESLintPattern[];
}
export interface VGenericExpression extends HasLocation, HasParent {
type: "VGenericExpression";
parent: VExpressionContainer;
params: TSESTree.TSTypeParameterDeclaration["params"];
rawParams: string[];
}
export interface VFilterSequenceExpression extends HasLocation, HasParent {
type: "VFilterSequenceExpression";
parent: VExpressionContainer;
expression: ESLintExpression;
filters: VFilter[];
}
export interface VFilter extends HasLocation, HasParent {
type: "VFilter";
parent: VFilterSequenceExpression;
callee: ESLintIdentifier;
arguments: (ESLintExpression | ESLintSpreadElement)[];
}
export type VNode = VAttribute | VDirective | VDirectiveKey | VDocumentFragment | VElement | VEndTag | VExpressionContainer | VIdentifier | VLiteral | VStartTag | VText;
export interface VText extends HasLocation, HasParent {
type: "VText";
parent: VDocumentFragment | VElement;
value: string;
}
export interface VExpressionContainer extends HasLocation, HasParent {
type: "VExpressionContainer";
parent: VDocumentFragment | VElement | VDirective | VDirectiveKey;
expression: ESLintExpression | VFilterSequenceExpression | VForExpression | VOnExpression | VSlotScopeExpression | VGenericExpression | null;
references: Reference[];
}
export interface VIdentifier extends HasLocation, HasParent {
type: "VIdentifier";
parent: VAttribute | VDirectiveKey;
name: string;
rawName: string;
}
export interface VDirectiveKey extends HasLocation, HasParent {
type: "VDirectiveKey";
parent: VDirective;
name: VIdentifier;
argument: VExpressionContainer | VIdentifier | null;
modifiers: VIdentifier[];
}
export interface VLiteral extends HasLocation, HasParent {
type: "VLiteral";
parent: VAttribute;
value: string;
}
export interface VAttribute extends HasLocation, HasParent {
type: "VAttribute";
parent: VStartTag;
directive: false;
key: VIdentifier;
value: VLiteral | null;
}
export interface VDirective extends HasLocation, HasParent {
type: "VAttribute";
parent: VStartTag;
directive: true;
key: VDirectiveKey;
value: VExpressionContainer | null;
}
export interface VStartTag extends HasLocation, HasParent {
type: "VStartTag";
parent: VElement;
selfClosing: boolean;
attributes: (VAttribute | VDirective)[];
}
export interface VEndTag extends HasLocation, HasParent {
type: "VEndTag";
parent: VElement;
}
export interface HasConcreteInfo {
tokens: Token[];
comments: Token[];
errors: ParseError[];
}
export interface VElement extends HasLocation, HasParent {
type: "VElement";
parent: VDocumentFragment | VElement;
namespace: Namespace;
name: string;
rawName: string;
startTag: VStartTag;
children: (VElement | VText | VExpressionContainer)[];
endTag: VEndTag | null;
variables: Variable[];
}
export interface VDocumentFragment extends HasLocation, HasParent, HasConcreteInfo {
type: "VDocumentFragment";
parent: null;
children: (VElement | VText | VExpressionContainer | VStyleElement)[];
}
export interface VStyleElement extends VElement {
type: "VElement";
name: "style";
style: true;
children: (VText | VExpressionContainer)[];
}
export {};
}
declare module 'vue-eslint-parser/ast/tokens' {
import type { HasLocation } from "vue-eslint-parser/ast/locations";
export interface Token extends HasLocation {
type: string;
value: string;
}
}
declare module 'vue-eslint-parser/ast/traverse' {
import type { VisitorKeys } from "eslint-visitor-keys";
import type { Node } from "vue-eslint-parser/ast/nodes";
export const KEYS: Readonly<{
[type: string]: readonly string[] | undefined;
}>;
function getFallbackKeys(node: Node): string[];
export interface Visitor {
visitorKeys?: VisitorKeys;
enterNode(node: Node, parent: Node | null): void;
leaveNode(node: Node, parent: Node | null): void;
}
export function traverseNodes(node: Node, visitor: Visitor): void;
export { getFallbackKeys };
}

6482
VApp/node_modules/vue-eslint-parser/index.js generated vendored Normal file

File diff suppressed because one or more lines are too long

1
VApp/node_modules/vue-eslint-parser/index.js.map generated vendored Normal file

File diff suppressed because one or more lines are too long

103
VApp/node_modules/vue-eslint-parser/package.json generated vendored Normal file
View File

@ -0,0 +1,103 @@
{
"name": "vue-eslint-parser",
"version": "9.4.2",
"description": "The ESLint custom parser for `.vue` files.",
"engines": {
"node": "^14.17.0 || >=16.0.0"
},
"main": "index.js",
"files": [
"index.*"
],
"peerDependencies": {
"eslint": ">=6.0.0"
},
"dependencies": {
"debug": "^4.3.4",
"eslint-scope": "^7.1.1",
"eslint-visitor-keys": "^3.3.0",
"espree": "^9.3.1",
"esquery": "^1.4.0",
"lodash": "^4.17.21",
"semver": "^7.3.6"
},
"devDependencies": {
"@babel/core": "^7.16.0",
"@babel/eslint-parser": "^7.16.3",
"@babel/plugin-syntax-decorators": "^7.16.0",
"@babel/plugin-syntax-pipeline-operator": "^7.16.0",
"@babel/plugin-syntax-typescript": "^7.16.0",
"@types/debug": "^4.1.7",
"@types/eslint": "^8.4.6",
"@types/estree": "^1.0.0",
"@types/lodash": "^4.14.186",
"@types/mocha": "^9.0.0",
"@types/node": "^18.8.4",
"@types/semver": "^7.3.12",
"@typescript-eslint/eslint-plugin": "^5.18.0",
"@typescript-eslint/parser": "^5.18.0",
"chokidar": "^3.5.2",
"codecov": "^3.8.3",
"cross-spawn": "^7.0.3",
"dts-bundle": "^0.7.3",
"eslint": "^8.12.0",
"eslint-plugin-eslint-comments": "^3.2.0",
"eslint-plugin-jsonc": "^2.2.1",
"eslint-plugin-node": "^11.1.0",
"eslint-plugin-node-dependencies": "^0.8.0",
"eslint-plugin-prettier": "^4.0.0",
"fs-extra": "^10.0.0",
"jsonc-eslint-parser": "^2.0.3",
"mocha": "^9.1.3",
"npm-run-all": "^4.1.5",
"nyc": "^15.1.0",
"opener": "^1.5.2",
"prettier": "^2.4.1",
"rimraf": "^3.0.2",
"rollup": "^2.60.0",
"rollup-plugin-node-resolve": "^5.2.0",
"rollup-plugin-replace": "^2.2.0",
"rollup-plugin-sourcemaps": "^0.6.3",
"ts-node": "^10.4.0",
"typescript": "~4.8.4",
"wait-on": "^6.0.0",
"warun": "^1.0.0"
},
"scripts": {
"prebuild": "npm run -s clean",
"build": "tsc --module es2015 && rollup -c -o index.js && dts-bundle --name vue-eslint-parser --main .temp/index.d.ts --out ../index.d.ts",
"clean": "rimraf .nyc_output .temp coverage index.*",
"codecov": "codecov",
"coverage": "opener ./coverage/lcov-report/index.html",
"lint": "eslint src test package.json --ext .js,.ts",
"setup": "git submodule update --init && cd test/fixtures/eslint && npm install",
"pretest": "run-s build lint",
"test": "npm run -s test:mocha",
"test:mocha": "mocha --require ts-node/register \"test/*.js\" --reporter dot --timeout 60000",
"test:cover": "nyc mocha \"test/*.js\" --reporter dot --timeout 60000",
"test:debug": "mocha --require ts-node/register/transpile-only \"test/*.js\" --reporter dot --timeout 60000",
"update-fixtures": "ts-node --transpile-only scripts/update-fixtures-ast.js && ts-node --transpile-only scripts/update-fixtures-document-fragment.js",
"preversion": "npm test",
"version": "npm run -s build",
"postversion": "git push && git push --tags",
"prewatch": "npm run -s clean",
"watch": "run-p watch:*",
"watch:tsc": "tsc --module es2015 --watch",
"watch:rollup": "wait-on .temp/index.js && rollup -c -o index.js --watch",
"watch:test": "wait-on index.js && warun index.js \"test/*.js\" \"test/fixtures/ast/*/*.json\" \"test/fixtures/*\" --debounce 1000 --no-initial -- nyc mocha \"test/*.js\" --reporter dot --timeout 10000",
"watch:update-ast": "wait-on index.js && warun index.js \"test/fixtures/ast/*/*.vue\" -- node scripts/update-fixtures-ast.js",
"watch:coverage-report": "wait-on coverage/lcov-report/index.html && opener coverage/lcov-report/index.html"
},
"repository": {
"type": "git",
"url": "git+https://github.com/vuejs/vue-eslint-parser.git"
},
"keywords": [],
"author": "Toru Nagashima",
"license": "MIT",
"bugs": {
"url": "https://github.com/vuejs/vue-eslint-parser/issues"
},
"homepage": "https://github.com/vuejs/vue-eslint-parser#readme",
"funding": "https://github.com/sponsors/mysticatea"
}