Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions packages/core/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -479,11 +479,11 @@ export interface RuleTextEdit {
* @param fixer The text editor to apply the fix.
* @returns The fix(es) for the violation.
*/
type RuleFixer = (
export type RuleFixer = (
fixer: RuleTextEditor,
) => RuleTextEdit | Iterable<RuleTextEdit> | null;

interface ViolationReportBase {
export interface ViolationReportBase {
/**
* The data to insert into the message.
*/
Expand All @@ -501,10 +501,10 @@ interface ViolationReportBase {
suggest?: SuggestedEdit[] | null | undefined;
}

type ViolationMessage<MessageIds = string> =
export type ViolationMessage<MessageIds = string> =
| { message: string }
| { messageId: MessageIds };
type ViolationLocation<Node> =
export type ViolationLocation<Node> =
| { loc: SourceLocation | Position }
| { node: Node };

Expand All @@ -517,7 +517,7 @@ export type ViolationReport<

// #region Suggestions

interface SuggestedEditBase {
export interface SuggestedEditBase {
/**
* The data to insert into the message.
*/
Expand All @@ -529,7 +529,7 @@ interface SuggestedEditBase {
fix: RuleFixer;
}

type SuggestionMessage = { desc: string } | { messageId: string };
export type SuggestionMessage = { desc: string } | { messageId: string };

/**
* A suggested edit for a rule violation.
Expand All @@ -539,7 +539,7 @@ export type SuggestedEdit = SuggestedEditBase & SuggestionMessage;
/**
* The normalized version of a lint suggestion.
*/
interface LintSuggestion {
export interface LintSuggestion {
/** A short description. */
desc: string;

Expand Down Expand Up @@ -904,7 +904,7 @@ export type EcmaVersion =
* The type of JavaScript source code.
* @deprecated Only supported in legacy eslintrc config format.
*/
type JavaScriptSourceType = "script" | "module" | "commonjs";
export type JavaScriptSourceType = "script" | "module" | "commonjs";

/**
* Parser options.
Expand Down Expand Up @@ -974,7 +974,7 @@ export interface EnvironmentConfig {
/**
* A configuration object that may have a `rules` block.
*/
interface HasRules<Rules extends RulesConfig = RulesConfig> {
export interface HasRules<Rules extends RulesConfig = RulesConfig> {
rules?: Partial<Rules> | undefined;
}

Expand All @@ -983,7 +983,7 @@ interface HasRules<Rules extends RulesConfig = RulesConfig> {
*
* @see [ESLint Legacy Configuration](https://eslint.org/docs/latest/use/configure/)
*/
interface BaseConfig<
export interface BaseConfig<
Rules extends RulesConfig = RulesConfig,
OverrideRules extends RulesConfig = Rules,
> extends HasRules<Rules> {
Expand Down