inspector/client
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Alex Andru 3a121bc8fc fix: support JSON Schema spec compliant oneOf with const for labeled enums
- Make JsonSchemaType.type optional to support const-only schemas
- Add JsonSchemaConst type for schema objects using const values
- Update oneOf/anyOf to accept both full schemas and const schemas
- Add comprehensive tests for oneOf with const and title patterns

This fixes TypeScript compilation errors when using the JSON Schema
specification's recommended approach for labeled enums:
{ "type": "string", "oneOf": [{ "const": "red", "title": "Stop" }] }

Replaces deprecated enumNames pattern with spec-compliant implementation.
2025-07-04 19:39:03 +02:00
..
bin refactor: use ES6 shorthand property syntax in start.js 2025-06-27 17:40:22 +01:00
e2e Cleanup client/e2e/test-results/ after test:e2e 2025-06-19 07:23:29 -07:00
public switch favicon 2024-11-19 14:13:19 -08:00
src fix: support JSON Schema spec compliant oneOf with const for labeled enums 2025-07-04 19:39:03 +02:00
.gitignore init client 2024-10-07 16:28:05 -07:00
components.json run prettier 2024-11-04 21:29:59 +00:00
eslint.config.js don't disable rules-of-hooks 2025-03-29 01:22:35 +05:30
index.html Full-width #root 2025-07-01 09:30:36 -07:00
jest.config.cjs Exclude e2e from Jest 2025-06-06 19:33:54 -07:00
package.json Merge branch 'origin/main' into feature/elicitations 2025-07-03 16:14:21 +02:00
playwright.config.ts prettier fix 2025-06-19 07:02:06 -07:00
postcss.config.js run prettier 2024-11-04 21:29:59 +00:00
README.md init client 2024-10-07 16:28:05 -07:00
tailwind.config.js Make tailwind config work on Windows 2024-11-26 16:51:50 +01:00
tsconfig.app.json Add jest-dom types 2025-03-23 13:22:31 -07:00
tsconfig.jest.json Handle edge case and add tests for functions 2025-02-27 06:40:01 -07:00
tsconfig.json init client 2024-10-07 16:28:05 -07:00
tsconfig.node.json init client 2024-10-07 16:28:05 -07:00
vite.config.ts Update Vite configuration to enable host access and fix proxy server URL to use the current hostname. 2025-03-20 22:04:59 +08:00

React + TypeScript + Vite

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Currently, two official plugins are available:

Expanding the ESLint configuration

If you are developing a production application, we recommend updating the configuration to enable type aware lint rules:

  • Configure the top-level parserOptions property like this:
export default tseslint.config({
  languageOptions: {
    // other options...
    parserOptions: {
      project: ["./tsconfig.node.json", "./tsconfig.app.json"],
      tsconfigRootDir: import.meta.dirname,
    },
  },
});
  • Replace tseslint.configs.recommended to tseslint.configs.recommendedTypeChecked or tseslint.configs.strictTypeChecked
  • Optionally add ...tseslint.configs.stylisticTypeChecked
  • Install eslint-plugin-react and update the config:
// eslint.config.js
import react from "eslint-plugin-react";

export default tseslint.config({
  // Set the react version
  settings: { react: { version: "18.3" } },
  plugins: {
    // Add the react plugin
    react,
  },
  rules: {
    // other rules...
    // Enable its recommended rules
    ...react.configs.recommended.rules,
    ...react.configs["jsx-runtime"].rules,
  },
});