eslintrc-tsnocheck

This commit is contained in:
Kagami Sascha Rosylight 2023-07-31 03:56:33 +02:00
parent fa03f61529
commit 2d3269273f
9 changed files with 50 additions and 7 deletions

View file

@ -62,6 +62,7 @@ jobs:
matrix:
workspace:
- backend
- frontend
- misskey-js
steps:
- uses: actions/checkout@v3.3.0

View file

@ -0,0 +1,10 @@
// Split from .eslintrc, so that the default eslintrc can still show error for ts-nocheck
module.exports = {
root: true,
extends: [
'./.eslintrc.cjs',
],
rules: {
'@typescript-eslint/ban-ts-comment': ['error', { 'ts-nocheck': false }]
}
};

View file

@ -70,6 +70,7 @@ export function userDetailed(id = 'someuserid', username = 'miskist', host = 'mi
avatarUrl: 'https://github.com/misskey-dev/misskey/blob/master/packages/frontend/assets/about-icon.png?raw=true',
avatarBlurhash: 'eQFRshof5NWBRi},juayfPju53WB?0ofs;s*a{ofjuay^SoMEJR%ay',
emojis: [],
alsoKnownAs: [],
bannerBlurhash: 'eQA^IW^-MH8w9tE8I=S^o{$*R4RikXtSxutRozjEnNR.RQadoyozog',
bannerColor: '#000000',
bannerUrl: 'https://github.com/misskey-dev/misskey/blob/master/packages/frontend/assets/fedi.jpg?raw=true',
@ -102,6 +103,7 @@ export function userDetailed(id = 'someuserid', username = 'miskist', host = 'mi
isSuspended: false,
lang: 'en',
location: 'Fediverse',
movedTo: null,
notesCount: 65536,
pinnedNoteIds: [],
pinnedNotes: [],

View file

@ -258,6 +258,7 @@ export function unwindCssModuleClassName(ast: estree.Node): void {
type: 'ArrayExpression',
elements: node.declarations[0].init.arguments[1].elements.slice(0, __cssModulesIndex).concat(node.declarations[0].init.arguments[1].elements.slice(__cssModulesIndex + 1)),
}],
optional: false,
},
}],
kind: 'const',

View file

@ -12,7 +12,8 @@
"test-and-coverage": "vitest --run --coverage",
"typecheck": "vue-tsc --noEmit",
"eslint": "eslint --quiet \"src/**/*.{ts,vue}\"",
"lint": "pnpm typecheck && pnpm eslint"
"lint-full": "pnpm typecheck && pnpm eslint",
"lint": "pnpm typecheck && pnpm eslint -c .eslintrc-tsnocheck.cjs"
},
"dependencies": {
"@discordapp/twemoji": "14.1.2",

View file

@ -19,7 +19,6 @@
"experimentalDecorators": true,
"resolveJsonModule": true,
"allowSyntheticDefaultImports": true,
"isolatedModules": true,
"useDefineForClassFields": true,
"baseUrl": ".",
"paths": {
@ -37,7 +36,8 @@
"esnext",
"dom"
],
"jsx": "preserve"
"jsx": "preserve",
"skipLibCheck": true
},
"compileOnSave": false,
"include": [
@ -46,6 +46,8 @@
"./**/*.vue"
],
"exclude": [
".storybook/**/*"
".storybook/**/*",
"lib/**/*",
"test/**/*"
]
}

View file

@ -2254,7 +2254,8 @@ declare namespace entities {
Invite,
InviteLimit,
UserSorting,
OriginType
OriginType,
Role
}
}
export { entities }
@ -2651,6 +2652,18 @@ type PageEvent = {
// @public (undocumented)
export const permissions: string[];
// @public (undocumented)
type Role = {
id: string;
name: string;
color: string | null;
iconUrl: string | null;
description: string;
isModerator: boolean;
isAdministrator: boolean;
displayOrder: number;
};
// @public (undocumented)
type ServerInfo = {
machine: string;
@ -2762,7 +2775,7 @@ type UserDetailed = UserLite & {
lang: string | null;
lastFetchedAt?: DateString;
location: string | null;
movedTo: string;
movedTo: string | null;
notesCount: number;
pinnedNoteIds: ID[];
pinnedNotes: Note[];
@ -2770,6 +2783,7 @@ type UserDetailed = UserLite & {
pinnedPageId: string | null;
publicReactions: boolean;
securityKeys: boolean;
roles: Role[];
twoFactorEnabled: boolean;
updatedAt: DateString | null;
uri: string | null;

View file

@ -57,7 +57,7 @@ export type UserDetailed = UserLite & {
lang: string | null;
lastFetchedAt?: DateString;
location: string | null;
movedTo: string;
movedTo: string | null;
notesCount: number;
pinnedNoteIds: ID[];
pinnedNotes: Note[];
@ -65,6 +65,7 @@ export type UserDetailed = UserLite & {
pinnedPageId: string | null;
publicReactions: boolean;
securityKeys: boolean;
roles: Role[],
twoFactorEnabled: boolean;
updatedAt: DateString | null;
uri: string | null;
@ -546,3 +547,14 @@ export type UserSorting =
| '+updatedAt'
| '-updatedAt';
export type OriginType = 'combined' | 'local' | 'remote';
export type Role = {
id: string;
name: string;
color: string | null;
iconUrl: string | null;
description: string;
isModerator: boolean;
isAdministrator: boolean;
displayOrder: number;
}