mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-04 01:44:13 +00:00
style: format server and shared with prettier
A mechanical prettier --write over server/src, server/tests, server/scripts and shared/src with the workspaces' .prettierrc; nothing but layout and import order changes, and every file keeps the same set of imports. shared is formatted throughout and its format baseline is empty. The server baseline keeps the 35 files that Prettier would grow past their lint:size limit (they need a split first, which is not a formatting change), and the generated entity files stay as their generator writes them.
This commit is contained in:
@@ -6,12 +6,18 @@
|
||||
* settings, so each shape it meets in the real repositories has a pinned
|
||||
* sample (or a pinned reason it has none).
|
||||
*/
|
||||
import {
|
||||
planRepositories,
|
||||
readCompilerOptions,
|
||||
sampleString,
|
||||
type MethodPlan,
|
||||
} from '../../../../scripts/pg-probe/arg-samples';
|
||||
|
||||
import { mkdirSync, mkdtempSync, rmSync, writeFileSync } from 'node:fs';
|
||||
import { tmpdir } from 'node:os';
|
||||
import path from 'node:path';
|
||||
import ts from 'typescript';
|
||||
import { afterAll, beforeAll, describe, expect, it } from 'vitest';
|
||||
import { planRepositories, readCompilerOptions, sampleString, type MethodPlan } from '../../../../scripts/pg-probe/arg-samples';
|
||||
|
||||
const FIXTURE = `
|
||||
export interface NewThing {
|
||||
@@ -71,7 +77,11 @@ beforeAll(() => {
|
||||
// The server's own settings (non-strict: `string | null` is `string`), so
|
||||
// the fixture is sampled the way the real repositories are.
|
||||
const options = readCompilerOptions(path.join(__dirname, '../../../../tsconfig.json'));
|
||||
plans = planRepositories([path.join(root, 'src/Things.repository.ts')], { ...options, rootDir: root, paths: undefined, types: [] }, root);
|
||||
plans = planRepositories(
|
||||
[path.join(root, 'src/Things.repository.ts')],
|
||||
{ ...options, rootDir: root, paths: undefined, types: [] },
|
||||
root,
|
||||
);
|
||||
});
|
||||
|
||||
afterAll(() => {
|
||||
|
||||
Reference in New Issue
Block a user