Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
40221d4
feat: add eslint 10 support
marufrasully Mar 19, 2026
22032ad
fix: add eslint 10 for rest of modules
marufrasully Mar 19, 2026
9e163b4
Merge remote-tracking branch 'origin/main' into feat/support-eslint-10
marufrasully Mar 19, 2026
c538935
fix: remove deprecated property
marufrasully Mar 19, 2026
1e75560
Merge remote-tracking branch 'origin/main' into feat/support-eslint-10
marufrasully Mar 19, 2026
54a0a83
fix: add change set
marufrasully Mar 19, 2026
8ca1b12
Linting auto fix commit
github-actions[bot] Mar 19, 2026
d415f65
fix Jest 30 Enzyme compatibility by resolving Cheerio exports and req…
marufrasully Mar 19, 2026
92692b4
fix: failing test
marufrasully Mar 19, 2026
41775f8
Merge remote-tracking branch 'origin/feat/support-eslint-10' into fea…
marufrasully Mar 19, 2026
d2b3f1f
fix: failing test and review comment
marufrasully Mar 20, 2026
f6dd86b
Merge remote-tracking branch 'origin/main' into feat/support-eslint-10
marufrasully Mar 20, 2026
5651d53
chore: merge main into feat/support-eslint-10 and resolve conflicts
longieirl Apr 15, 2026
148c96c
chore: merge origin/main into feat/support-eslint-10 (batch 2)
longieirl Apr 15, 2026
0007546
chore: merge origin/main into feat/support-eslint-10
longieirl Apr 15, 2026
f03c984
chore: update pnpm-lock.yaml after merging main into feat/support-esl…
longieirl Apr 15, 2026
e6a4b2e
chore: remove WIP files that don't belong on this branch
longieirl Apr 15, 2026
22965b4
chore: consolidate eslint-10 changesets
longieirl Apr 15, 2026
8b07afa
fix(ui-components): resolve cheerio/lib/utils to physical pnpm path f…
longieirl Apr 15, 2026
4149bc0
test: improve coverage for eslint-10 migration changes
longieirl Apr 15, 2026
0691ed9
Merge branch 'main' into feat/support-eslint-10
longieirl Apr 15, 2026
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
9 changes: 9 additions & 0 deletions .changeset/fair-adults-cheat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
---
'@sap-ux/eslint-plugin-fiori-tools': major
'@sap-ux/app-config-writer': patch
'@sap-ux/ui5-application-writer': patch
'@sap-ux/ui5-library-writer': patch
'@sap-ux-private/preview-middleware-client': patch
---

