Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 30 additions & 1 deletion eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,13 @@ export default [
'no-await-in-loop': 'warn',
'@typescript-eslint/no-unused-vars': 'warn',
'@typescript-eslint/consistent-type-definitions': 'warn',
'@typescript-eslint/ban-types': 'warn',
// Using rules compatible with @typescript-eslint v7 (from @scaleway/eslint-config-react)
'@typescript-eslint/no-explicit-any': 'warn',
'@typescript-eslint/no-empty-interface': 'warn',
'@typescript-eslint/no-unsafe-assignment': 'warn',
'@typescript-eslint/no-unsafe-call': 'warn',
'@typescript-eslint/no-unsafe-member-access': 'warn',
'@typescript-eslint/no-unsafe-return': 'warn',
},
})),

Expand Down Expand Up @@ -115,4 +121,27 @@ export default [
'no-restricted-syntax': 'off',
},
})),

// Exclude all generated packages from strict type rules
...scwTypescript.map(config => ({
...config,
files: [
'packages_generated/**/*.ts',
],
rules: {
...config.rules,
'@typescript-eslint/consistent-type-definitions': 'off',
'@typescript-eslint/no-unsafe-assignment': 'off',
'@typescript-eslint/no-unsafe-call': 'off',
'@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-return': 'off',
'@typescript-eslint/ban-types': 'off',
'@typescript-eslint/no-unused-vars': 'off',
'@typescript-eslint/no-use-before-define': 'off',
'no-restricted-syntax': 'off',
'no-useless-escape': 'off',
'no-underscore-dangle': 'off',
'max-classes-per-file': 'off',
},
})),
]
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@
"@commitlint/cli": "19.8.1",
"@commitlint/config-conventional": "19.8.1",
"@manypkg/cli": "0.24.0",
"@scaleway/eslint-config-react": "4.0.9",
"@scaleway/eslint-config-react": "5.2.10",
"@typescript-eslint/eslint-plugin": "8.40.0",
"@typescript-eslint/parser": "8.40.0",
"@vitest/coverage-istanbul": "3.1.2",
Expand Down
2 changes: 0 additions & 2 deletions packages/client/src/scw/locality.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/* eslint-disable @typescript-eslint/ban-types */
export type Region = 'fr-par' | 'nl-ams' | 'pl-waw' | (string & {})

export type Zone =
Expand All @@ -12,7 +11,6 @@ export type Zone =
| 'pl-waw-2'
| 'pl-waw-3'
| (string & {})
/* eslint-enable @typescript-eslint/ban-types */

export type ApiLocality =
| { type: 'zone'; zones: Zone[] }
Expand Down
4 changes: 2 additions & 2 deletions packages/configuration-loader/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* @public
*/
export type Profile = {
export interface Profile {
/**
* You need an access key and a secret key to connect to Scaleway API.
* Generate your token at the following address: {@link https://console.scaleway.com/project/credentials}
Expand Down Expand Up @@ -48,7 +48,7 @@ export type Profile = {
/** Configuration type. */
export type ConfigurationType = Record<string, Record<string, string>>
/** Parameters to load the all the profiles from the configuration file */
export type AllProfilesFromFileParams = {
export interface AllProfilesFromFileParams {
/**
* The path at which to locate the configuration file.
*
Expand Down
Loading
Loading