Skip to content

Commit 2f88a93

Browse files
committed
pnpm biome check --write .
1 parent 3a035d6 commit 2f88a93

File tree

828 files changed

+9180
-11831
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

828 files changed

+9180
-11831
lines changed

.changeset/config.json

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
{
2-
"$schema": "https://unpkg.com/@changesets/config@2/schema.json",
3-
"changelog": ["@changesets/changelog-github", {"repo": "Khan/perseus"}],
4-
"commit": ["@changesets/cli/commit", { "skipCI": false }],
5-
"linked": [],
6-
"access": "public",
7-
"baseBranch": "main",
8-
"updateInternalDependencies": "patch",
9-
"ignore": [],
10-
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
11-
"updateInternalDependents": "always"
12-
}
2+
"$schema": "https://unpkg.com/@changesets/config@2/schema.json",
3+
"changelog": ["@changesets/changelog-github", { "repo": "Khan/perseus" }],
4+
"commit": ["@changesets/cli/commit", { "skipCI": false }],
5+
"linked": [],
6+
"access": "public",
7+
"baseBranch": "main",
8+
"updateInternalDependencies": "patch",
9+
"ignore": [],
10+
"___experimentalUnsafeOptions_WILL_CHANGE_IN_PATCH": {
11+
"updateInternalDependents": "always"
12+
}
1313
}

.devcontainer/devcontainer.json

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
22
// README at: https://github.com/devcontainers/templates/tree/main/src/typescript-node
33
{
4-
"name": "Node.js & TypeScript",
5-
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6-
"image": "mcr.microsoft.com/devcontainers/typescript-node:16",
4+
"name": "Node.js & TypeScript",
5+
// Or use a Dockerfile or Docker Compose file. More info: https://containers.dev/guide/dockerfile
6+
"image": "mcr.microsoft.com/devcontainers/typescript-node:16",
77

8-
// Features to add to the dev container. More info: https://containers.dev/features.
9-
// "features": {},
8+
// Features to add to the dev container. More info: https://containers.dev/features.
9+
// "features": {},
1010

11-
// Use 'forwardPorts' to make a list of ports inside the container available locally.
12-
"forwardPorts": [6006],
11+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
12+
"forwardPorts": [6006],
1313

14-
// Use 'postCreateCommand' to run commands after the container is created.
15-
"postCreateCommand": "pnpm install"
14+
// Use 'postCreateCommand' to run commands after the container is created.
15+
"postCreateCommand": "pnpm install"
1616

17-
// Configure tool-specific properties.
18-
// "customizations": {},
17+
// Configure tool-specific properties.
18+
// "customizations": {},
1919

20-
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
21-
// "remoteUser": "root"
20+
// Uncomment to connect as root instead. More info: https://aka.ms/dev-containers-non-root.
21+
// "remoteUser": "root"
2222
}

.nycrc.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,5 @@
66
"packages/*/src/**/*.ts",
77
"packages/*/src/**/*.tsx"
88
],
9-
"exclude": [
10-
"**/*.stories.tsx",
11-
"**/*.test.ts",
12-
"**/*.test.tsx"
13-
]
14-
}
9+
"exclude": ["**/*.stories.tsx", "**/*.test.ts", "**/*.test.tsx"]
10+
}

.storybook/main.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
import viteConfig from "../vite.config";
2-
import {mergeConfig} from "vite";
3-
41
import type {StorybookConfig} from "@storybook/react-vite";
2+
import {mergeConfig} from "vite";
3+
import viteConfig from "../vite.config";
54

65
// This is a temporary plugin option to mimic what is in PROD in regard to cascade layers.
76
// Perseus LESS files are wrapped in the 'shared' layer in Webapp.

.storybook/preview.tsx

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
import * as React from "react";
2-
import {color} from "@khanacademy/wonder-blocks-tokens";
31
import {RenderStateRoot} from "@khanacademy/wonder-blocks-core";
4-
2+
import {color} from "@khanacademy/wonder-blocks-tokens";
3+
import type {Preview} from "@storybook/react";
4+
import * as React from "react";
55
import {
6-
setDependencies,
76
DependenciesContext,
7+
setDependencies,
88
} from "../packages/perseus/src/dependencies";
99
import {
10-
storybookTestDependencies,
1110
storybookDependenciesV2,
11+
storybookTestDependencies,
1212
} from "../testing/test-dependencies";
1313

