61609de97e
* feat(preview-generator): add new preview generator webapp * wip(preview-service): reworking the preview service backend * feat(previews): logging * feat(preview-service): streamline payloads * fix(preview-service): do not log the full payload * feat(preview-service): build new preview service * feat(preview-service): add separate response queue * feat(previews): integrate preview queues with the server * feat(previews): use module alias * chore(previews): remove old preview service code * feat(previews): log stuff on job statuses * fix(previews): add missing deps and scripts * fix(previews): package deps fix * fix(server): moar typing fixes * Metrics related to jobs: total count, request failures, response errors & durations * duration should include unit. - histogram metric should be summary - error responses include duration in seconds - attempt to remove metric before adding it (prevent errors with duplicate metrics) * fix(server, frontend): some ts fixes * fixes * fix(frontend): remove unneeded ts-expect-error * chore(preview-service): eslint * TS fix * feat(previews): more smoal fixes * fix(preview-service): alias loading * feat(helm): updates for new preview service queue setup * feat(preview-service): launch new browser for each job * feat(preview-service): add timeout, fix liveliness * fix(helm): add access to new secret in service accounts * tidy metrics into a separate file * Remove broken preview service acceptance test * fix broken import * Add metrics to test * feat(preview-service): handle preview service shutdown properly * fix(previews): merge bork --------- Co-authored-by: Iain Sproat <68657+iainsproat@users.noreply.github.com> Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
62 lines
1.5 KiB
JavaScript
62 lines
1.5 KiB
JavaScript
import { baseConfigs, globals, getESMDirname } from '../../eslint.config.mjs'
|
|
import tseslint from 'typescript-eslint'
|
|
|
|
/**
|
|
* @type {Array<import('eslint').Linter.FlatConfig>}
|
|
*/
|
|
const configs = [
|
|
...baseConfigs,
|
|
{
|
|
files: ['**/*.js'],
|
|
languageOptions: {
|
|
sourceType: 'module'
|
|
}
|
|
},
|
|
{
|
|
files: ['*.{js,cjs,mjs,ts}'],
|
|
languageOptions: {
|
|
globals: {
|
|
...globals.node
|
|
}
|
|
}
|
|
},
|
|
{
|
|
files: ['**/*.src'],
|
|
languageOptions: {
|
|
globals: {
|
|
...globals.browser
|
|
}
|
|
}
|
|
},
|
|
...tseslint.configs.recommendedTypeChecked.map((c) => ({
|
|
...c,
|
|
files: [...(c.files || []), '**/*.ts', '**/*.d.ts']
|
|
})),
|
|
{
|
|
files: ['**/*.ts', '**/*.d.ts'],
|
|
languageOptions: {
|
|
parserOptions: {
|
|
tsconfigRootDir: getESMDirname(import.meta.url),
|
|
project: './tsconfig.json'
|
|
}
|
|
},
|
|
rules: {
|
|
'@typescript-eslint/no-unused-vars': 'off',
|
|
'@typescript-eslint/no-non-null-assertion': 'error',
|
|
'@typescript-eslint/no-base-to-string': 'off', // too restrictive
|
|
'@typescript-eslint/restrict-template-expressions': 'off', // too restrictive
|
|
'@typescript-eslint/no-unsafe-enum-comparison': 'off', // too restrictive
|
|
'@typescript-eslint/require-await': 'off', // too restrictive
|
|
'@typescript-eslint/unbound-method': 'off', // too restrictive
|
|
'@typescript-eslint/no-misused-promises': 'off'
|
|
}
|
|
},
|
|
{
|
|
rules: {
|
|
'no-console': 'off'
|
|
}
|
|
}
|
|
]
|
|
|
|
export default configs
|