Skip to content

chore: release eslint-plugin-svelte #314

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 4, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .changeset/kind-boats-clean.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/little-points-poke.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/pink-zoos-wonder.md

This file was deleted.

10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
# eslint-plugin-svelte

## 2.14.0

### Minor Changes

- [#310](https://github.com/ota-meshi/eslint-plugin-svelte/pull/310) [`6d392c4`](https://github.com/ota-meshi/eslint-plugin-svelte/commit/6d392c4ac1d94e6f296858da99454198774c6bec) Thanks [@ota-meshi](https://github.com/ota-meshi)! - feat: improve `svelte/indent` rule to support more ts syntax

- [#308](https://github.com/ota-meshi/eslint-plugin-svelte/pull/308) [`a9c4912`](https://github.com/ota-meshi/eslint-plugin-svelte/commit/a9c4912b9d23fe7557786445fa8180a7b35bda21) Thanks [@ota-meshi](https://github.com/ota-meshi)! - feat: add `svelte/no-dupe-use-directives` rule

- [#308](https://github.com/ota-meshi/eslint-plugin-svelte/pull/308) [`a9c4912`](https://github.com/ota-meshi/eslint-plugin-svelte/commit/a9c4912b9d23fe7557786445fa8180a7b35bda21) Thanks [@ota-meshi](https://github.com/ota-meshi)! - feat: add `svelte/no-dupe-on-directives` rule

## 2.13.1

### Patch Changes
Expand Down
7 changes: 5 additions & 2 deletions docs/rules/no-dupe-on-directives.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ pageClass: "rule-details"
sidebarDepth: 0
title: "svelte/no-dupe-on-directives"
description: "disallow duplicate `on:` directives"
since: "v2.14.0"
---

# svelte/no-dupe-on-directives

> disallow duplicate `on:` directives

- :exclamation: <badge text="This rule has not been released yet." vertical="middle" type="error"> **_This rule has not been released yet._** </badge>

## :book: Rule Details

We can define any number of `on:` directive with the same event name, but duplicate directives with the exact same event name and expression are probably a mistake.
Expand Down Expand Up @@ -47,6 +46,10 @@ This rule reports reports `on:` directives with exactly the same event name and

Nothing.

## :rocket: Version

This rule was introduced in eslint-plugin-svelte v2.14.0

## :mag: Implementation

- [Rule source](https://github.com/ota-meshi/eslint-plugin-svelte/blob/main/src/rules/no-dupe-on-directives.ts)
Expand Down
7 changes: 5 additions & 2 deletions docs/rules/no-dupe-use-directives.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@ pageClass: "rule-details"
sidebarDepth: 0
title: "svelte/no-dupe-use-directives"
description: "disallow duplicate `use:` directives"
since: "v2.14.0"
---

# svelte/no-dupe-use-directives

> disallow duplicate `use:` directives

- :exclamation: <badge text="This rule has not been released yet." vertical="middle" type="error"> **_This rule has not been released yet._** </badge>

## :book: Rule Details

We can define any number of `use:` directive with the same action, but duplicate directives with the exact same action and expression are probably a mistake.
Expand Down Expand Up @@ -40,6 +39,10 @@ This rule reports reports `use:` directives with exactly the same action and exp

Nothing.

## :rocket: Version

This rule was introduced in eslint-plugin-svelte v2.14.0

## :mag: Implementation

- [Rule source](https://github.com/ota-meshi/eslint-plugin-svelte/blob/main/src/rules/no-dupe-use-directives.ts)
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eslint-plugin-svelte",
"version": "2.13.1",
"version": "2.14.0",
"description": "ESLint plugin for Svelte using AST",
"repository": "git+https://github.com/ota-meshi/eslint-plugin-svelte.git",
"homepage": "https://ota-meshi.github.io/eslint-plugin-svelte",
Expand Down Expand Up @@ -174,7 +174,7 @@
"access": "public"
},
"typeCoverage": {
"atLeast": 99.04,
"atLeast": 99.05,
"cache": true,
"detail": true,
"ignoreAsAssertion": true,
Expand Down
18 changes: 18 additions & 0 deletions src/types-for-node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ export type ASTNodeWithParent =
| AST.SvelteProgram

export type ASTNodeListener = {
AccessorProperty?: (
node: TSESTree.AccessorProperty & ASTNodeWithParent,
) => void
ArrayExpression?: (node: TSESTree.ArrayExpression & ASTNodeWithParent) => void
ArrayPattern?: (node: TSESTree.ArrayPattern & ASTNodeWithParent) => void
ArrowFunctionExpression?: (
Expand Down Expand Up @@ -181,6 +184,9 @@ export type ASTNodeListener = {
WhileStatement?: (node: TSESTree.WhileStatement & ASTNodeWithParent) => void
WithStatement?: (node: TSESTree.WithStatement & ASTNodeWithParent) => void
YieldExpression?: (node: TSESTree.YieldExpression & ASTNodeWithParent) => void
TSAbstractAccessorProperty?: (
node: TSESTree.TSAbstractAccessorProperty & ASTNodeWithParent,
) => void
TSAbstractKeyword?: (
node: TSESTree.TSAbstractKeyword & ASTNodeWithParent,
) => void
Expand Down Expand Up @@ -304,6 +310,9 @@ export type ASTNodeListener = {
node: TSESTree.TSReadonlyKeyword & ASTNodeWithParent,
) => void
TSRestType?: (node: TSESTree.TSRestType & ASTNodeWithParent) => void
TSSatisfiesExpression?: (
node: TSESTree.TSSatisfiesExpression & ASTNodeWithParent,
) => void
TSStaticKeyword?: (node: TSESTree.TSStaticKeyword & ASTNodeWithParent) => void
TSStringKeyword?: (node: TSESTree.TSStringKeyword & ASTNodeWithParent) => void
TSSymbolKeyword?: (node: TSESTree.TSSymbolKeyword & ASTNodeWithParent) => void
Expand Down Expand Up @@ -399,6 +408,9 @@ export type ASTNodeListener = {
}

export type ESNodeListener = {
AccessorProperty?: (
node: TSESTree.AccessorProperty & ASTNodeWithParent,
) => void
ArrayExpression?: (node: TSESTree.ArrayExpression & ASTNodeWithParent) => void
ArrayPattern?: (node: TSESTree.ArrayPattern & ASTNodeWithParent) => void
ArrowFunctionExpression?: (
Expand Down Expand Up @@ -540,6 +552,9 @@ export type TSNodeListener = {
Decorator?: (node: TSESTree.Decorator & ASTNodeWithParent) => void
ImportAttribute?: (node: TSESTree.ImportAttribute & ASTNodeWithParent) => void
StaticBlock?: (node: TSESTree.StaticBlock & ASTNodeWithParent) => void
TSAbstractAccessorProperty?: (
node: TSESTree.TSAbstractAccessorProperty & ASTNodeWithParent,
) => void
TSAbstractKeyword?: (
node: TSESTree.TSAbstractKeyword & ASTNodeWithParent,
) => void
Expand Down Expand Up @@ -663,6 +678,9 @@ export type TSNodeListener = {
node: TSESTree.TSReadonlyKeyword & ASTNodeWithParent,
) => void
TSRestType?: (node: TSESTree.TSRestType & ASTNodeWithParent) => void
TSSatisfiesExpression?: (
node: TSESTree.TSSatisfiesExpression & ASTNodeWithParent,
) => void
TSStaticKeyword?: (node: TSESTree.TSStaticKeyword & ASTNodeWithParent) => void
TSStringKeyword?: (node: TSESTree.TSStringKeyword & ASTNodeWithParent) => void
TSSymbolKeyword?: (node: TSESTree.TSSymbolKeyword & ASTNodeWithParent) => void
Expand Down
1 change: 1 addition & 0 deletions typings/estree/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ export type Node = TSESTree.Node
export type Expression = TSESTree.Expression
export type Statement = TSESTree.Statement
export type Pattern = TSESTree.Pattern
export type AccessorProperty = TSESTree.AccessorProperty
export type ArrayExpression = TSESTree.ArrayExpression
export type ArrayPattern = TSESTree.ArrayPattern
export type ArrowFunctionExpression = TSESTree.ArrowFunctionExpression
Expand Down