14-
import type {Preview} from "@storybook/react";
15-
1614
// IMPORTANT: This code runs ONCE per story file, not per story within that file.
1715
// If you want code to run once per story, see `StorybookWrapper`.
1816

biome.jsonc

Lines changed: 32 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,58 +1,64 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/1.9.4/schema.json",
2+
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
33
"files": {
44
"ignoreUnknown": false,
5-
"ignore": [
6-
"data/questions/",
7-
"__genfiles__/",
8-
"dist/",
9-
"vendor/",
10-
"storybook-static/",
11-
"styles/khan-exercise.css"
12-
]
5+
"includes": [
6+
"**",
7+
"!data/questions",
8+
"!**/__genfiles__",
9+
"!dist/",
10+
"!vendor",
11+
"!storybook-static",
12+
],
1313
},
1414
"vcs": {
15+
"enabled": true,
1516
"clientKind": "git",
16-
"useIgnoreFile": true
17+
"useIgnoreFile": true,
1718
},
1819
"formatter": {
1920
"enabled": true,
20-
"useEditorconfig": true
21-
},
22-
"organizeImports": {
23-
"enabled": false
21+
"useEditorconfig": true,
2422
},
2523
"linter": {
2624
"enabled": false,
2725
"rules": {
28-
"recommended": true
29-
}
26+
"recommended": true,
27+
},
28+
},
29+
"assist": {
30+
"actions": {
31+
"source": {
32+
"organizeImports": "on",
33+
},
34+
},
3035
},
3136
"javascript": {
3237
"formatter": {
3338
"quoteStyle": "double",
3439
"trailingCommas": "all",
3540

36-
"bracketSpacing": false
37-
}
41+
"bracketSpacing": false,
42+
},
3843
},
3944
"overrides": [
4045
{
41-
"include": [
46+
"includes": [
4247
"tsconfig-build.json",
4348
"tsconfig-common.json",
4449
"tsconfig-shared.json",
45-
"tsconfig.json"
50+
"tsconfig.json",
51+
"biome.jsonc",
4652
],
4753
"json": {
4854
"formatter": {
49-
"trailingCommas": "all"
55+
"trailingCommas": "all",
5056
},
5157
"parser": {
58+
"allowComments": true,
5259
"allowTrailingCommas": true,
53-
"allowComments": true
54-
}
55-
}
56-
}
57-
]
60+
},
61+
},
62+
},
63+
],
5864
}

config/build/rollup.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
/* eslint-disable import/no-commonjs */
2-
import fs from "fs";
3-
import path from "path";
42

53
import alias from "@rollup/plugin-alias";
64
import {babel} from "@rollup/plugin-babel";
75
import commonjs from "@rollup/plugin-commonjs";
86
import resolve from "@rollup/plugin-node-resolve";
97
import replace from "@rollup/plugin-replace";
108
import ancesdir from "ancesdir";
9+
import fs from "fs";
10+
import path from "path";
1111
import autoExternal from "rollup-plugin-auto-external";
1212
import filesize from "rollup-plugin-filesize";
1313
import styles from "rollup-plugin-styles";

config/cypress/cypress.config.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
1+
import {defineConfig} from "cypress";
12
import fs from "fs";
23
import path from "path";
34
import {mergeConfig} from "vite";
45
import istanbul from "vite-plugin-istanbul";
5-
6-
import {defineConfig} from "cypress";
76
import viteConfig from "../../vite.config";
87

98
const aliases = {};

data/find-questions.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,10 @@
77
* - run: ./find-questions.js
88
*/
99

10+
import type {PerseusRenderer} from "@khanacademy/perseus-core";
1011
import fs from "fs";
1112
import path from "path";
1213

13-
import type {PerseusRenderer} from "@khanacademy/perseus-core";
14-
1514
// ==========================
1615
// MODIFY THIS WHEN SEARCHING
1716
// ==========================

dev/editable-controlled-input.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,7 @@
1+
import type {PropsFor} from "@khanacademy/wonder-blocks-core";
12
import * as React from "react";
23
import {useState} from "react";
34

4-
import type {PropsFor} from "@khanacademy/wonder-blocks-core";
5-
65
type Props = Omit<PropsFor<"input">, "value" | "onInput"> & {
76
value: string;
87
onInput: (newValue: string) => unknown;

0 commit comments

Comments
 (0)