diff --git a/packages/cli/src/commands/dev.ts b/packages/cli/src/commands/dev.ts index bf55eaa5..c98476b5 100644 --- a/packages/cli/src/commands/dev.ts +++ b/packages/cli/src/commands/dev.ts @@ -17,8 +17,8 @@ export async function dev(schemaPath: string, options: DevOptions) { const cwd = process.cwd(); // Resolve the actual project root and schema file - let projectRoot = cwd; - let targetSchemaPath = schemaPath; + let _projectRoot = cwd; + const targetSchemaPath = schemaPath; let hasPagesDir = false; let pagesDir = ''; let appConfig: unknown = null; @@ -33,7 +33,7 @@ export async function dev(schemaPath: string, options: DevOptions) { if (existsSync(potentialPagesDir)) { console.log(chalk.blue(`📂 Detected project structure at ${fileDir}`)); - projectRoot = fileDir; + _projectRoot = fileDir; hasPagesDir = true; pagesDir = potentialPagesDir; @@ -41,7 +41,7 @@ export async function dev(schemaPath: string, options: DevOptions) { try { appConfig = parseSchemaFile(absoluteSchemaPath); console.log(chalk.blue('⚙️ Loaded App Config from app.json')); - } catch (e) { + } catch (_e) { console.warn('Failed to parse app config'); } } @@ -170,7 +170,7 @@ export async function dev(schemaPath: string, options: DevOptions) { // We might get the cjs entry, but for aliasing usually fine. // Better yet, if we can find the package root, but require.resolve gives file. // Let's just use what require.resolve gives. - // @ts-ignore + // @ts-expect-error - lucidePath is dynamically resolved viteConfig.resolve.alias['lucide-react'] = lucidePath; } catch (e) { console.warn('⚠️ Could not resolve lucide-react automatically:', e); @@ -192,7 +192,7 @@ export async function dev(schemaPath: string, options: DevOptions) { ], }, }; - } catch (e) { + } catch (_e) { console.warn(chalk.yellow('⚠️ Failed to load PostCSS plugins from root node_modules. Styles might not work correctly.')); } } diff --git a/packages/plugin-kanban/src/index.tsx b/packages/plugin-kanban/src/index.tsx index 357e1491..bb5f51b3 100644 --- a/packages/plugin-kanban/src/index.tsx +++ b/packages/plugin-kanban/src/index.tsx @@ -52,7 +52,7 @@ export const KanbanRenderer: React.FC = ({ schema }) => { // Default: Return columns as-is (assuming they have 'cards' inside) return columns; - }, [schema.columns, schema.data, schema.groupBy]); + }, [schema]); return ( }> diff --git a/packages/react/src/SchemaRenderer.tsx b/packages/react/src/SchemaRenderer.tsx index cf518bd4..f004e2fd 100644 --- a/packages/react/src/SchemaRenderer.tsx +++ b/packages/react/src/SchemaRenderer.tsx @@ -1,12 +1,11 @@ import React, { forwardRef } from 'react'; import { SchemaNode, ComponentRegistry } from '@object-ui/core'; -export const SchemaRenderer = forwardRef>(({ schema, ...props }, ref) => { +export const SchemaRenderer = forwardRef>(({ schema, ...props }, _ref) => { if (!schema) return null; // If schema is just a string, render it as text if (typeof schema === 'string') return <>{schema}; - // eslint-disable-next-line const Component = ComponentRegistry.get(schema.type); if (!Component) { @@ -18,13 +17,14 @@ export const SchemaRenderer = forwardRef