feat: support ESLint 10
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20.20.0
1 change: 1 addition & 0 deletions examples/ui-prompting-examples/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
"babel-loader": "10.1.1",
"copyfiles": "2.4.1",
"css-loader": "7.1.4",
"eslint": "9.39.1",
"eslint-plugin-react": "7.37.5",
"eslint-plugin-storybook": "0.6.15",
"mem-fs": "2.1.0",
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@
"devDependencies": {
"@changesets/cli": "2.30.0",
"@eslint/eslintrc": "3.3.5",
"@eslint/js": "9.22.0",
"@eslint/js": "10.0.1",
"@playwright/test": "1.58.2",
"@types/jest": "30.0.0",
"@types/node": "20.19.37",
"autoprefixer": "10.4.27",
"check-dependency-version-consistency": "6.0.0",
"esbuild": "0.27.4",
"esbuild-sass-plugin": "3.7.0",
"eslint": "9.39.1",
"eslint": "10.0.3",
"eslint-config-prettier": "10.1.8",
"eslint-import-resolver-typescript": "4.4.4",
"eslint-plugin-import": "2.32.0",
Expand Down
4 changes: 2 additions & 2 deletions packages/app-config-writer/src/eslint-config/convert.ts
Original file line number Diff line number Diff line change
Expand Up @@ -369,8 +369,8 @@ async function updatePackageJson(basePath: string, fs: Editor, logger?: ToolsLog
const packageJsonPath = join(basePath, FileName.Package);
const packageJson = fs.readJSON(packageJsonPath) as Package;
packageJson.devDependencies ??= {};
packageJson.devDependencies[packageName.ESLINT] = '^9.0.0';
packageJson.devDependencies[packageName.ESLINT_PLUGIN_FIORI_TOOLS] = '^9.0.0';
packageJson.devDependencies[packageName.ESLINT] = '^10.0.0';
packageJson.devDependencies[packageName.ESLINT_PLUGIN_FIORI_TOOLS] = '^10.0.0';
delete packageJson.devDependencies[packageName.ESLINT_PLUGIN_FIORI_CUSTOM];
packageJson.scripts ??= {};
if (packageJson.scripts['lint']) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,8 @@ describe('generateEslintConfig', () => {
const packageJson = fs.readJSON(packageJsonPath) as Package;

expect(packageJson.devDependencies).toBeDefined();
expect(packageJson.devDependencies?.eslint).toBe('^9');
expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^9.0.0');
expect(packageJson.devDependencies?.eslint).toBe('^10');
expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^10.0.0');
});

test('should add lint script to package.json', async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ describe('convertEslintConfig', () => {
const packageJsonPath = join(basePath, 'package.json');
const packageJson = fs.readJSON(packageJsonPath) as Package;

expect(packageJson.devDependencies?.eslint).toBe('^9.0.0');
expect(packageJson.devDependencies?.eslint).toBe('^10.0.0');
});

test('should update @sap-ux/eslint-plugin-fiori-tools version to ^9.0.0', async () => {
Expand All @@ -620,7 +620,7 @@ describe('convertEslintConfig', () => {
const packageJsonPath = join(basePath, 'package.json');
const packageJson = fs.readJSON(packageJsonPath) as Package;

expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^9.0.0');
expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^10.0.0');
});

test('should preserve existing devDependencies', async () => {
Expand Down Expand Up @@ -660,7 +660,7 @@ describe('convertEslintConfig', () => {

const updatedPackageJson = fs.readJSON(packageJsonPath) as Package;
expect(updatedPackageJson.devDependencies).toBeDefined();
expect(updatedPackageJson.devDependencies?.eslint).toBe('^9.0.0');
expect(updatedPackageJson.devDependencies?.eslint).toBe('^10.0.0');
});
});

Expand Down Expand Up @@ -762,8 +762,8 @@ describe('convertEslintConfig', () => {
// Verify package.json was updated
const packageJsonPath = join(basePath, 'package.json');
const packageJson = fs.readJSON(packageJsonPath) as Package;
expect(packageJson.devDependencies?.eslint).toBe('^9.0.0');
expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^9.0.0');
expect(packageJson.devDependencies?.eslint).toBe('^10.0.0');
expect(packageJson.devDependencies?.['@sap-ux/eslint-plugin-fiori-tools']).toBe('^10.0.0');

// Verify result is the fs instance
expect(result).toBe(fs);
Expand Down
1 change: 1 addition & 0 deletions packages/control-property-editor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
"@types/remote-redux-devtools": "0.5.8",
"@types/source-map-support": "0.5.10",
"@types/react": "16.14.69",
"eslint": "9.39.1",
"eslint-plugin-react": "7.37.5",
"http-proxy-middleware": "3.0.5",
"i18next": "25.10.10",
Expand Down
15 changes: 8 additions & 7 deletions packages/eslint-plugin-fiori-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,18 @@
"cross-env": "10.1.0",
"eslint": "9.39.1",
"@typescript-eslint/rule-tester": "8.57.2",
"eslint-plugin-eslint-plugin": "7.3.2"
"eslint-plugin-eslint-plugin": "7.3.2",
"@types/semver": "7.7.1"
},
"dependencies": {
"@babel/core": "7.29.0",
"@babel/eslint-parser": "^7.28.5",
"@eslint/js": "9.22.0",
"@eslint/js": "10.0.1",
"@eslint/json": "0.14.0",
"@eslint/core": "0.17.0",
"@eslint/core": "1.1.1",
"@eslint/config-helpers": "0.5.3",
"@typescript-eslint/eslint-plugin": ">=8.57.2",
"@typescript-eslint/parser": ">=8.57.2",
"@typescript-eslint/eslint-plugin": "8.57.2",
"@typescript-eslint/parser": "8.57.2",
"@sap-ux/fiori-annotation-api": "workspace:*",
"@sap-ux/odata-annotation-core": "workspace:*",
"@sap-ux/odata-vocabularies": "workspace:*",
Expand All @@ -47,7 +48,7 @@
"@xml-tools/ast": "5.0.5",
"@xml-tools/parser": "1.0.11",
"@humanwhocodes/momoa": "^3.3.9",
"@eslint/plugin-kit": "0.5.0",
"@eslint/plugin-kit": "0.6.1",
"globals": "17.4.0",
"lodash": "4.18.1",
"requireindex": "^1.2.0",
Expand All @@ -56,7 +57,7 @@
"semver": "7.7.4"
},
"peerDependencies": {
"eslint": "^9",
"eslint": ">=9",
"typescript-eslint": "^8.57.2",
"@types/semver": "7.7.1"
},
Expand Down
8 changes: 5 additions & 3 deletions packages/eslint-plugin-fiori-tools/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ export const languages = {
fiori: new FioriLanguage()
};

const fioriRules = rules as Plugin['rules'];

/**
* Default export following ESLint 9 plugin structure.
* This is the recommended way to export plugins in ESLint 9.
Expand All @@ -52,7 +54,7 @@ const plugin: Plugin = {
namespace: '@sap-ux/fiori-tools'
},
languages,
rules: rules as Plugin['rules'],
rules: fioriRules,
processors: {}
};

Expand Down Expand Up @@ -493,7 +495,7 @@ export const configs: Record<string, Linter.Config[]> = {
plugins: {
'@sap-ux/fiori-tools': {
meta,
rules: rules as Plugin['rules']
rules: fioriRules
}
}
},
Expand All @@ -507,7 +509,7 @@ export const configs: Record<string, Linter.Config[]> = {
'@sap-ux/fiori-tools': {
meta,
languages,
rules: rules as Plugin['rules']
rules: fioriRules
}
}
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions, RuleVisitor } from '@eslint/core';
import type { RuleVisitor } from '@eslint/core';
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions } from '@eslint/plugin-kit';

import type { FioriAnnotationSourceCode } from './source-code';
import type { AnyNode } from '@sap-ux/odata-annotation-core';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions, RuleVisitor } from '@eslint/core';
import type { RuleVisitor } from '@eslint/core';
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions } from '@eslint/plugin-kit';
import type { JSONLanguageOptions } from '@eslint/json';
import type { AnyNode } from '@humanwhocodes/momoa';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions, RuleVisitor } from '@eslint/core';
import type { RuleVisitor } from '@eslint/core';
import type { CustomRuleDefinitionType, CustomRuleTypeDefinitions } from '@eslint/plugin-kit';
import type { XMLAstNode, XMLToken } from '@xml-tools/ast';

import type { FioriXMLSourceCode } from './source-code';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
parseIdentifier,
toFullyQualifiedName
} from '@sap-ux/odata-annotation-core';
import type { ServiceArtifacts } from '@sap-ux/fiori-annotation-api/src/types';
import type { ServiceArtifacts } from '@sap-ux/fiori-annotation-api';

import type { DocumentType } from '../types';

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'disallow global variable declarations',
category: 'Best Practices',
recommended: true
},
fixable: undefined,
Expand All @@ -48,7 +47,7 @@ const rule: Rule.RuleModule = {

return {
VariableDeclaration(node: ASTNode) {
const sourceCode = context.sourceCode ?? context.getSourceCode();
const sourceCode = context.sourceCode;
const scope: Scope.Scope = sourceCode.getScope
? sourceCode.getScope(node)
: (context as any).getScope();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ const rule: Rule.RuleModule = {
type: 'problem',
docs: {
description: 'fiori tools (fiori custom) ESLint rule',
category: 'Best Practices',
recommended: false
},
messages: {
Expand Down
Loading
Loading