Showing 8,855 of 8,855 total issues
Identifier 'item' is never reassigned; use 'const' instead of 'let'. Open
let item = {name: itemName, rarity: selectedValue, mediaId: fileId};
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: prefer-const
Requires that variable declarations use const
instead of let
and var
if possible.
If a variable is only assigned to once when it is declared, it should be declared using 'const'
Notes
- Has Fix
Config
An optional object containing the property "destructuring" with two possible values:
- "any" (default) - If any variable in destructuring can be const, this rule warns for those variables.
- "all" - Only warns if all variables in destructuring can be const.
Examples
"prefer-const": true
"prefer-const": true,[object Object]
Schema
{
"type": "object",
"properties": {
"destructuring": {
"type": "string",
"enum": [
"all",
"any"
]
}
}
}
For more information see this page.
" should be ' Open
alt="logo"
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: quotemark
Enforces quote character for string literals.
Notes
- Has Fix
Config
Five arguments may be optionally provided:
-
"single"
enforces single quotes. -
"double"
enforces double quotes. -
"backtick"
enforces backticks. -
"jsx-single"
enforces single quotes for JSX attributes. -
"jsx-double"
enforces double quotes for JSX attributes. -
"avoid-template"
forbids single-line untagged template strings that do not contain string interpolations. Note that backticks may still be used if"avoid-escape"
is enabled and both single and double quotes are present in the string (the latter option takes precedence). -
"avoid-escape"
allows you to use the "other" quotemark in cases where escaping would normally be required. For example,[true, "double", "avoid-escape"]
would not report a failure on the string literal'Hello "World"'
.
Examples
"quotemark": true,single,avoid-escape,avoid-template
"quotemark": true,single,jsx-double
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"single",
"double",
"backtick",
"jsx-single",
"jsx-double",
"avoid-escape",
"avoid-template"
]
},
"minLength": 0,
"maxLength": 5
}
For more information see this page.
" should be ' Open
placeholder="Item Name"
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: quotemark
Enforces quote character for string literals.
Notes
- Has Fix
Config
Five arguments may be optionally provided:
-
"single"
enforces single quotes. -
"double"
enforces double quotes. -
"backtick"
enforces backticks. -
"jsx-single"
enforces single quotes for JSX attributes. -
"jsx-double"
enforces double quotes for JSX attributes. -
"avoid-template"
forbids single-line untagged template strings that do not contain string interpolations. Note that backticks may still be used if"avoid-escape"
is enabled and both single and double quotes are present in the string (the latter option takes precedence). -
"avoid-escape"
allows you to use the "other" quotemark in cases where escaping would normally be required. For example,[true, "double", "avoid-escape"]
would not report a failure on the string literal'Hello "World"'
.
Examples
"quotemark": true,single,avoid-escape,avoid-template
"quotemark": true,single,jsx-double
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"single",
"double",
"backtick",
"jsx-single",
"jsx-double",
"avoid-escape",
"avoid-template"
]
},
"minLength": 0,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//Mobx store for api
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
Class name must be in pascal case Open
interface longTapUserProps {
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: class-name
Enforces PascalCased class and interface names.
Rationale
Makes it easy to differentiate classes from regular variables at a glance.
JavaScript and general programming convention is to refer to classes in PascalCase. It's confusing to use camelCase or other conventions for class names.
Config
Not configurable.
Examples
"class-name": true
For more information see this page.
comment must start with a space Open
//set roles associated to the provided room in store
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//delete from Mobx store
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//set room image success response
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
Unnecessary semicolon Open
};
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: semicolon
Enforces consistent semicolon usage at the end of every statement.
Notes
- Has Fix
Config
One of the following arguments must be provided:
-
"always"
enforces semicolons at the end of every statement. -
"never"
disallows semicolons at the end of every statement except for when they are necessary.
The following arguments may be optionally provided:
-
"ignore-interfaces"
skips checking semicolons at the end of interface members. -
"ignore-bound-class-methods"
skips checking semicolons at the end of bound class methods. -
"strict-bound-class-methods"
disables any special handling of bound class methods and treats them as any other assignment. This option overrides"ignore-bound-class-methods"
.
Examples
"semicolon": true,always
"semicolon": true,never
"semicolon": true,always,ignore-interfaces
"semicolon": true,always,ignore-bound-class-methods
Schema
{
"type": "array",
"items": [
{
"type": "string",
"enum": [
"always",
"never"
]
},
{
"type": "string",
"enum": [
"ignore-interfaces"
]
}
],
"additionalItems": false
}
For more information see this page.
comment must start with a space Open
//login user handler
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//handle to register a new user using external wallet
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//will call updateInitialData which will store the updated data in async store and then in mobx store.
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.
Identifier 'isAssetsOpen' is never reassigned; use 'const' instead of 'let'. Open
isAssetsOpen,
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: prefer-const
Requires that variable declarations use const
instead of let
and var
if possible.
If a variable is only assigned to once when it is declared, it should be declared using 'const'
Notes
- Has Fix
Config
An optional object containing the property "destructuring" with two possible values:
- "any" (default) - If any variable in destructuring can be const, this rule warns for those variables.
- "all" - Only warns if all variables in destructuring can be const.
Examples
"prefer-const": true
"prefer-const": true,[object Object]
Schema
{
"type": "object",
"properties": {
"destructuring": {
"type": "string",
"enum": [
"all",
"any"
]
}
}
}
For more information see this page.
" should be ' Open
<FontAwesome name="send" size={15} color="black" />
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: quotemark
Enforces quote character for string literals.
Notes
- Has Fix
Config
Five arguments may be optionally provided:
-
"single"
enforces single quotes. -
"double"
enforces double quotes. -
"backtick"
enforces backticks. -
"jsx-single"
enforces single quotes for JSX attributes. -
"jsx-double"
enforces double quotes for JSX attributes. -
"avoid-template"
forbids single-line untagged template strings that do not contain string interpolations. Note that backticks may still be used if"avoid-escape"
is enabled and both single and double quotes are present in the string (the latter option takes precedence). -
"avoid-escape"
allows you to use the "other" quotemark in cases where escaping would normally be required. For example,[true, "double", "avoid-escape"]
would not report a failure on the string literal'Hello "World"'
.
Examples
"quotemark": true,single,avoid-escape,avoid-template
"quotemark": true,single,jsx-double
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"single",
"double",
"backtick",
"jsx-single",
"jsx-double",
"avoid-escape",
"avoid-template"
]
},
"minLength": 0,
"maxLength": 5
}
For more information see this page.
Unnecessary semicolon Open
};
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: semicolon
Enforces consistent semicolon usage at the end of every statement.
Notes
- Has Fix
Config
One of the following arguments must be provided:
-
"always"
enforces semicolons at the end of every statement. -
"never"
disallows semicolons at the end of every statement except for when they are necessary.
The following arguments may be optionally provided:
-
"ignore-interfaces"
skips checking semicolons at the end of interface members. -
"ignore-bound-class-methods"
skips checking semicolons at the end of bound class methods. -
"strict-bound-class-methods"
disables any special handling of bound class methods and treats them as any other assignment. This option overrides"ignore-bound-class-methods"
.
Examples
"semicolon": true,always
"semicolon": true,never
"semicolon": true,always,ignore-interfaces
"semicolon": true,always,ignore-bound-class-methods
Schema
{
"type": "array",
"items": [
{
"type": "string",
"enum": [
"always",
"never"
]
},
{
"type": "string",
"enum": [
"ignore-interfaces"
]
}
],
"additionalItems": false
}
For more information see this page.
Expected property shorthand in object literal ('{userWalletAddress}'). Open
userWalletAddress: userWalletAddress,
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: object-literal-shorthand
Enforces/disallows use of ES6 object literal shorthand.
Notes
- Has Fix
Config
"always"
assumed to be default option, thus with no options provided
the rule enforces object literal methods and properties shorthands.
With "never"
option provided, any shorthand object literal syntax causes an error.
The rule can be configured in a more granular way.
With {"property": "never"}
provided (which is equivalent to {"property": "never", "method": "always"}
),
the rule only flags property shorthand assignments,
and respectively with {"method": "never"}
(equivalent to {"property": "always", "method": "never"}
),
the rule fails only on method shorthands.
Examples
"object-literal-shorthand": true
"object-literal-shorthand": true,never
"object-literal-shorthand": true,[object Object]
Schema
{
"oneOf": [
{
"type": "string",
"enum": [
"never"
]
},
{
"type": "object",
"properties": {
"property": {
"type": "string",
"enum": [
"never"
]
},
"method": {
"type": "string",
"enum": [
"never"
]
}
},
"minProperties": 1,
"maxProperties": 2
}
]
}
For more information see this page.
unused expression, expected an assignment or function call Open
total && total < rareTotal && traits.push('Rare');
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: no-unused-expression
Disallows unused expression statements.
Unused expressions are expression statements which are not assignments or function calls (and thus usually no-ops).
Rationale
Detects potential errors where an assignment or function call was intended.
Config
Three arguments may be optionally provided:
-
allow-fast-null-checks
allows to use logical operators to perform fast null checks and perform method or function calls for side effects (e.g.e && e.preventDefault()
). -
allow-new
allows 'new' expressions for side effects (e.g.new ModifyGlobalState();
. -
allow-tagged-template
allows tagged templates for side effects (e.g.this.add\
foo`;`.
Examples
"no-unused-expression": true
"no-unused-expression": true,allow-fast-null-checks
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"allow-fast-null-checks",
"allow-new",
"allow-tagged-template"
]
},
"minLength": 0,
"maxLength": 3
}
For more information see this page.
" should be ' Open
flexDirection="row"
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: quotemark
Enforces quote character for string literals.
Notes
- Has Fix
Config
Five arguments may be optionally provided:
-
"single"
enforces single quotes. -
"double"
enforces double quotes. -
"backtick"
enforces backticks. -
"jsx-single"
enforces single quotes for JSX attributes. -
"jsx-double"
enforces double quotes for JSX attributes. -
"avoid-template"
forbids single-line untagged template strings that do not contain string interpolations. Note that backticks may still be used if"avoid-escape"
is enabled and both single and double quotes are present in the string (the latter option takes precedence). -
"avoid-escape"
allows you to use the "other" quotemark in cases where escaping would normally be required. For example,[true, "double", "avoid-escape"]
would not report a failure on the string literal'Hello "World"'
.
Examples
"quotemark": true,single,avoid-escape,avoid-template
"quotemark": true,single,jsx-double
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"single",
"double",
"backtick",
"jsx-single",
"jsx-double",
"avoid-escape",
"avoid-template"
]
},
"minLength": 0,
"maxLength": 5
}
For more information see this page.
" should be ' Open
<Ionicons size={hp('2%')} color={'#fff'} name="share-social" />
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: quotemark
Enforces quote character for string literals.
Notes
- Has Fix
Config
Five arguments may be optionally provided:
-
"single"
enforces single quotes. -
"double"
enforces double quotes. -
"backtick"
enforces backticks. -
"jsx-single"
enforces single quotes for JSX attributes. -
"jsx-double"
enforces double quotes for JSX attributes. -
"avoid-template"
forbids single-line untagged template strings that do not contain string interpolations. Note that backticks may still be used if"avoid-escape"
is enabled and both single and double quotes are present in the string (the latter option takes precedence). -
"avoid-escape"
allows you to use the "other" quotemark in cases where escaping would normally be required. For example,[true, "double", "avoid-escape"]
would not report a failure on the string literal'Hello "World"'
.
Examples
"quotemark": true,single,avoid-escape,avoid-template
"quotemark": true,single,jsx-double
Schema
{
"type": "array",
"items": {
"type": "string",
"enum": [
"single",
"double",
"backtick",
"jsx-single",
"jsx-double",
"avoid-escape",
"avoid-template"
]
},
"minLength": 0,
"maxLength": 5
}
For more information see this page.
comment must start with a space Open
//handle to remove mainnet address
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
Rule: comment-format
Enforces formatting rules for single-line comments.
Rationale
Helps maintain a consistent, readable style in your codebase.
Notes
- Has Fix
Config
Four arguments may be optionally provided:
-
"check-space"
requires that all single-line comments must begin with a space, as in// comment
- note that for comments starting with multiple slashes, e.g.
///
, leading slashes are ignored - TypeScript reference comments are ignored completely
- note that for comments starting with multiple slashes, e.g.
-
"check-lowercase"
requires that the first non-whitespace character of a comment must be lowercase, if applicable. -
"check-uppercase"
requires that the first non-whitespace character of a comment must be uppercase, if applicable. -
"allow-trailing-lowercase"
allows that only the first comment of a series of comments needs to be uppercase.- requires
"check-uppercase"
- comments must start at the same position
- requires
Exceptions to "check-lowercase"
or "check-uppercase"
can be managed with object that may be passed as last
argument.
One of two options can be provided in this object:
-
"ignore-words"
- array of strings - words that will be ignored at the beginning of the comment. -
"ignore-pattern"
- string - RegExp pattern that will be ignored at the beginning of the comment.
Examples
"comment-format": true,check-space,check-uppercase,allow-trailing-lowercase
"comment-format": true,check-lowercase,[object Object]
"comment-format": true,check-lowercase,[object Object]
Schema
{
"type": "array",
"items": {
"anyOf": [
{
"type": "string",
"enum": [
"check-space",
"check-lowercase",
"check-uppercase",
"allow-trailing-lowercase"
]
},
{
"type": "object",
"properties": {
"ignore-words": {
"type": "array",
"items": {
"type": "string"
}
},
"ignore-pattern": {
"type": "string"
}
},
"minProperties": 1,
"maxProperties": 1
}
]
},
"minLength": 1,
"maxLength": 5
}
For more information see this page.