javascript.biomeConfig
Submodule
Protocols
IA11y
- Implemented By: projen.javascript.biomeConfig.IA11y
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that the accessKey attribute is not used on any HTML element. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that aria-hidden="true" is not set on focusable elements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that elements that do not support ARIA roles, states, and properties do not have those attributes. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that autoFocus prop is not used on elements. |
| string | projen.javascript.biomeConfig.IRuleWithAllowDomainOptions | Disallow target="_blank" attribute without rel="noreferrer". |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforces that no distracting elements are used. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | The scope prop should be used only on <th> elements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that non-interactive ARIA roles are not assigned to interactive HTML elements. |
| string | projen.javascript.biomeConfig.IRuleWithNoLabelWithoutControlOptions | Enforce that a label element or component has a text label and an associated input. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that interactive ARIA roles are not assigned to non-interactive HTML elements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that tabIndex is not assigned to non-interactive HTML elements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevent the usage of positive integers on tabIndex property. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce img alt prop does not contain the word "image", "picture", or "photo". |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce explicit role property is not the same as implicit/default role property on an element. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforces the usage of the title element for the svg element. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that all elements that require alternative text have meaningful information to relay back to the end user. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that anchors have content and that the content is accessible to screen readers. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce that tabIndex is assigned to non-interactive HTML elements with aria-activedescendant. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that elements with ARIA roles must have all required ARIA attributes for that role. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforces the usage of the attribute type for the element button. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Elements with an interactive role and interaction handlers must be focusable. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow a missing generic family keyword within font families. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that heading elements (h1, h2, etc.) have content and that the content is accessible to screen readers. Accessible means that it is not hidden using the aria-hidden prop. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that html element has lang attribute. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforces the usage of the attribute title for the element iframe. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce onClick is accompanied by at least one of the following: onKeyUp, onKeyDown, onKeyPress. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce onMouseOver / onMouseOut are accompanied by onFocus / onBlur. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforces that audio and video elements must have a track for captions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | It detects the use of role attributes in JSX elements and suggests using semantic elements instead. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that all anchors are valid, and they are navigable elements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Ensures that ARIA properties aria-* are all valid. |
| string | projen.javascript.biomeConfig.IRuleWithValidAriaRoleOptions | Elements with ARIA roles must use a valid, non-abstract ARIA role. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that ARIA state and property values are valid. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Ensure that the attribute passed to the lang attribute is a correct ISO language and/or country. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noAccessKey
Optional
public readonly noAccessKey: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that the accessKey attribute is not used on any HTML element.
noAriaHiddenOnFocusable
Optional
public readonly noAriaHiddenOnFocusable: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that aria-hidden="true" is not set on focusable elements.
noAriaUnsupportedElements
Optional
public readonly noAriaUnsupportedElements: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that elements that do not support ARIA roles, states, and properties do not have those attributes.
noAutofocus
Optional
public readonly noAutofocus: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that autoFocus prop is not used on elements.
noBlankTarget
Optional
public readonly noBlankTarget: string | IRuleWithAllowDomainOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithAllowDomainOptions
Disallow target="_blank" attribute without rel="noreferrer".
noDistractingElements
Optional
public readonly noDistractingElements: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforces that no distracting elements are used.
noHeaderScope
Optional
public readonly noHeaderScope: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
The scope prop should be used only on <th> elements.
noInteractiveElementToNoninteractiveRole
Optional
public readonly noInteractiveElementToNoninteractiveRole: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that non-interactive ARIA roles are not assigned to interactive HTML elements.
noLabelWithoutControl
Optional
public readonly noLabelWithoutControl: string | IRuleWithNoLabelWithoutControlOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoLabelWithoutControlOptions
Enforce that a label element or component has a text label and an associated input.
noNoninteractiveElementToInteractiveRole
Optional
public readonly noNoninteractiveElementToInteractiveRole: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that interactive ARIA roles are not assigned to non-interactive HTML elements.
noNoninteractiveTabindex
Optional
public readonly noNoninteractiveTabindex: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that tabIndex is not assigned to non-interactive HTML elements.
noPositiveTabindex
Optional
public readonly noPositiveTabindex: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevent the usage of positive integers on tabIndex property.
noRedundantAlt
Optional
public readonly noRedundantAlt: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce img alt prop does not contain the word "image", "picture", or "photo".
noRedundantRoles
Optional
public readonly noRedundantRoles: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce explicit role property is not the same as implicit/default role property on an element.
noSvgWithoutTitle
Optional
public readonly noSvgWithoutTitle: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforces the usage of the title element for the svg element.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useAltText
Optional
public readonly useAltText: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that all elements that require alternative text have meaningful information to relay back to the end user.
useAnchorContent
Optional
public readonly useAnchorContent: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that anchors have content and that the content is accessible to screen readers.
useAriaActivedescendantWithTabindex
Optional
public readonly useAriaActivedescendantWithTabindex: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce that tabIndex is assigned to non-interactive HTML elements with aria-activedescendant.
useAriaPropsForRole
Optional
public readonly useAriaPropsForRole: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that elements with ARIA roles must have all required ARIA attributes for that role.
useButtonType
Optional
public readonly useButtonType: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforces the usage of the attribute type for the element button.
useFocusableInteractive
Optional
public readonly useFocusableInteractive: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Elements with an interactive role and interaction handlers must be focusable.
useGenericFontNames
Optional
public readonly useGenericFontNames: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow a missing generic family keyword within font families.
useHeadingContent
Optional
public readonly useHeadingContent: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that heading elements (h1, h2, etc.) have content and that the content is accessible to screen readers. Accessible means that it is not hidden using the aria-hidden prop.
useHtmlLang
Optional
public readonly useHtmlLang: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that html element has lang attribute.
useIframeTitle
Optional
public readonly useIframeTitle: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforces the usage of the attribute title for the element iframe.
useKeyWithClickEvents
Optional
public readonly useKeyWithClickEvents: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce onClick is accompanied by at least one of the following: onKeyUp, onKeyDown, onKeyPress.
useKeyWithMouseEvents
Optional
public readonly useKeyWithMouseEvents: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce onMouseOver / onMouseOut are accompanied by onFocus / onBlur.
useMediaCaption
Optional
public readonly useMediaCaption: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforces that audio and video elements must have a track for captions.
useSemanticElements
Optional
public readonly useSemanticElements: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
It detects the use of role attributes in JSX elements and suggests using semantic elements instead.
useValidAnchor
Optional
public readonly useValidAnchor: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that all anchors are valid, and they are navigable elements.
useValidAriaProps
Optional
public readonly useValidAriaProps: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Ensures that ARIA properties aria-* are all valid.
useValidAriaRole
Optional
public readonly useValidAriaRole: string | IRuleWithValidAriaRoleOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithValidAriaRoleOptions
Elements with ARIA roles must use a valid, non-abstract ARIA role.
useValidAriaValues
Optional
public readonly useValidAriaValues: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that ARIA state and property values are valid.
useValidLang
Optional
public readonly useValidLang: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Ensure that the attribute passed to the lang attribute is a correct ISO language and/or country.
IActions
- Implemented By: projen.javascript.biomeConfig.IActions
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.ISource | No description. |
source
Optional
public readonly source: ISource;
- Type: projen.javascript.biomeConfig.ISource
IAllowDomainOptions
- Implemented By: projen.javascript.biomeConfig.IAllowDomainOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | List of domains to allow target="_blank" without rel="noreferrer" . |
allowDomains
Optional
public readonly allowDomains: string[];
- Type: string[]
List of domains to allow target="_blank"
without rel="noreferrer"
.
IAssistsConfiguration
- Implemented By: projen.javascript.biomeConfig.IAssistsConfiguration
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IActions | Whether Biome should fail in CLI if the assists were not applied to the code. |
| boolean | Whether Biome should enable assists via LSP. |
| string[] | A list of Unix shell style patterns. |
| string[] | A list of Unix shell style patterns. |
actions
Optional
public readonly actions: IActions;
- Type: projen.javascript.biomeConfig.IActions
Whether Biome should fail in CLI if the assists were not applied to the code.
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Whether Biome should enable assists via LSP.
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will ignore files/folders that will match these patterns.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will include files/folders that will match these patterns.
IComplexity
- Implemented By: projen.javascript.biomeConfig.IComplexity
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow primitive type aliases and misleading types. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow empty type parameters in type aliases and interfaces. |
| string | projen.javascript.biomeConfig.IRuleWithComplexityOptions | Disallow functions that exceed a given Cognitive Complexity score. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | This rule enforces a maximum depth to nested describe() in test files. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary boolean casts. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prefer for...of statement instead of Array.forEach. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unclear usage of consecutive space characters in regular expression literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | This rule reports when a class has no non-static members, such as for a class used exclusively as a static namespace. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow this and super in static contexts. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary catch clauses. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary constructors. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow empty exports that don't change anything in a module file. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary fragments. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary labels. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary nested block statements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow renaming import, export, and destructured assignments to the same name. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary concatenation of string or template literals. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow useless case in switch statements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow ternary operators when simpler alternatives exist. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow useless this aliasing. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow using any or unknown as type constraint. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow initializing variables to undefined. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of void operators, which is not a familiar operator. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow with statements in non-strict contexts. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use arrow functions over function expressions. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use Date.now() to get the number of milliseconds since the Unix Epoch. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Promotes the use of .flatMap() when map().flat() are used together. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the usage of a literal access to properties over computed property access. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce using concise optional chain instead of chained logical expressions. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of the regular expression literals instead of the RegExp constructor if possible. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow number literal object member names which are not base10 or uses underscore as separator. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Discard redundant terms from logical expressions. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noBannedTypes
Optional
public readonly noBannedTypes: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow primitive type aliases and misleading types.
noEmptyTypeParameters
Optional
public readonly noEmptyTypeParameters: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow empty type parameters in type aliases and interfaces.
noExcessiveCognitiveComplexity
Optional
public readonly noExcessiveCognitiveComplexity: string | IRuleWithComplexityOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithComplexityOptions
Disallow functions that exceed a given Cognitive Complexity score.
noExcessiveNestedTestSuites
Optional
public readonly noExcessiveNestedTestSuites: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
This rule enforces a maximum depth to nested describe() in test files.
noExtraBooleanCast
Optional
public readonly noExtraBooleanCast: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary boolean casts.
noForEach
Optional
public readonly noForEach: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prefer for...of statement instead of Array.forEach.
noMultipleSpacesInRegularExpressionLiterals
Optional
public readonly noMultipleSpacesInRegularExpressionLiterals: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unclear usage of consecutive space characters in regular expression literals.
noStaticOnlyClass
Optional
public readonly noStaticOnlyClass: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
This rule reports when a class has no non-static members, such as for a class used exclusively as a static namespace.
noThisInStatic
Optional
public readonly noThisInStatic: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow this and super in static contexts.
noUselessCatch
Optional
public readonly noUselessCatch: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary catch clauses.
noUselessConstructor
Optional
public readonly noUselessConstructor: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary constructors.
noUselessEmptyExport
Optional
public readonly noUselessEmptyExport: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow empty exports that don't change anything in a module file.
noUselessFragments
Optional
public readonly noUselessFragments: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary fragments.
noUselessLabel
Optional
public readonly noUselessLabel: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary labels.
noUselessLoneBlockStatements
Optional
public readonly noUselessLoneBlockStatements: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary nested block statements.
noUselessRename
Optional
public readonly noUselessRename: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow renaming import, export, and destructured assignments to the same name.
noUselessStringConcat
Optional
public readonly noUselessStringConcat: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary concatenation of string or template literals.
noUselessSwitchCase
Optional
public readonly noUselessSwitchCase: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow useless case in switch statements.
noUselessTernary
Optional
public readonly noUselessTernary: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow ternary operators when simpler alternatives exist.
noUselessThisAlias
Optional
public readonly noUselessThisAlias: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow useless this aliasing.
noUselessTypeConstraint
Optional
public readonly noUselessTypeConstraint: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow using any or unknown as type constraint.
noUselessUndefinedInitialization
Optional
public readonly noUselessUndefinedInitialization: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow initializing variables to undefined.
noVoid
Optional
public readonly noVoid: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of void operators, which is not a familiar operator.
noWith
Optional
public readonly noWith: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow with statements in non-strict contexts.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useArrowFunction
Optional
public readonly useArrowFunction: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use arrow functions over function expressions.
useDateNow
Optional
public readonly useDateNow: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use Date.now() to get the number of milliseconds since the Unix Epoch.
useFlatMap
Optional
public readonly useFlatMap: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Promotes the use of .flatMap() when map().flat() are used together.
useLiteralKeys
Optional
public readonly useLiteralKeys: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the usage of a literal access to properties over computed property access.
useOptionalChain
Optional
public readonly useOptionalChain: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce using concise optional chain instead of chained logical expressions.
useRegexLiterals
Optional
public readonly useRegexLiterals: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of the regular expression literals instead of the RegExp constructor if possible.
useSimpleNumberKeys
Optional
public readonly useSimpleNumberKeys: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow number literal object member names which are not base10 or uses underscore as separator.
useSimplifiedLogicExpression
Optional
public readonly useSimplifiedLogicExpression: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Discard redundant terms from logical expressions.
IComplexityOptions
- Implemented By: projen.javascript.biomeConfig.IComplexityOptions
Options for the rule noExcessiveCognitiveComplexity
.
Properties
Name | Type | Description |
---|---|---|
| number | The maximum complexity score that we allow. |
maxAllowedComplexity
Optional
public readonly maxAllowedComplexity: number;
- Type: number
The maximum complexity score that we allow.
Anything higher is considered excessive.
IConfiguration
- Implemented By: projen.javascript.biomeConfig.IConfiguration
The configuration that is contained inside the file biome.json
.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IAssistsConfiguration | Specific configuration for assists. |
| projen.javascript.biomeConfig.ICssConfiguration | Specific configuration for the Css language. |
| string[] | A list of paths to other JSON files, used to extends the current configuration. |
| projen.javascript.biomeConfig.IFilesConfiguration | The configuration of the filesystem. |
| projen.javascript.biomeConfig.IFormatterConfiguration | The configuration of the formatter. |
| projen.javascript.biomeConfig.IGraphqlConfiguration | Specific configuration for the GraphQL language. |
| projen.javascript.biomeConfig.IJavascriptConfiguration | Specific configuration for the JavaScript language. |
| projen.javascript.biomeConfig.IJsonConfiguration | Specific configuration for the Json language. |
| projen.javascript.biomeConfig.ILinterConfiguration | The configuration for the linter. |
| projen.javascript.biomeConfig.IOrganizeImports | The configuration of the import sorting. |
| projen.javascript.biomeConfig.IOverridePattern[] | A list of granular patterns that should be applied only to a sub set of files. |
| projen.javascript.biomeConfig.IVcsConfiguration | The configuration of the VCS integration. |
assists
Optional
public readonly assists: IAssistsConfiguration;
- Type: projen.javascript.biomeConfig.IAssistsConfiguration
Specific configuration for assists.
css
Optional
public readonly css: ICssConfiguration;
- Type: projen.javascript.biomeConfig.ICssConfiguration
Specific configuration for the Css language.
extends
Optional
public readonly extends: string[];
- Type: string[]
A list of paths to other JSON files, used to extends the current configuration.
files
Optional
public readonly files: IFilesConfiguration;
- Type: projen.javascript.biomeConfig.IFilesConfiguration
The configuration of the filesystem.
formatter
Optional
public readonly formatter: IFormatterConfiguration;
- Type: projen.javascript.biomeConfig.IFormatterConfiguration
The configuration of the formatter.
graphql
Optional
public readonly graphql: IGraphqlConfiguration;
- Type: projen.javascript.biomeConfig.IGraphqlConfiguration
Specific configuration for the GraphQL language.
javascript
Optional
public readonly javascript: IJavascriptConfiguration;
- Type: projen.javascript.biomeConfig.IJavascriptConfiguration
Specific configuration for the JavaScript language.
json
Optional
public readonly json: IJsonConfiguration;
- Type: projen.javascript.biomeConfig.IJsonConfiguration
Specific configuration for the Json language.
linter
Optional
public readonly linter: ILinterConfiguration;
- Type: projen.javascript.biomeConfig.ILinterConfiguration
The configuration for the linter.
organizeImports
Optional
public readonly organizeImports: IOrganizeImports;
- Type: projen.javascript.biomeConfig.IOrganizeImports
The configuration of the import sorting.
overrides
Optional
public readonly overrides: IOverridePattern[];
- Type: projen.javascript.biomeConfig.IOverridePattern[]
A list of granular patterns that should be applied only to a sub set of files.
vcs
Optional
public readonly vcs: IVcsConfiguration;
- Type: projen.javascript.biomeConfig.IVcsConfiguration
The configuration of the VCS integration.
IConsistentArrayTypeOptions
- Implemented By: projen.javascript.biomeConfig.IConsistentArrayTypeOptions
Properties
Name | Type | Description |
---|---|---|
| string | No description. |
syntax
Optional
public readonly syntax: string;
- Type: string
IConsistentMemberAccessibilityOptions
- Implemented By: projen.javascript.biomeConfig.IConsistentMemberAccessibilityOptions
Properties
Name | Type | Description |
---|---|---|
| string | No description. |
accessibility
Optional
public readonly accessibility: string;
- Type: string
IConvention
- Implemented By: projen.javascript.biomeConfig.IConvention
Properties
Name | Type | Description |
---|---|---|
| string[] | String cases to enforce. |
| string | Regular expression to enforce. |
| projen.javascript.biomeConfig.ISelector | Declarations concerned by this convention. |
formats
Optional
public readonly formats: string[];
- Type: string[]
String cases to enforce.
match
Optional
public readonly match: string;
- Type: string
Regular expression to enforce.
selector
Optional
public readonly selector: ISelector;
- Type: projen.javascript.biomeConfig.ISelector
Declarations concerned by this convention.
ICorrectness
- Implemented By: projen.javascript.biomeConfig.ICorrectness
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent passing of children as props. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow constant expressions in conditions. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of Math.min and Math.max to clamp a value where the result itself is constant. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevents from having const variables being re-assigned. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow returning a value from a constructor. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow empty character classes in regular expression literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallows empty destructuring patterns. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow to use unnecessary callback on flatMap. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow calling global object properties as functions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow function and var declarations that are accessible outside their block. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Ensure that builtins are correctly instantiated. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevents the incorrect use of super() inside classes. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow non-standard direction values for linear gradient functions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallows invalid named grid areas in CSS Grid Layouts. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow new operators with global non-constructor functions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of variables and function parameters before their declaration. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow new operators with the Symbol object. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Forbid the use of Node.js builtin modules. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow \8 and \9 escape sequences in string literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow literal numbers that lose precision. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent the usage of the return value of React.render. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow assignments where both sides are exactly the same. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow returning a value from a setter. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow comparison of expressions modifying the string case with non-compliant value. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow lexical declarations in switch clauses. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of dependencies that aren't specified in the package.json. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevents the usage of variables that haven't been declared inside the document. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown CSS value functions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown media feature names. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown properties. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown CSS units. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unmatchable An+B selectors. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Avoid using unnecessary continue. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unreachable code. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Ensures the super() constructor is called exactly once on every code path in a class constructor before this is accessed if the class has a superclass. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow control flow statements in finally blocks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of optional chaining in contexts where the undefined value is not allowed. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unused function parameters. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unused imports. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unused labels. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unused private class members. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unused variables. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | This rules prevents void elements (AKA self-closing elements) from having children. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow returning a value from a function with the return type 'void'. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow Array constructors. |
| string | projen.javascript.biomeConfig.IRuleWithUseExhaustiveDependenciesOptions | Enforce all dependencies are correctly specified in a React hook. |
| string | projen.javascript.biomeConfig.IRuleWithDeprecatedHooksOptions | Enforce that all React hooks are being called from the Top Level component functions. |
| string | projen.javascript.biomeConfig.IRuleWithUseImportExtensionsOptions | Enforce file extensions for relative imports. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require calls to isNaN() when checking for NaN. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow missing key props in iterators/collection literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce "for" loop update clause moving the counter in the right direction. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require generator functions to contain yield. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noChildrenProp
Optional
public readonly noChildrenProp: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent passing of children as props.
noConstantCondition
Optional
public readonly noConstantCondition: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow constant expressions in conditions.
noConstantMathMinMaxClamp
Optional
public readonly noConstantMathMinMaxClamp: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of Math.min and Math.max to clamp a value where the result itself is constant.
noConstAssign
Optional
public readonly noConstAssign: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevents from having const variables being re-assigned.
noConstructorReturn
Optional
public readonly noConstructorReturn: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow returning a value from a constructor.
noEmptyCharacterClassInRegex
Optional
public readonly noEmptyCharacterClassInRegex: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow empty character classes in regular expression literals.
noEmptyPattern
Optional
public readonly noEmptyPattern: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallows empty destructuring patterns.
noFlatMapIdentity
Optional
public readonly noFlatMapIdentity: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow to use unnecessary callback on flatMap.
noGlobalObjectCalls
Optional
public readonly noGlobalObjectCalls: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow calling global object properties as functions.
noInnerDeclarations
Optional
public readonly noInnerDeclarations: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow function and var declarations that are accessible outside their block.
noInvalidBuiltinInstantiation
Optional
public readonly noInvalidBuiltinInstantiation: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Ensure that builtins are correctly instantiated.
noInvalidConstructorSuper
Optional
public readonly noInvalidConstructorSuper: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevents the incorrect use of super() inside classes.
It also checks whether a call super() is missing from classes that extends other constructors.
noInvalidDirectionInLinearGradient
Optional
public readonly noInvalidDirectionInLinearGradient: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow non-standard direction values for linear gradient functions.
noInvalidGridAreas
Optional
public readonly noInvalidGridAreas: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallows invalid named grid areas in CSS Grid Layouts.
noInvalidNewBuiltin
Optional
public readonly noInvalidNewBuiltin: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow new operators with global non-constructor functions.
noInvalidPositionAtImportRule
Optional
public readonly noInvalidPositionAtImportRule: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of.
noInvalidUseBeforeDeclaration
Optional
public readonly noInvalidUseBeforeDeclaration: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of variables and function parameters before their declaration.
noNewSymbol
Optional
public readonly noNewSymbol: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow new operators with the Symbol object.
noNodejsModules
Optional
public readonly noNodejsModules: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Forbid the use of Node.js builtin modules.
noNonoctalDecimalEscape
Optional
public readonly noNonoctalDecimalEscape: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow \8 and \9 escape sequences in string literals.
noPrecisionLoss
Optional
public readonly noPrecisionLoss: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow literal numbers that lose precision.
noRenderReturnValue
Optional
public readonly noRenderReturnValue: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent the usage of the return value of React.render.
noSelfAssign
Optional
public readonly noSelfAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow assignments where both sides are exactly the same.
noSetterReturn
Optional
public readonly noSetterReturn: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow returning a value from a setter.
noStringCaseMismatch
Optional
public readonly noStringCaseMismatch: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow comparison of expressions modifying the string case with non-compliant value.
noSwitchDeclarations
Optional
public readonly noSwitchDeclarations: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow lexical declarations in switch clauses.
noUndeclaredDependencies
Optional
public readonly noUndeclaredDependencies: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of dependencies that aren't specified in the package.json.
noUndeclaredVariables
Optional
public readonly noUndeclaredVariables: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevents the usage of variables that haven't been declared inside the document.
noUnknownFunction
Optional
public readonly noUnknownFunction: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown CSS value functions.
noUnknownMediaFeatureName
Optional
public readonly noUnknownMediaFeatureName: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown media feature names.
noUnknownProperty
Optional
public readonly noUnknownProperty: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown properties.
noUnknownUnit
Optional
public readonly noUnknownUnit: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown CSS units.
noUnmatchableAnbSelector
Optional
public readonly noUnmatchableAnbSelector: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unmatchable An+B selectors.
noUnnecessaryContinue
Optional
public readonly noUnnecessaryContinue: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Avoid using unnecessary continue.
noUnreachable
Optional
public readonly noUnreachable: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unreachable code.
noUnreachableSuper
Optional
public readonly noUnreachableSuper: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Ensures the super() constructor is called exactly once on every code path in a class constructor before this is accessed if the class has a superclass.
noUnsafeFinally
Optional
public readonly noUnsafeFinally: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow control flow statements in finally blocks.
noUnsafeOptionalChaining
Optional
public readonly noUnsafeOptionalChaining: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of optional chaining in contexts where the undefined value is not allowed.
noUnusedFunctionParameters
Optional
public readonly noUnusedFunctionParameters: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unused function parameters.
noUnusedImports
Optional
public readonly noUnusedImports: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unused imports.
noUnusedLabels
Optional
public readonly noUnusedLabels: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unused labels.
noUnusedPrivateClassMembers
Optional
public readonly noUnusedPrivateClassMembers: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unused private class members.
noUnusedVariables
Optional
public readonly noUnusedVariables: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unused variables.
noVoidElementsWithChildren
Optional
public readonly noVoidElementsWithChildren: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
This rules prevents void elements (AKA self-closing elements) from having children.
noVoidTypeReturn
Optional
public readonly noVoidTypeReturn: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow returning a value from a function with the return type 'void'.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useArrayLiterals
Optional
public readonly useArrayLiterals: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow Array constructors.
useExhaustiveDependencies
Optional
public readonly useExhaustiveDependencies: string | IRuleWithUseExhaustiveDependenciesOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithUseExhaustiveDependenciesOptions
Enforce all dependencies are correctly specified in a React hook.
useHookAtTopLevel
Optional
public readonly useHookAtTopLevel: string | IRuleWithDeprecatedHooksOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithDeprecatedHooksOptions
Enforce that all React hooks are being called from the Top Level component functions.
useImportExtensions
Optional
public readonly useImportExtensions: string | IRuleWithUseImportExtensionsOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithUseImportExtensionsOptions
Enforce file extensions for relative imports.
useIsNan
Optional
public readonly useIsNan: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require calls to isNaN() when checking for NaN.
useJsxKeyInIterable
Optional
public readonly useJsxKeyInIterable: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow missing key props in iterators/collection literals.
useValidForDirection
Optional
public readonly useValidForDirection: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce "for" loop update clause moving the counter in the right direction.
useYield
Optional
public readonly useYield: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require generator functions to contain yield.
ICssAssists
- Implemented By: projen.javascript.biomeConfig.ICssAssists
Options that changes how the CSS assists behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the assists for CSS files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the assists for CSS files.
ICssConfiguration
- Implemented By: projen.javascript.biomeConfig.ICssConfiguration
Options applied to CSS files.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.ICssAssists | CSS assists options. |
| projen.javascript.biomeConfig.ICssFormatter | CSS formatter options. |
| projen.javascript.biomeConfig.ICssLinter | CSS linter options. |
| projen.javascript.biomeConfig.ICssParser | CSS parsing options. |
assists
Optional
public readonly assists: ICssAssists;
- Type: projen.javascript.biomeConfig.ICssAssists
CSS assists options.
formatter
Optional
public readonly formatter: ICssFormatter;
- Type: projen.javascript.biomeConfig.ICssFormatter
CSS formatter options.
linter
Optional
public readonly linter: ICssLinter;
- Type: projen.javascript.biomeConfig.ICssLinter
CSS linter options.
parser
Optional
public readonly parser: ICssParser;
- Type: projen.javascript.biomeConfig.ICssParser
CSS parsing options.
ICssFormatter
- Implemented By: projen.javascript.biomeConfig.ICssFormatter
Options that changes how the CSS formatter behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the formatter for CSS (and its super languages) files. |
| string | The indent style applied to CSS (and its super languages) files. |
| number | The size of the indentation applied to CSS (and its super languages) files. |
| string | The type of line ending applied to CSS (and its super languages) files. |
| number | What's the max width of a line applied to CSS (and its super languages) files. |
| string | The type of quotes used in CSS code. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the formatter for CSS (and its super languages) files.
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style applied to CSS (and its super languages) files.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation applied to CSS (and its super languages) files.
Default to 2.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending applied to CSS (and its super languages) files.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line applied to CSS (and its super languages) files.
Defaults to 80.
quoteStyle
Optional
public readonly quoteStyle: string;
- Type: string
The type of quotes used in CSS code.
Defaults to double.
ICssLinter
- Implemented By: projen.javascript.biomeConfig.ICssLinter
Options that changes how the CSS linter behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the linter for CSS files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the linter for CSS files.
ICssParser
- Implemented By: projen.javascript.biomeConfig.ICssParser
Options that changes how the CSS parser behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Allow comments to appear on incorrect lines in .css files. |
| boolean | Enables parsing of CSS Modules specific features. |
allowWrongLineComments
Optional
public readonly allowWrongLineComments: boolean;
- Type: boolean
Allow comments to appear on incorrect lines in .css
files.
cssModules
Optional
public readonly cssModules: boolean;
- Type: boolean
Enables parsing of CSS Modules specific features.
ICustomRestrictedTypeOptions
- Implemented By: projen.javascript.biomeConfig.ICustomRestrictedTypeOptions
Properties
Name | Type | Description |
---|---|---|
| string | No description. |
| string | No description. |
message
Optional
public readonly message: string;
- Type: string
use
Optional
public readonly use: string;
- Type: string
IDeprecatedHooksOptions
- Implemented By: projen.javascript.biomeConfig.IDeprecatedHooksOptions
Options for the useHookAtTopLevel
rule have been deprecated, since we now use the React hook naming convention to determine whether a function is a hook.
IFilenamingConventionOptions
- Implemented By: projen.javascript.biomeConfig.IFilenamingConventionOptions
Rule's options.
Properties
Name | Type | Description |
---|---|---|
| string[] | Allowed cases for file names. |
| boolean | If false , then non-ASCII characters are allowed. |
| boolean | If false , then consecutive uppercase are allowed in camel and pascal cases. |
filenameCases
Optional
public readonly filenameCases: string[];
- Type: string[]
Allowed cases for file names.
requireAscii
Optional
public readonly requireAscii: boolean;
- Type: boolean
If false
, then non-ASCII characters are allowed.
strictCase
Optional
public readonly strictCase: boolean;
- Type: boolean
If false
, then consecutive uppercase are allowed in camel and pascal cases.
This does not affect other [Case].
IFilesConfiguration
- Implemented By: projen.javascript.biomeConfig.IFilesConfiguration
The configuration of the filesystem.
Properties
Name | Type | Description |
---|---|---|
| string[] | A list of Unix shell style patterns. |
| boolean | Tells Biome to not emit diagnostics when handling files that doesn't know. |
| string[] | A list of Unix shell style patterns. |
| number | The maximum allowed size for source code files in bytes. |
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
Biome will ignore files/folders that will match these patterns.
ignoreUnknown
Optional
public readonly ignoreUnknown: boolean;
- Type: boolean
Tells Biome to not emit diagnostics when handling files that doesn't know.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
Biome will handle only those files/folders that will match these patterns.
maxSize
Optional
public readonly maxSize: number;
- Type: number
The maximum allowed size for source code files in bytes.
Files above this limit will be ignored for performance reasons. Defaults to 1 MiB
IFormatterConfiguration
- Implemented By: projen.javascript.biomeConfig.IFormatterConfiguration
Generic options applied to all files.
Properties
Name | Type | Description |
---|---|---|
| string | The attribute position style in HTMLish languages. |
| boolean | Whether to insert spaces around brackets in object literals. |
| boolean | No description. |
| boolean | Stores whether formatting should be allowed to proceed if a given file has syntax errors. |
| string[] | A list of Unix shell style patterns. |
| string[] | A list of Unix shell style patterns. |
| number | The size of the indentation, 2 by default (deprecated, use indent-width ). |
| string | The indent style. |
| number | The size of the indentation, 2 by default. |
| string | The type of line ending. |
| number | What's the max width of a line. |
| boolean | Use any .editorconfig files to configure the formatter. Configuration in biome.json will override .editorconfig configuration. Default: false. |
attributePosition
Optional
public readonly attributePosition: string;
- Type: string
The attribute position style in HTMLish languages.
By default auto.
bracketSpacing
Optional
public readonly bracketSpacing: boolean;
- Type: boolean
Whether to insert spaces around brackets in object literals.
Defaults to true.
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
formatWithErrors
Optional
public readonly formatWithErrors: boolean;
- Type: boolean
Stores whether formatting should be allowed to proceed if a given file has syntax errors.
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will ignore files/folders that will match these patterns.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will include files/folders that will match these patterns.
indentSize
Optional
public readonly indentSize: number;
- Type: number
The size of the indentation, 2 by default (deprecated, use indent-width
).
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation, 2 by default.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line.
Defaults to 80.
useEditorconfig
Optional
public readonly useEditorconfig: boolean;
- Type: boolean
Use any .editorconfig
files to configure the formatter. Configuration in biome.json
will override .editorconfig
configuration. Default: false.
IGraphqlConfiguration
- Implemented By: projen.javascript.biomeConfig.IGraphqlConfiguration
Options applied to GraphQL files.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IGraphqlFormatter | GraphQL formatter options. |
| projen.javascript.biomeConfig.IGraphqlLinter | No description. |
formatter
Optional
public readonly formatter: IGraphqlFormatter;
- Type: projen.javascript.biomeConfig.IGraphqlFormatter
GraphQL formatter options.
linter
Optional
public readonly linter: IGraphqlLinter;
- Type: projen.javascript.biomeConfig.IGraphqlLinter
IGraphqlFormatter
- Implemented By: projen.javascript.biomeConfig.IGraphqlFormatter
Options that changes how the GraphQL formatter behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Whether to insert spaces around brackets in object literals. |
| boolean | Control the formatter for GraphQL files. |
| string | The indent style applied to GraphQL files. |
| number | The size of the indentation applied to GraphQL files. |
| string | The type of line ending applied to GraphQL files. |
| number | What's the max width of a line applied to GraphQL files. |
| string | The type of quotes used in GraphQL code. |
bracketSpacing
Optional
public readonly bracketSpacing: boolean;
- Type: boolean
Whether to insert spaces around brackets in object literals.
Defaults to true.
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the formatter for GraphQL files.
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style applied to GraphQL files.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation applied to GraphQL files.
Default to 2.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending applied to GraphQL files.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line applied to GraphQL files.
Defaults to 80.
quoteStyle
Optional
public readonly quoteStyle: string;
- Type: string
The type of quotes used in GraphQL code.
Defaults to double.
IGraphqlLinter
- Implemented By: projen.javascript.biomeConfig.IGraphqlLinter
Options that changes how the GraphQL linter behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the formatter for GraphQL files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the formatter for GraphQL files.
IHook
- Implemented By: projen.javascript.biomeConfig.IHook
Properties
Name | Type | Description |
---|---|---|
| number | The "position" of the closure function, starting from zero. |
| number | The "position" of the array of dependencies, starting from zero. |
| string | The name of the hook. |
| boolean | number[] | Whether the result of the hook is stable. |
closureIndex
Optional
public readonly closureIndex: number;
- Type: number
The "position" of the closure function, starting from zero.
For example, for React's useEffect()
hook, the closure index is 0.
dependenciesIndex
Optional
public readonly dependenciesIndex: number;
- Type: number
The "position" of the array of dependencies, starting from zero.
For example, for React's useEffect()
hook, the dependencies index is 1.
name
Optional
public readonly name: string;
- Type: string
The name of the hook.
stableResult
Optional
public readonly stableResult: boolean | number[];
- Type: boolean | number[]
Whether the result of the hook is stable.
Set to true
to mark the identity of the hook's return value as stable, or use a number/an array of numbers to mark the "positions" in the return array as stable.
For example, for React's useRef()
hook the value would be true
, while for useState()
it would be [1]
.
IJavascriptAssists
- Implemented By: projen.javascript.biomeConfig.IJavascriptAssists
Linter options specific to the JavaScript linter.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the linter for JavaScript (and its super languages) files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the linter for JavaScript (and its super languages) files.
IJavascriptConfiguration
- Implemented By: projen.javascript.biomeConfig.IJavascriptConfiguration
A set of options applied to the JavaScript files.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IJavascriptAssists | Assists options. |
| projen.javascript.biomeConfig.IJavascriptFormatter | Formatting options. |
| string[] | A list of global bindings that should be ignored by the analyzers. |
| string | Indicates the type of runtime or transformation used for interpreting JSX. |
| projen.javascript.biomeConfig.IJavascriptLinter | Linter options. |
| projen.javascript.biomeConfig.IJavascriptOrganizeImports | No description. |
| projen.javascript.biomeConfig.IJavascriptParser | Parsing options. |
assists
Optional
public readonly assists: IJavascriptAssists;
- Type: projen.javascript.biomeConfig.IJavascriptAssists
Assists options.
formatter
Optional
public readonly formatter: IJavascriptFormatter;
- Type: projen.javascript.biomeConfig.IJavascriptFormatter
Formatting options.
globals
Optional
public readonly globals: string[];
- Type: string[]
A list of global bindings that should be ignored by the analyzers.
If defined here, they should not emit diagnostics.
jsxRuntime
Optional
public readonly jsxRuntime: string;
- Type: string
Indicates the type of runtime or transformation used for interpreting JSX.
linter
Optional
public readonly linter: IJavascriptLinter;
- Type: projen.javascript.biomeConfig.IJavascriptLinter
Linter options.
organizeImports
Optional
public readonly organizeImports: IJavascriptOrganizeImports;
- Type: projen.javascript.biomeConfig.IJavascriptOrganizeImports
parser
Optional
public readonly parser: IJavascriptParser;
- Type: projen.javascript.biomeConfig.IJavascriptParser
Parsing options.
IJavascriptFormatter
- Implemented By: projen.javascript.biomeConfig.IJavascriptFormatter
Formatting options specific to the JavaScript files.
Properties
Name | Type | Description |
---|---|---|
| string | Whether to add non-necessary parentheses to arrow functions. |
| string | The attribute position style in jsx elements. |
| boolean | Whether to hug the closing bracket of multiline HTML/JSX tags to the end of the last line, rather than being alone on the following line. |
| boolean | Whether to insert spaces around brackets in object literals. |
| boolean | Control the formatter for JavaScript (and its super languages) files. |
| number | The size of the indentation applied to JavaScript (and its super languages) files. |
| string | The indent style applied to JavaScript (and its super languages) files. |
| number | The size of the indentation applied to JavaScript (and its super languages) files. |
| string | The type of quotes used in JSX. |
| string | The type of line ending applied to JavaScript (and its super languages) files. |
| number | What's the max width of a line applied to JavaScript (and its super languages) files. |
| string | When properties in objects are quoted. |
| string | The type of quotes used in JavaScript code. |
| string | Whether the formatter prints semicolons for all statements or only in for statements where it is necessary because of ASI. |
| string | Print trailing commas wherever possible in multi-line comma-separated syntactic structures. |
| string | Print trailing commas wherever possible in multi-line comma-separated syntactic structures. |
arrowParentheses
Optional
public readonly arrowParentheses: string;
- Type: string
Whether to add non-necessary parentheses to arrow functions.
Defaults to "always".
attributePosition
Optional
public readonly attributePosition: string;
- Type: string
The attribute position style in jsx elements.
Defaults to auto.
bracketSameLine
Optional
public readonly bracketSameLine: boolean;
- Type: boolean
Whether to hug the closing bracket of multiline HTML/JSX tags to the end of the last line, rather than being alone on the following line.
Defaults to false.
bracketSpacing
Optional
public readonly bracketSpacing: boolean;
- Type: boolean
Whether to insert spaces around brackets in object literals.
Defaults to true.
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the formatter for JavaScript (and its super languages) files.
indentSize
Optional
public readonly indentSize: number;
- Type: number
The size of the indentation applied to JavaScript (and its super languages) files.
Default to 2.
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style applied to JavaScript (and its super languages) files.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation applied to JavaScript (and its super languages) files.
Default to 2.
jsxQuoteStyle
Optional
public readonly jsxQuoteStyle: string;
- Type: string
The type of quotes used in JSX.
Defaults to double.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending applied to JavaScript (and its super languages) files.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line applied to JavaScript (and its super languages) files.
Defaults to 80.
quoteProperties
Optional
public readonly quoteProperties: string;
- Type: string
When properties in objects are quoted.
Defaults to asNeeded.
quoteStyle
Optional
public readonly quoteStyle: string;
- Type: string
The type of quotes used in JavaScript code.
Defaults to double.
semicolons
Optional
public readonly semicolons: string;
- Type: string
Whether the formatter prints semicolons for all statements or only in for statements where it is necessary because of ASI.
trailingComma
Optional
public readonly trailingComma: string;
- Type: string
Print trailing commas wherever possible in multi-line comma-separated syntactic structures.
Defaults to "all".
trailingCommas
Optional
public readonly trailingCommas: string;
- Type: string
Print trailing commas wherever possible in multi-line comma-separated syntactic structures.
Defaults to "all".
IJavascriptLinter
- Implemented By: projen.javascript.biomeConfig.IJavascriptLinter
Linter options specific to the JavaScript linter.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the linter for JavaScript (and its super languages) files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the linter for JavaScript (and its super languages) files.
IJavascriptOrganizeImports
- Implemented By: projen.javascript.biomeConfig.IJavascriptOrganizeImports
IJavascriptParser
- Implemented By: projen.javascript.biomeConfig.IJavascriptParser
Options that changes how the JavaScript parser behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables the experimental and unsafe parsing of parameter decorators. |
unsafeParameterDecoratorsEnabled
Optional
public readonly unsafeParameterDecoratorsEnabled: boolean;
- Type: boolean
It enables the experimental and unsafe parsing of parameter decorators.
These decorators belong to an old proposal, and they are subject to change.
IJsonAssists
- Implemented By: projen.javascript.biomeConfig.IJsonAssists
Linter options specific to the JSON linter.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the linter for JSON (and its super languages) files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the linter for JSON (and its super languages) files.
IJsonConfiguration
- Implemented By: projen.javascript.biomeConfig.IJsonConfiguration
Options applied to JSON files.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IJsonAssists | Assists options. |
| projen.javascript.biomeConfig.IJsonFormatter | Formatting options. |
| projen.javascript.biomeConfig.IJsonLinter | Linting options. |
| projen.javascript.biomeConfig.IJsonParser | Parsing options. |
assists
Optional
public readonly assists: IJsonAssists;
- Type: projen.javascript.biomeConfig.IJsonAssists
Assists options.
formatter
Optional
public readonly formatter: IJsonFormatter;
- Type: projen.javascript.biomeConfig.IJsonFormatter
Formatting options.
linter
Optional
public readonly linter: IJsonLinter;
- Type: projen.javascript.biomeConfig.IJsonLinter
Linting options.
parser
Optional
public readonly parser: IJsonParser;
- Type: projen.javascript.biomeConfig.IJsonParser
Parsing options.
IJsonFormatter
- Implemented By: projen.javascript.biomeConfig.IJsonFormatter
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the formatter for JSON (and its super languages) files. |
| number | The size of the indentation applied to JSON (and its super languages) files. |
| string | The indent style applied to JSON (and its super languages) files. |
| number | The size of the indentation applied to JSON (and its super languages) files. |
| string | The type of line ending applied to JSON (and its super languages) files. |
| number | What's the max width of a line applied to JSON (and its super languages) files. |
| string | Print trailing commas wherever possible in multi-line comma-separated syntactic structures. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the formatter for JSON (and its super languages) files.
indentSize
Optional
public readonly indentSize: number;
- Type: number
The size of the indentation applied to JSON (and its super languages) files.
Default to 2.
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style applied to JSON (and its super languages) files.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation applied to JSON (and its super languages) files.
Default to 2.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending applied to JSON (and its super languages) files.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line applied to JSON (and its super languages) files.
Defaults to 80.
trailingCommas
Optional
public readonly trailingCommas: string;
- Type: string
Print trailing commas wherever possible in multi-line comma-separated syntactic structures.
Defaults to "none".
IJsonLinter
- Implemented By: projen.javascript.biomeConfig.IJsonLinter
Linter options specific to the JSON linter.
Properties
Name | Type | Description |
---|---|---|
| boolean | Control the linter for JSON (and its super languages) files. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Control the linter for JSON (and its super languages) files.
IJsonParser
- Implemented By: projen.javascript.biomeConfig.IJsonParser
Options that changes how the JSON parser behaves.
Properties
Name | Type | Description |
---|---|---|
| boolean | Allow parsing comments in .json files. |
| boolean | Allow parsing trailing commas in .json files. |
allowComments
Optional
public readonly allowComments: boolean;
- Type: boolean
Allow parsing comments in .json
files.
allowTrailingCommas
Optional
public readonly allowTrailingCommas: boolean;
- Type: boolean
Allow parsing trailing commas in .json
files.
ILinterConfiguration
- Implemented By: projen.javascript.biomeConfig.ILinterConfiguration
Properties
Name | Type | Description |
---|---|---|
| boolean | if false , it disables the feature and the linter won't be executed. |
| string[] | A list of Unix shell style patterns. |
| string[] | A list of Unix shell style patterns. |
| projen.javascript.biomeConfig.IRules | List of rules. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
if false
, it disables the feature and the linter won't be executed.
true
by default
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will ignore files/folders that will match these patterns.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will include files/folders that will match these patterns.
rules
Optional
public readonly rules: IRules;
- Type: projen.javascript.biomeConfig.IRules
List of rules.
INamingConventionOptions
- Implemented By: projen.javascript.biomeConfig.INamingConventionOptions
Rule's options.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IConvention[] | Custom conventions. |
| string | Allowed cases for TypeScript enum member names. |
| boolean | If false , then non-ASCII characters are allowed. |
| boolean | If false , then consecutive uppercase are allowed in camel and pascal cases. |
conventions
Optional
public readonly conventions: IConvention[];
- Type: projen.javascript.biomeConfig.IConvention[]
Custom conventions.
enumMemberCase
Optional
public readonly enumMemberCase: string;
- Type: string
Allowed cases for TypeScript enum
member names.
requireAscii
Optional
public readonly requireAscii: boolean;
- Type: boolean
If false
, then non-ASCII characters are allowed.
strictCase
Optional
public readonly strictCase: boolean;
- Type: boolean
If false
, then consecutive uppercase are allowed in camel and pascal cases.
This does not affect other [Case].
INoConsoleOptions
- Implemented By: projen.javascript.biomeConfig.INoConsoleOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | Allowed calls on the console object. |
allow
Required
public readonly allow: string[];
- Type: string[]
Allowed calls on the console object.
INoDoubleEqualsOptions
- Implemented By: projen.javascript.biomeConfig.INoDoubleEqualsOptions
Rule's options.
Properties
Name | Type | Description |
---|---|---|
| boolean | If true , an exception is made when comparing with null , as it's often relied on to check both for null or undefined . |
ignoreNull
Optional
public readonly ignoreNull: boolean;
- Type: boolean
If true
, an exception is made when comparing with null
, as it's often relied on to check both for null
or undefined
.
If false
, no such exception will be made.
INoLabelWithoutControlOptions
- Implemented By: projen.javascript.biomeConfig.INoLabelWithoutControlOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | Array of component names that should be considered the same as an input element. |
| string[] | Array of attributes that should be treated as the label accessible text content. |
| string[] | Array of component names that should be considered the same as a label element. |
inputComponents
Optional
public readonly inputComponents: string[];
- Type: string[]
Array of component names that should be considered the same as an input
element.
labelAttributes
Optional
public readonly labelAttributes: string[];
- Type: string[]
Array of attributes that should be treated as the label
accessible text content.
labelComponents
Optional
public readonly labelComponents: string[];
- Type: string[]
Array of component names that should be considered the same as a label
element.
INoRestrictedTypesOptions
- Implemented By: projen.javascript.biomeConfig.INoRestrictedTypesOptions
Properties
Name | Type | Description |
---|---|---|
| {[ key: string ]: string | projen.javascript.biomeConfig.ICustomRestrictedTypeOptions} | No description. |
types
Optional
public readonly types: {[ key: string ]: string | ICustomRestrictedTypeOptions};
- Type: {[ key: string ]: string | projen.javascript.biomeConfig.ICustomRestrictedTypeOptions}
INoSecretsOptions
- Implemented By: projen.javascript.biomeConfig.INoSecretsOptions
Properties
Name | Type | Description |
---|---|---|
| number | Set entropy threshold (default is 41). |
entropyThreshold
Optional
public readonly entropyThreshold: number;
- Type: number
Set entropy threshold (default is 41).
INursery
- Implemented By: projen.javascript.biomeConfig.INursery
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow use of CommonJs module system in favor of ESM style imports. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow a lower specificity selector from coming after a higher specificity selector. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow direct assignments to document.cookie. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevents importing next/document outside of pages/_document.jsx in Next.js projects. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate custom properties within declaration blocks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | No duplicated fields in GraphQL operations. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate conditions in if-else-if chains. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate properties within declaration blocks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow accessing namespace imports dynamically. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow TypeScript enum. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow exporting an imported variable. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent usage of <head> element in a Next.js project. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent using the next/head module in pages/_document.js on Next.js projects. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent usage of <img> element in a Next.js project. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallows the use of irregular whitespace characters. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow missing var function for css variables. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow nested ternary expressions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow octal escape sequences in string literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of process.env. |
| string | projen.javascript.biomeConfig.IRuleWithRestrictedImportsOptions | Disallow specified modules when loaded by import or require. |
| string | projen.javascript.biomeConfig.IRuleWithNoRestrictedTypesOptions | Disallow user defined types. |
| string | projen.javascript.biomeConfig.IRuleWithNoSecretsOptions | Disallow usage of sensitive data such as API keys and tokens. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that static, visible elements (such as <div>) that have click handlers use the valid role attribute. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of String.slice() over String.substr() and String.substring(). |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow template literal placeholder syntax in regular strings. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown pseudo-class selectors. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown pseudo-element selectors. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unknown type selectors. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow unnecessary escape sequence in regular expression literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unnecessary String.raw function in template string literals without any escape sequence. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow use of. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of overload signatures that are not next to each other. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce that ARIA properties are valid for the roles that are supported by the element. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use at() instead of integer index access. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce using single if instead of nested if clauses. |
| string | projen.javascript.biomeConfig.IRuleWithUseComponentExportOnlyModulesOptions | Enforce declaring components only within modules that export React Components exclusively. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | This rule enforces consistent use of curly braces inside JSX attributes and JSX children. |
| string | projen.javascript.biomeConfig.IRuleWithConsistentMemberAccessibilityOptions | Require consistent accessibility modifiers on class properties and methods. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require specifying the reason argument when using. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require explicit return types on functions and class methods. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforces the use of a recommended display strategy with Google Fonts. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require for-in loops to include an if statement. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallows package private imports. |
| string | projen.javascript.biomeConfig.IRuleWithUtilityClassSortingOptions | Enforce the sorting of CSS utility classes. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of the directive "use strict" in script files. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of String.trimStart() and String.trimEnd() over String.trimLeft() and String.trimRight(). |
| string | projen.javascript.biomeConfig.IRuleWithUseValidAutocompleteOptions | Use valid values for the autocomplete attribute on input elements. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noCommonJs
Optional
public readonly noCommonJs: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow use of CommonJs module system in favor of ESM style imports.
noDescendingSpecificity
Optional
public readonly noDescendingSpecificity: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow a lower specificity selector from coming after a higher specificity selector.
noDocumentCookie
Optional
public readonly noDocumentCookie: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow direct assignments to document.cookie.
noDocumentImportInPage
Optional
public readonly noDocumentImportInPage: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevents importing next/document outside of pages/_document.jsx in Next.js projects.
noDuplicateCustomProperties
Optional
public readonly noDuplicateCustomProperties: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate custom properties within declaration blocks.
noDuplicatedFields
Optional
public readonly noDuplicatedFields: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
No duplicated fields in GraphQL operations.
noDuplicateElseIf
Optional
public readonly noDuplicateElseIf: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate conditions in if-else-if chains.
noDuplicateProperties
Optional
public readonly noDuplicateProperties: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate properties within declaration blocks.
noDynamicNamespaceImportAccess
Optional
public readonly noDynamicNamespaceImportAccess: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow accessing namespace imports dynamically.
noEnum
Optional
public readonly noEnum: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow TypeScript enum.
noExportedImports
Optional
public readonly noExportedImports: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow exporting an imported variable.
noHeadElement
Optional
public readonly noHeadElement: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent usage of <head> element in a Next.js project.
noHeadImportInDocument
Optional
public readonly noHeadImportInDocument: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent using the next/head module in pages/_document.js on Next.js projects.
noImgElement
Optional
public readonly noImgElement: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent usage of <img> element in a Next.js project.
noIrregularWhitespace
Optional
public readonly noIrregularWhitespace: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallows the use of irregular whitespace characters.
noMissingVarFunction
Optional
public readonly noMissingVarFunction: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow missing var function for css variables.
noNestedTernary
Optional
public readonly noNestedTernary: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow nested ternary expressions.
noOctalEscape
Optional
public readonly noOctalEscape: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow octal escape sequences in string literals.
noProcessEnv
Optional
public readonly noProcessEnv: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of process.env.
noRestrictedImports
Optional
public readonly noRestrictedImports: string | IRuleWithRestrictedImportsOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithRestrictedImportsOptions
Disallow specified modules when loaded by import or require.
noRestrictedTypes
Optional
public readonly noRestrictedTypes: string | IRuleWithNoRestrictedTypesOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoRestrictedTypesOptions
Disallow user defined types.
noSecrets
Optional
public readonly noSecrets: string | IRuleWithNoSecretsOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoSecretsOptions
Disallow usage of sensitive data such as API keys and tokens.
noStaticElementInteractions
Optional
public readonly noStaticElementInteractions: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that static, visible elements (such as <div>) that have click handlers use the valid role attribute.
noSubstr
Optional
public readonly noSubstr: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of String.slice() over String.substr() and String.substring().
noTemplateCurlyInString
Optional
public readonly noTemplateCurlyInString: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow template literal placeholder syntax in regular strings.
noUnknownPseudoClass
Optional
public readonly noUnknownPseudoClass: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown pseudo-class selectors.
noUnknownPseudoElement
Optional
public readonly noUnknownPseudoElement: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown pseudo-element selectors.
noUnknownTypeSelector
Optional
public readonly noUnknownTypeSelector: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unknown type selectors.
noUselessEscapeInRegex
Optional
public readonly noUselessEscapeInRegex: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow unnecessary escape sequence in regular expression literals.
noUselessStringRaw
Optional
public readonly noUselessStringRaw: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unnecessary String.raw function in template string literals without any escape sequence.
noValueAtRule
Optional
public readonly noValueAtRule: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow use of.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useAdjacentOverloadSignatures
Optional
public readonly useAdjacentOverloadSignatures: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of overload signatures that are not next to each other.
useAriaPropsSupportedByRole
Optional
public readonly useAriaPropsSupportedByRole: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce that ARIA properties are valid for the roles that are supported by the element.
useAtIndex
Optional
public readonly useAtIndex: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use at() instead of integer index access.
useCollapsedIf
Optional
public readonly useCollapsedIf: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce using single if instead of nested if clauses.
useComponentExportOnlyModules
Optional
public readonly useComponentExportOnlyModules: string | IRuleWithUseComponentExportOnlyModulesOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithUseComponentExportOnlyModulesOptions
Enforce declaring components only within modules that export React Components exclusively.
useConsistentCurlyBraces
Optional
public readonly useConsistentCurlyBraces: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
This rule enforces consistent use of curly braces inside JSX attributes and JSX children.
useConsistentMemberAccessibility
Optional
public readonly useConsistentMemberAccessibility: string | IRuleWithConsistentMemberAccessibilityOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithConsistentMemberAccessibilityOptions
Require consistent accessibility modifiers on class properties and methods.
useDeprecatedReason
Optional
useDeprecatedReason
- Deprecated: directive
public readonly useDeprecatedReason: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require specifying the reason argument when using.
useExplicitType
Optional
public readonly useExplicitType: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require explicit return types on functions and class methods.
useGoogleFontDisplay
Optional
public readonly useGoogleFontDisplay: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforces the use of a recommended display strategy with Google Fonts.
useGuardForIn
Optional
public readonly useGuardForIn: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require for-in loops to include an if statement.
useImportRestrictions
Optional
public readonly useImportRestrictions: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallows package private imports.
useSortedClasses
Optional
public readonly useSortedClasses: string | IRuleWithUtilityClassSortingOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithUtilityClassSortingOptions
Enforce the sorting of CSS utility classes.
useStrictMode
Optional
public readonly useStrictMode: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of the directive "use strict" in script files.
useTrimStartEnd
Optional
public readonly useTrimStartEnd: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of String.trimStart() and String.trimEnd() over String.trimLeft() and String.trimRight().
useValidAutocomplete
Optional
public readonly useValidAutocomplete: string | IRuleWithUseValidAutocompleteOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithUseValidAutocompleteOptions
Use valid values for the autocomplete attribute on input elements.
IOrganizeImports
- Implemented By: projen.javascript.biomeConfig.IOrganizeImports
Properties
Name | Type | Description |
---|---|---|
| boolean | Enables the organization of imports. |
| string[] | A list of Unix shell style patterns. |
| string[] | A list of Unix shell style patterns. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
Enables the organization of imports.
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will ignore files/folders that will match these patterns.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will include files/folders that will match these patterns.
IOverrideFormatterConfiguration
- Implemented By: projen.javascript.biomeConfig.IOverrideFormatterConfiguration
Properties
Name | Type | Description |
---|---|---|
| string | The attribute position style. |
| boolean | Whether to insert spaces around brackets in object literals. |
| boolean | No description. |
| boolean | Stores whether formatting should be allowed to proceed if a given file has syntax errors. |
| number | The size of the indentation, 2 by default (deprecated, use indent-width ). |
| string | The indent style. |
| number | The size of the indentation, 2 by default. |
| string | The type of line ending. |
| number | What's the max width of a line. |
attributePosition
Optional
public readonly attributePosition: string;
- Type: string
The attribute position style.
bracketSpacing
Optional
public readonly bracketSpacing: boolean;
- Type: boolean
Whether to insert spaces around brackets in object literals.
Defaults to true.
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
formatWithErrors
Optional
public readonly formatWithErrors: boolean;
- Type: boolean
Stores whether formatting should be allowed to proceed if a given file has syntax errors.
indentSize
Optional
public readonly indentSize: number;
- Type: number
The size of the indentation, 2 by default (deprecated, use indent-width
).
indentStyle
Optional
public readonly indentStyle: string;
- Type: string
The indent style.
indentWidth
Optional
public readonly indentWidth: number;
- Type: number
The size of the indentation, 2 by default.
lineEnding
Optional
public readonly lineEnding: string;
- Type: string
The type of line ending.
lineWidth
Optional
public readonly lineWidth: number;
- Type: number
What's the max width of a line.
Defaults to 80.
IOverrideLinterConfiguration
- Implemented By: projen.javascript.biomeConfig.IOverrideLinterConfiguration
Properties
Name | Type | Description |
---|---|---|
| boolean | if false , it disables the feature and the linter won't be executed. |
| projen.javascript.biomeConfig.IRules | List of rules. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
if false
, it disables the feature and the linter won't be executed.
true
by default
rules
Optional
public readonly rules: IRules;
- Type: projen.javascript.biomeConfig.IRules
List of rules.
IOverrideOrganizeImportsConfiguration
- Implemented By: projen.javascript.biomeConfig.IOverrideOrganizeImportsConfiguration
Properties
Name | Type | Description |
---|---|---|
| boolean | if false , it disables the feature and the linter won't be executed. |
enabled
Optional
public readonly enabled: boolean;
- Type: boolean
if false
, it disables the feature and the linter won't be executed.
true
by default
IOverridePattern
- Implemented By: projen.javascript.biomeConfig.IOverridePattern
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.ICssConfiguration | Specific configuration for the Css language. |
| projen.javascript.biomeConfig.IOverrideFormatterConfiguration | Specific configuration for the Json language. |
| projen.javascript.biomeConfig.IGraphqlConfiguration | Specific configuration for the Graphql language. |
| string[] | A list of Unix shell style patterns. |
| string[] | A list of Unix shell style patterns. |
| projen.javascript.biomeConfig.IJavascriptConfiguration | Specific configuration for the JavaScript language. |
| projen.javascript.biomeConfig.IJsonConfiguration | Specific configuration for the Json language. |
| projen.javascript.biomeConfig.IOverrideLinterConfiguration | Specific configuration for the Json language. |
| projen.javascript.biomeConfig.IOverrideOrganizeImportsConfiguration | Specific configuration for the Json language. |
css
Optional
public readonly css: ICssConfiguration;
- Type: projen.javascript.biomeConfig.ICssConfiguration
Specific configuration for the Css language.
formatter
Optional
public readonly formatter: IOverrideFormatterConfiguration;
- Type: projen.javascript.biomeConfig.IOverrideFormatterConfiguration
Specific configuration for the Json language.
graphql
Optional
public readonly graphql: IGraphqlConfiguration;
- Type: projen.javascript.biomeConfig.IGraphqlConfiguration
Specific configuration for the Graphql language.
ignore
Optional
public readonly ignore: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will ignore files/folders that will match these patterns.
include
Optional
public readonly include: string[];
- Type: string[]
A list of Unix shell style patterns.
The formatter will include files/folders that will match these patterns.
javascript
Optional
public readonly javascript: IJavascriptConfiguration;
- Type: projen.javascript.biomeConfig.IJavascriptConfiguration
Specific configuration for the JavaScript language.
json
Optional
public readonly json: IJsonConfiguration;
- Type: projen.javascript.biomeConfig.IJsonConfiguration
Specific configuration for the Json language.
linter
Optional
public readonly linter: IOverrideLinterConfiguration;
- Type: projen.javascript.biomeConfig.IOverrideLinterConfiguration
Specific configuration for the Json language.
organizeImports
Optional
public readonly organizeImports: IOverrideOrganizeImportsConfiguration;
- Type: projen.javascript.biomeConfig.IOverrideOrganizeImportsConfiguration
Specific configuration for the Json language.
IPerformance
- Implemented By: projen.javascript.biomeConfig.IPerformance
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of spread (...) syntax on accumulators. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of barrel file. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of the delete operator. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Avoid re-export all. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require regex literals to be declared at the top level. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noAccumulatingSpread
Optional
public readonly noAccumulatingSpread: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of spread (...) syntax on accumulators.
noBarrelFile
Optional
public readonly noBarrelFile: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of barrel file.
noDelete
Optional
public readonly noDelete: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of the delete operator.
noReExportAll
Optional
public readonly noReExportAll: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Avoid re-export all.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useTopLevelRegex
Optional
public readonly useTopLevelRegex: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require regex literals to be declared at the top level.
IRestrictedGlobalsOptions
- Implemented By: projen.javascript.biomeConfig.IRestrictedGlobalsOptions
Options for the rule noRestrictedGlobals
.
Properties
Name | Type | Description |
---|---|---|
| string[] | A list of names that should trigger the rule. |
deniedGlobals
Optional
public readonly deniedGlobals: string[];
- Type: string[]
A list of names that should trigger the rule.
IRestrictedImportsOptions
- Implemented By: projen.javascript.biomeConfig.IRestrictedImportsOptions
Options for the rule noRestrictedImports
.
Properties
Name | Type | Description |
---|---|---|
| {[ key: string ]: string} | A list of names that should trigger the rule. |
paths
Optional
public readonly paths: {[ key: string ]: string};
- Type: {[ key: string ]: string}
A list of names that should trigger the rule.
IRules
- Implemented By: projen.javascript.biomeConfig.IRules
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IA11y | No description. |
| boolean | It enables ALL rules. |
| projen.javascript.biomeConfig.IComplexity | No description. |
| projen.javascript.biomeConfig.ICorrectness | No description. |
| projen.javascript.biomeConfig.INursery | No description. |
| projen.javascript.biomeConfig.IPerformance | No description. |
| boolean | It enables the lint rules recommended by Biome. |
| projen.javascript.biomeConfig.ISecurity | No description. |
| projen.javascript.biomeConfig.IStyle | No description. |
| projen.javascript.biomeConfig.ISuspicious | No description. |
a11y
Optional
public readonly a11y: IA11y;
- Type: projen.javascript.biomeConfig.IA11y
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules.
The rules that belong to nursery
won't be enabled.
complexity
Optional
public readonly complexity: IComplexity;
- Type: projen.javascript.biomeConfig.IComplexity
correctness
Optional
public readonly correctness: ICorrectness;
- Type: projen.javascript.biomeConfig.ICorrectness
nursery
Optional
public readonly nursery: INursery;
- Type: projen.javascript.biomeConfig.INursery
performance
Optional
public readonly performance: IPerformance;
- Type: projen.javascript.biomeConfig.IPerformance
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the lint rules recommended by Biome.
true
by default.
security
Optional
public readonly security: ISecurity;
- Type: projen.javascript.biomeConfig.ISecurity
style
Optional
public readonly style: IStyle;
- Type: projen.javascript.biomeConfig.IStyle
suspicious
Optional
public readonly suspicious: ISuspicious;
- Type: projen.javascript.biomeConfig.ISuspicious
IRuleWithAllowDomainOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithAllowDomainOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.IAllowDomainOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: IAllowDomainOptions;
- Type: projen.javascript.biomeConfig.IAllowDomainOptions
Rule's options.
IRuleWithComplexityOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithComplexityOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IComplexityOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IComplexityOptions;
- Type: projen.javascript.biomeConfig.IComplexityOptions
Rule's options.
IRuleWithConsistentArrayTypeOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithConsistentArrayTypeOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.IConsistentArrayTypeOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: IConsistentArrayTypeOptions;
- Type: projen.javascript.biomeConfig.IConsistentArrayTypeOptions
Rule's options.
IRuleWithConsistentMemberAccessibilityOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithConsistentMemberAccessibilityOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IConsistentMemberAccessibilityOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IConsistentMemberAccessibilityOptions;
- Type: projen.javascript.biomeConfig.IConsistentMemberAccessibilityOptions
Rule's options.
IRuleWithDeprecatedHooksOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithDeprecatedHooksOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IDeprecatedHooksOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IDeprecatedHooksOptions;
- Type: projen.javascript.biomeConfig.IDeprecatedHooksOptions
Rule's options.
IRuleWithFilenamingConventionOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithFilenamingConventionOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IFilenamingConventionOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IFilenamingConventionOptions;
- Type: projen.javascript.biomeConfig.IFilenamingConventionOptions
Rule's options.
IRuleWithFixNoOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithFixNoOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
IRuleWithNamingConventionOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNamingConventionOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.INamingConventionOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: INamingConventionOptions;
- Type: projen.javascript.biomeConfig.INamingConventionOptions
Rule's options.
IRuleWithNoConsoleOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoConsoleOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.INoConsoleOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: INoConsoleOptions;
- Type: projen.javascript.biomeConfig.INoConsoleOptions
Rule's options.
IRuleWithNoDoubleEqualsOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoDoubleEqualsOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.INoDoubleEqualsOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: INoDoubleEqualsOptions;
- Type: projen.javascript.biomeConfig.INoDoubleEqualsOptions
Rule's options.
IRuleWithNoLabelWithoutControlOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoLabelWithoutControlOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.INoLabelWithoutControlOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: INoLabelWithoutControlOptions;
- Type: projen.javascript.biomeConfig.INoLabelWithoutControlOptions
Rule's options.
IRuleWithNoOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
IRuleWithNoRestrictedTypesOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoRestrictedTypesOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.INoRestrictedTypesOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: INoRestrictedTypesOptions;
- Type: projen.javascript.biomeConfig.INoRestrictedTypesOptions
Rule's options.
IRuleWithNoSecretsOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithNoSecretsOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.INoSecretsOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: INoSecretsOptions;
- Type: projen.javascript.biomeConfig.INoSecretsOptions
Rule's options.
IRuleWithRestrictedGlobalsOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithRestrictedGlobalsOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IRestrictedGlobalsOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IRestrictedGlobalsOptions;
- Type: projen.javascript.biomeConfig.IRestrictedGlobalsOptions
Rule's options.
IRuleWithRestrictedImportsOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithRestrictedImportsOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IRestrictedImportsOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IRestrictedImportsOptions;
- Type: projen.javascript.biomeConfig.IRestrictedImportsOptions
Rule's options.
IRuleWithUseComponentExportOnlyModulesOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithUseComponentExportOnlyModulesOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IUseComponentExportOnlyModulesOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IUseComponentExportOnlyModulesOptions;
- Type: projen.javascript.biomeConfig.IUseComponentExportOnlyModulesOptions
Rule's options.
IRuleWithUseExhaustiveDependenciesOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithUseExhaustiveDependenciesOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IUseExhaustiveDependenciesOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IUseExhaustiveDependenciesOptions;
- Type: projen.javascript.biomeConfig.IUseExhaustiveDependenciesOptions
Rule's options.
IRuleWithUseImportExtensionsOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithUseImportExtensionsOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.IUseImportExtensionsOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: IUseImportExtensionsOptions;
- Type: projen.javascript.biomeConfig.IUseImportExtensionsOptions
Rule's options.
IRuleWithUseValidAutocompleteOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithUseValidAutocompleteOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| projen.javascript.biomeConfig.IUseValidAutocompleteOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
options
Optional
public readonly options: IUseValidAutocompleteOptions;
- Type: projen.javascript.biomeConfig.IUseValidAutocompleteOptions
Rule's options.
IRuleWithUtilityClassSortingOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithUtilityClassSortingOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.IUtilityClassSortingOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: IUtilityClassSortingOptions;
- Type: projen.javascript.biomeConfig.IUtilityClassSortingOptions
Rule's options.
IRuleWithValidAriaRoleOptions
- Implemented By: projen.javascript.biomeConfig.IRuleWithValidAriaRoleOptions
Properties
Name | Type | Description |
---|---|---|
| string | The severity of the emitted diagnostics by the rule. |
| string | The kind of the code actions emitted by the rule. |
| projen.javascript.biomeConfig.IValidAriaRoleOptions | Rule's options. |
level
Required
public readonly level: string;
- Type: string
The severity of the emitted diagnostics by the rule.
fix
Optional
public readonly fix: string;
- Type: string
The kind of the code actions emitted by the rule.
options
Optional
public readonly options: IValidAriaRoleOptions;
- Type: projen.javascript.biomeConfig.IValidAriaRoleOptions
Rule's options.
ISecurity
- Implemented By: projen.javascript.biomeConfig.ISecurity
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevent the usage of dangerous JSX props. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Report when a DOM element or a component uses both children and dangerouslySetInnerHTML prop. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of global eval(). |
| boolean | It enables the recommended rules for this group. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noDangerouslySetInnerHtml
Optional
public readonly noDangerouslySetInnerHtml: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevent the usage of dangerous JSX props.
noDangerouslySetInnerHtmlWithChildren
Optional
public readonly noDangerouslySetInnerHtmlWithChildren: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Report when a DOM element or a component uses both children and dangerouslySetInnerHTML prop.
noGlobalEval
Optional
public readonly noGlobalEval: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of global eval().
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
ISelector
- Implemented By: projen.javascript.biomeConfig.ISelector
Properties
Name | Type | Description |
---|---|---|
| string | Declaration kind. |
| string[] | Modifiers used on the declaration. |
| string | Scope of the declaration. |
kind
Optional
public readonly kind: string;
- Type: string
Declaration kind.
modifiers
Optional
public readonly modifiers: string[];
- Type: string[]
Modifiers used on the declaration.
scope
Optional
public readonly scope: string;
- Type: string
Scope of the declaration.
ISource
- Implemented By: projen.javascript.biomeConfig.ISource
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| string | Enforce props sorting in JSX elements. |
| string | Sorts the keys of a JSON object in natural order. |
sortJsxProps
Optional
public readonly sortJsxProps: string;
- Type: string
Enforce props sorting in JSX elements.
useSortedKeys
Optional
public readonly useSortedKeys: string;
- Type: string
Sorts the keys of a JSON object in natural order.
IStyle
- Implemented By: projen.javascript.biomeConfig.IStyle
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of arguments. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow comma operator. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow default exports. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow using a callback in asynchronous tests and hooks. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow implicit true values on JSX boolean attributes. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow type annotations for variables, parameters, and class properties initialized with a literal expression. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of TypeScript's namespaces. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of namespace imports. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow negation in the condition of an if statement if it has an else clause. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow non-null assertions using the ! |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow reassigning function parameters. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the use of parameter properties in class constructors. |
| string | projen.javascript.biomeConfig.IRuleWithRestrictedGlobalsOptions | This rule allows you to specify global variable names that you don’t want to use in your application. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of constants which its value is the upper-case version of its name. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow template literals if interpolation and special-character handling are not needed. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow else block when the if block breaks early. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of var. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of yoda expressions. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of as const over literal type and type annotation. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Requires following curly brace conventions. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce using else if instead of nested if in else clauses. |
| string | projen.javascript.biomeConfig.IRuleWithConsistentArrayTypeOptions | Require consistently using either T[] or Array<T>. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of new for all builtins, except String, Number and Boolean. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require const declarations for variables that are only assigned once. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce default function parameters and optional function parameters to be last. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require the default clause in switch statements. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require that each enum member value be explicitly initialized. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce explicitly comparing the length, size, byteLength or byteOffset property of a value. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of Math.pow in favor of the ** operator. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Promotes the use of export type for types. |
| string | projen.javascript.biomeConfig.IRuleWithFilenamingConventionOptions | Enforce naming conventions for JavaScript and TypeScript filenames. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | This rule recommends a for-of loop when in a for loop, the index used to extract an item from the iterated array. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | This rule enforces the use of <>...</> over <Fragment>...</Fragment>. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Promotes the use of import type for types. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Require all enum members to be literal values. |
| string | projen.javascript.biomeConfig.IRuleWithNamingConventionOptions | Enforce naming conventions for everything across a codebase. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Promotes the usage of node:assert/strict over node:assert. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforces using the node: protocol for Node.js builtin modules. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use the Number properties instead of global ones. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow parseInt() and Number.parseInt() in favor of binary, octal, and hexadecimal literals. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevent extra closing tags for components without children. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | When expressing array types, this rule promotes the usage of T[] shorthand instead of Array<T>. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require assignment operator shorthand where possible. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce using function types instead of object type with call signatures. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforces switch clauses have a single statement, emits a quick fix wrapping the statements in a block. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow multiple variable declarations in the same variable statement. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prefer template literals over string concatenation. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require new when throwing an error. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow throwing non-Error values. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce the use of while loops instead of for loops when the initializer and update expressions are not needed. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noArguments
Optional
public readonly noArguments: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of arguments.
noCommaOperator
Optional
public readonly noCommaOperator: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow comma operator.
noDefaultExport
Optional
public readonly noDefaultExport: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow default exports.
noDoneCallback
Optional
public readonly noDoneCallback: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow using a callback in asynchronous tests and hooks.
noImplicitBoolean
Optional
public readonly noImplicitBoolean: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow implicit true values on JSX boolean attributes.
noInferrableTypes
Optional
public readonly noInferrableTypes: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow type annotations for variables, parameters, and class properties initialized with a literal expression.
noNamespace
Optional
public readonly noNamespace: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of TypeScript's namespaces.
noNamespaceImport
Optional
public readonly noNamespaceImport: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of namespace imports.
noNegationElse
Optional
public readonly noNegationElse: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow negation in the condition of an if statement if it has an else clause.
noNonNullAssertion
Optional
public readonly noNonNullAssertion: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow non-null assertions using the !
postfix operator.
noParameterAssign
Optional
public readonly noParameterAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow reassigning function parameters.
noParameterProperties
Optional
public readonly noParameterProperties: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the use of parameter properties in class constructors.
noRestrictedGlobals
Optional
public readonly noRestrictedGlobals: string | IRuleWithRestrictedGlobalsOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithRestrictedGlobalsOptions
This rule allows you to specify global variable names that you don’t want to use in your application.
noShoutyConstants
Optional
public readonly noShoutyConstants: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of constants which its value is the upper-case version of its name.
noUnusedTemplateLiteral
Optional
public readonly noUnusedTemplateLiteral: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow template literals if interpolation and special-character handling are not needed.
noUselessElse
Optional
public readonly noUselessElse: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow else block when the if block breaks early.
noVar
Optional
public readonly noVar: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of var.
noYodaExpression
Optional
public readonly noYodaExpression: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of yoda expressions.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useAsConstAssertion
Optional
public readonly useAsConstAssertion: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of as const over literal type and type annotation.
useBlockStatements
Optional
public readonly useBlockStatements: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Requires following curly brace conventions.
useCollapsedElseIf
Optional
public readonly useCollapsedElseIf: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce using else if instead of nested if in else clauses.
useConsistentArrayType
Optional
public readonly useConsistentArrayType: string | IRuleWithConsistentArrayTypeOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithConsistentArrayTypeOptions
Require consistently using either T[] or Array<T>.
useConsistentBuiltinInstantiation
Optional
public readonly useConsistentBuiltinInstantiation: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of new for all builtins, except String, Number and Boolean.
useConst
Optional
public readonly useConst: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require const declarations for variables that are only assigned once.
useDefaultParameterLast
Optional
public readonly useDefaultParameterLast: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce default function parameters and optional function parameters to be last.
useDefaultSwitchClause
Optional
public readonly useDefaultSwitchClause: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require the default clause in switch statements.
useEnumInitializers
Optional
public readonly useEnumInitializers: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require that each enum member value be explicitly initialized.
useExplicitLengthCheck
Optional
public readonly useExplicitLengthCheck: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce explicitly comparing the length, size, byteLength or byteOffset property of a value.
useExponentiationOperator
Optional
public readonly useExponentiationOperator: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of Math.pow in favor of the ** operator.
useExportType
Optional
public readonly useExportType: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Promotes the use of export type for types.
useFilenamingConvention
Optional
public readonly useFilenamingConvention: string | IRuleWithFilenamingConventionOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFilenamingConventionOptions
Enforce naming conventions for JavaScript and TypeScript filenames.
useForOf
Optional
public readonly useForOf: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
This rule recommends a for-of loop when in a for loop, the index used to extract an item from the iterated array.
useFragmentSyntax
Optional
public readonly useFragmentSyntax: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
This rule enforces the use of <>...</> over <Fragment>...</Fragment>.
useImportType
Optional
public readonly useImportType: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Promotes the use of import type for types.
useLiteralEnumMembers
Optional
public readonly useLiteralEnumMembers: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Require all enum members to be literal values.
useNamingConvention
Optional
public readonly useNamingConvention: string | IRuleWithNamingConventionOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNamingConventionOptions
Enforce naming conventions for everything across a codebase.
useNodeAssertStrict
Optional
public readonly useNodeAssertStrict: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Promotes the usage of node:assert/strict over node:assert.
useNodejsImportProtocol
Optional
public readonly useNodejsImportProtocol: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforces using the node: protocol for Node.js builtin modules.
useNumberNamespace
Optional
public readonly useNumberNamespace: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use the Number properties instead of global ones.
useNumericLiterals
Optional
public readonly useNumericLiterals: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow parseInt() and Number.parseInt() in favor of binary, octal, and hexadecimal literals.
useSelfClosingElements
Optional
public readonly useSelfClosingElements: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevent extra closing tags for components without children.
useShorthandArrayType
Optional
public readonly useShorthandArrayType: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
When expressing array types, this rule promotes the usage of T[] shorthand instead of Array<T>.
useShorthandAssign
Optional
public readonly useShorthandAssign: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require assignment operator shorthand where possible.
useShorthandFunctionType
Optional
public readonly useShorthandFunctionType: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce using function types instead of object type with call signatures.
useSingleCaseStatement
Optional
public readonly useSingleCaseStatement: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforces switch clauses have a single statement, emits a quick fix wrapping the statements in a block.
useSingleVarDeclarator
Optional
public readonly useSingleVarDeclarator: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow multiple variable declarations in the same variable statement.
useTemplate
Optional
public readonly useTemplate: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prefer template literals over string concatenation.
useThrowNewError
Optional
public readonly useThrowNewError: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require new when throwing an error.
useThrowOnlyError
Optional
public readonly useThrowOnlyError: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow throwing non-Error values.
useWhile
Optional
public readonly useWhile: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce the use of while loops instead of for loops when the initializer and update expressions are not needed.
ISuggestedExtensionMapping
- Implemented By: projen.javascript.biomeConfig.ISuggestedExtensionMapping
Properties
Name | Type | Description |
---|---|---|
| string | Extension that should be used for component file imports. |
| string | Extension that should be used for module imports. |
component
Optional
public readonly component: string;
- Type: string
Extension that should be used for component file imports.
module
Optional
public readonly module: string;
- Type: string
Extension that should be used for module imports.
ISuspicious
- Implemented By: projen.javascript.biomeConfig.ISuspicious
A list of rules that belong to this group.
Properties
Name | Type | Description |
---|---|---|
| boolean | It enables ALL rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use standard constants instead of approximated literals. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Discourage the usage of Array index in keys. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow assignments in expressions. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallows using an async function as a Promise executor. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow reassigning exceptions in catch clauses. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow reassigning class members. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevent comments from being inserted as text nodes. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow comparing against -0. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow labeled statements that are not loops. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow void type outside of generic or return types. |
| string | projen.javascript.biomeConfig.IRuleWithNoConsoleOptions | Disallow the use of console. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of console.log. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow TypeScript const enum. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevents from having control characters and some escape sequences that match control characters in regular expressions. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the use of debugger. |
| string | projen.javascript.biomeConfig.IRuleWithNoDoubleEqualsOptions | Require the use of === and !==. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate case labels. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate class members. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate names within font families. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Prevents JSX properties to be assigned multiple times. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow two keys with the same name inside objects. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate function parameter name. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow duplicate selectors within keyframe blocks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | A describe block should not contain duplicate hooks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow CSS empty blocks. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow empty block statements and static blocks. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow the declaration of empty interfaces. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow variables from evolving into any type through reassignments. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow the any type usage. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow using export or module.exports in files containing tests. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevents the wrong usage of the non-null assertion operator (!) in TypeScript files. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow fallthrough of switch clauses. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow focused tests. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow reassigning function declarations. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow assignments to native objects and read-only global variables. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use Number.isFinite instead of global isFinite. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use Number.isNaN instead of global isNaN. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow use of implicit any type on variable declarations. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow invalid !important within keyframe declarations. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow assigning to imported bindings. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow labels that share a name with a variable. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow characters made with multiple code points in character class syntax. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce proper usage of new and constructor. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Checks that the assertion function, for example expect, is placed inside an it() function call. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow shorthand assign when variable appears on both sides. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow direct use of Object.prototype builtins. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevents React-specific JSX properties from being used. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow variable, function, class, and type redeclarations in the same scope. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Prevents from having redundant "use strict". |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow comparisons where both sides are exactly the same. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow identifiers from shadowing restricted names. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow shorthand properties that override related longhand properties. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow disabled tests. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow sparse arrays. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | It detects possible "wrong" semicolons inside JSX elements. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow then property. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Disallow unsafe declaration merging between interfaces and classes. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Disallow using unsafe negation. |
| boolean | It enables the recommended rules for this group. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Ensure async functions utilize await. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce default clauses in switch statements to be last. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce passing a message value when creating a built-in error. |
| string | projen.javascript.biomeConfig.IRuleWithNoOptions | Enforce get methods to always return a value. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Use Array.isArray() instead of instanceof Array. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Require using the namespace keyword over the module keyword to declare TypeScript namespaces. |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | Enforce using the digits argument with Number#toFixed(). |
| string | projen.javascript.biomeConfig.IRuleWithFixNoOptions | This rule verifies the result of typeof $expr unary expressions is being compared to valid values, either string literals containing valid type names or other typeof expressions. |
all
Optional
public readonly all: boolean;
- Type: boolean
It enables ALL rules for this group.
noApproximativeNumericConstant
Optional
public readonly noApproximativeNumericConstant: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use standard constants instead of approximated literals.
noArrayIndexKey
Optional
public readonly noArrayIndexKey: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Discourage the usage of Array index in keys.
noAssignInExpressions
Optional
public readonly noAssignInExpressions: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow assignments in expressions.
noAsyncPromiseExecutor
Optional
public readonly noAsyncPromiseExecutor: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallows using an async function as a Promise executor.
noCatchAssign
Optional
public readonly noCatchAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow reassigning exceptions in catch clauses.
noClassAssign
Optional
public readonly noClassAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow reassigning class members.
noCommentText
Optional
public readonly noCommentText: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevent comments from being inserted as text nodes.
noCompareNegZero
Optional
public readonly noCompareNegZero: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow comparing against -0.
noConfusingLabels
Optional
public readonly noConfusingLabels: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow labeled statements that are not loops.
noConfusingVoidType
Optional
public readonly noConfusingVoidType: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow void type outside of generic or return types.
noConsole
Optional
public readonly noConsole: string | IRuleWithNoConsoleOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoConsoleOptions
Disallow the use of console.
noConsoleLog
Optional
public readonly noConsoleLog: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of console.log.
noConstEnum
Optional
public readonly noConstEnum: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow TypeScript const enum.
noControlCharactersInRegex
Optional
public readonly noControlCharactersInRegex: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevents from having control characters and some escape sequences that match control characters in regular expressions.
noDebugger
Optional
public readonly noDebugger: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the use of debugger.
noDoubleEquals
Optional
public readonly noDoubleEquals: string | IRuleWithNoDoubleEqualsOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoDoubleEqualsOptions
Require the use of === and !==.
noDuplicateAtImportRules
Optional
public readonly noDuplicateAtImportRules: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate.
noDuplicateCase
Optional
public readonly noDuplicateCase: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate case labels.
noDuplicateClassMembers
Optional
public readonly noDuplicateClassMembers: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate class members.
noDuplicateFontNames
Optional
public readonly noDuplicateFontNames: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate names within font families.
noDuplicateJsxProps
Optional
public readonly noDuplicateJsxProps: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Prevents JSX properties to be assigned multiple times.
noDuplicateObjectKeys
Optional
public readonly noDuplicateObjectKeys: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow two keys with the same name inside objects.
noDuplicateParameters
Optional
public readonly noDuplicateParameters: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate function parameter name.
noDuplicateSelectorsKeyframeBlock
Optional
public readonly noDuplicateSelectorsKeyframeBlock: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow duplicate selectors within keyframe blocks.
noDuplicateTestHooks
Optional
public readonly noDuplicateTestHooks: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
A describe block should not contain duplicate hooks.
noEmptyBlock
Optional
public readonly noEmptyBlock: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow CSS empty blocks.
noEmptyBlockStatements
Optional
public readonly noEmptyBlockStatements: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow empty block statements and static blocks.
noEmptyInterface
Optional
public readonly noEmptyInterface: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow the declaration of empty interfaces.
noEvolvingTypes
Optional
public readonly noEvolvingTypes: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow variables from evolving into any type through reassignments.
noExplicitAny
Optional
public readonly noExplicitAny: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow the any type usage.
noExportsInTest
Optional
public readonly noExportsInTest: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow using export or module.exports in files containing tests.
noExtraNonNullAssertion
Optional
public readonly noExtraNonNullAssertion: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevents the wrong usage of the non-null assertion operator (!) in TypeScript files.
noFallthroughSwitchClause
Optional
public readonly noFallthroughSwitchClause: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow fallthrough of switch clauses.
noFocusedTests
Optional
public readonly noFocusedTests: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow focused tests.
noFunctionAssign
Optional
public readonly noFunctionAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow reassigning function declarations.
noGlobalAssign
Optional
public readonly noGlobalAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow assignments to native objects and read-only global variables.
noGlobalIsFinite
Optional
public readonly noGlobalIsFinite: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use Number.isFinite instead of global isFinite.
noGlobalIsNan
Optional
public readonly noGlobalIsNan: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use Number.isNaN instead of global isNaN.
noImplicitAnyLet
Optional
public readonly noImplicitAnyLet: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow use of implicit any type on variable declarations.
noImportantInKeyframe
Optional
public readonly noImportantInKeyframe: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow invalid !important within keyframe declarations.
noImportAssign
Optional
public readonly noImportAssign: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow assigning to imported bindings.
noLabelVar
Optional
public readonly noLabelVar: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow labels that share a name with a variable.
noMisleadingCharacterClass
Optional
public readonly noMisleadingCharacterClass: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow characters made with multiple code points in character class syntax.
noMisleadingInstantiator
Optional
public readonly noMisleadingInstantiator: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce proper usage of new and constructor.
noMisplacedAssertion
Optional
public readonly noMisplacedAssertion: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Checks that the assertion function, for example expect, is placed inside an it() function call.
noMisrefactoredShorthandAssign
Optional
public readonly noMisrefactoredShorthandAssign: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow shorthand assign when variable appears on both sides.
noPrototypeBuiltins
Optional
public readonly noPrototypeBuiltins: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow direct use of Object.prototype builtins.
noReactSpecificProps
Optional
public readonly noReactSpecificProps: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevents React-specific JSX properties from being used.
noRedeclare
Optional
public readonly noRedeclare: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow variable, function, class, and type redeclarations in the same scope.
noRedundantUseStrict
Optional
public readonly noRedundantUseStrict: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Prevents from having redundant "use strict".
noSelfCompare
Optional
public readonly noSelfCompare: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow comparisons where both sides are exactly the same.
noShadowRestrictedNames
Optional
public readonly noShadowRestrictedNames: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow identifiers from shadowing restricted names.
noShorthandPropertyOverrides
Optional
public readonly noShorthandPropertyOverrides: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow shorthand properties that override related longhand properties.
noSkippedTests
Optional
public readonly noSkippedTests: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow disabled tests.
noSparseArray
Optional
public readonly noSparseArray: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow sparse arrays.
noSuspiciousSemicolonInJsx
Optional
public readonly noSuspiciousSemicolonInJsx: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
It detects possible "wrong" semicolons inside JSX elements.
noThenProperty
Optional
public readonly noThenProperty: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow then property.
noUnsafeDeclarationMerging
Optional
public readonly noUnsafeDeclarationMerging: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Disallow unsafe declaration merging between interfaces and classes.
noUnsafeNegation
Optional
public readonly noUnsafeNegation: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Disallow using unsafe negation.
recommended
Optional
public readonly recommended: boolean;
- Type: boolean
It enables the recommended rules for this group.
useAwait
Optional
public readonly useAwait: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Ensure async functions utilize await.
useDefaultSwitchClauseLast
Optional
public readonly useDefaultSwitchClauseLast: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce default clauses in switch statements to be last.
useErrorMessage
Optional
public readonly useErrorMessage: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce passing a message value when creating a built-in error.
useGetterReturn
Optional
public readonly useGetterReturn: string | IRuleWithNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithNoOptions
Enforce get methods to always return a value.
useIsArray
Optional
public readonly useIsArray: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Use Array.isArray() instead of instanceof Array.
useNamespaceKeyword
Optional
public readonly useNamespaceKeyword: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Require using the namespace keyword over the module keyword to declare TypeScript namespaces.
useNumberToFixedDigitsArgument
Optional
public readonly useNumberToFixedDigitsArgument: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
Enforce using the digits argument with Number#toFixed().
useValidTypeof
Optional
public readonly useValidTypeof: string | IRuleWithFixNoOptions;
- Type: string | projen.javascript.biomeConfig.IRuleWithFixNoOptions
This rule verifies the result of typeof $expr unary expressions is being compared to valid values, either string literals containing valid type names or other typeof expressions.
IUseComponentExportOnlyModulesOptions
- Implemented By: projen.javascript.biomeConfig.IUseComponentExportOnlyModulesOptions
Properties
Name | Type | Description |
---|---|---|
| boolean | Allows the export of constants. |
| string[] | A list of names that can be additionally exported from the module This option is for exports that do not hinder React Fast Refresh, such as meta in Remix. |
allowConstantExport
Optional
public readonly allowConstantExport: boolean;
- Type: boolean
Allows the export of constants.
This option is for environments that support it, such as Vite
allowExportNames
Optional
public readonly allowExportNames: string[];
- Type: string[]
A list of names that can be additionally exported from the module This option is for exports that do not hinder React Fast Refresh, such as meta
in Remix.
IUseExhaustiveDependenciesOptions
- Implemented By: projen.javascript.biomeConfig.IUseExhaustiveDependenciesOptions
Options for the rule useExhaustiveDependencies
.
Properties
Name | Type | Description |
---|---|---|
| projen.javascript.biomeConfig.IHook[] | List of hooks of which the dependencies should be validated. |
| boolean | Whether to report an error when a hook has no dependencies array. |
| boolean | Whether to report an error when a dependency is listed in the dependencies array but isn't used. |
hooks
Optional
public readonly hooks: IHook[];
- Type: projen.javascript.biomeConfig.IHook[]
List of hooks of which the dependencies should be validated.
reportMissingDependenciesArray
Optional
public readonly reportMissingDependenciesArray: boolean;
- Type: boolean
Whether to report an error when a hook has no dependencies array.
reportUnnecessaryDependencies
Optional
public readonly reportUnnecessaryDependencies: boolean;
- Type: boolean
Whether to report an error when a dependency is listed in the dependencies array but isn't used.
Defaults to true.
IUseImportExtensionsOptions
- Implemented By: projen.javascript.biomeConfig.IUseImportExtensionsOptions
Properties
Name | Type | Description |
---|---|---|
| {[ key: string ]: projen.javascript.biomeConfig.ISuggestedExtensionMapping} | A map of custom import extension mappings, where the key is the inspected file extension, and the value is a pair of module extension and component import extension. |
suggestedExtensions
Optional
public readonly suggestedExtensions: {[ key: string ]: ISuggestedExtensionMapping};
- Type: {[ key: string ]: projen.javascript.biomeConfig.ISuggestedExtensionMapping}
A map of custom import extension mappings, where the key is the inspected file extension, and the value is a pair of module
extension and component
import extension.
IUseValidAutocompleteOptions
- Implemented By: projen.javascript.biomeConfig.IUseValidAutocompleteOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | input like custom components that should be checked. |
inputComponents
Optional
public readonly inputComponents: string[];
- Type: string[]
input
like custom components that should be checked.
IUtilityClassSortingOptions
- Implemented By: projen.javascript.biomeConfig.IUtilityClassSortingOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | Additional attributes that will be sorted. |
| string[] | Names of the functions or tagged templates that will be sorted. |
attributes
Optional
public readonly attributes: string[];
- Type: string[]
Additional attributes that will be sorted.
functions
Optional
public readonly functions: string[];
- Type: string[]
Names of the functions or tagged templates that will be sorted.
IValidAriaRoleOptions
- Implemented By: projen.javascript.biomeConfig.IValidAriaRoleOptions
Properties
Name | Type | Description |
---|---|---|
| string[] | No description. |
| boolean | No description. |
allowInvalidRoles
Optional
public readonly allowInvalidRoles: string[];
- Type: string[]
ignoreNonDom
Optional
public readonly ignoreNonDom: boolean;
- Type: boolean
IVcsConfiguration
- Implemented By: projen.javascript.biomeConfig.IVcsConfiguration
Set of properties to integrate Biome with a VCS software.
Properties
Name | Type | Description |
---|---|---|
| string | The kind of client. |
| string | The main branch of the project. |
| boolean | Whether Biome should integrate itself with the VCS client. |
| string | The folder where Biome should check for VCS files. |
| boolean | Whether Biome should use the VCS ignore file. |