MCPcopy Index your code
hub / github.com/cardbox/frontend

github.com/cardbox/frontend @v0.0.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.0.1 ↗ · + Follow
213 symbols 566 edges 137 files 7 documented · 3%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Cardbox Frontend

code style: prettier Commitizen friendly Conventional Commits

Get Started

  1. Clone repository

  2. Prepare local certificate authorithy

    Setup via mkcert:

    bash mkcert -install

    Then generate your personal local certificates for cardbox:

    bash yarn prepare:certs

  3. Setup local env for development

    Copy from .env.sample file and make sure the default settings are correct

    ```properties

    Change some if you need

    RAZZLE_SESSION_TOKEN=XXXXXX CLIENT_PUBLIC_PATH=https://localhost:9101/ PORT=9100 BACKEND_URL=https://cardbox.sova.dev/api/internal ```

  4. Install and run:

    bash yarn install yarn start

Other commands

yarn api     # update api by codegen
yarn lint    # lint project with fix

Development

HotReload

Sometime you should manually restart server for new changes

# Just type and press ENTER:
rs

Effector

  • Use import {} from "effector-root" instead of "effector". All units should be created in the root domain.
  • Use import { debug } from "patronum" for debug effector units

Structure

Project designed by FeatureSliced

WIP: Project is migrating from FSv1 to FSv2

app

  • src/app/application.tsx — Application component, that have global styles and effector provider
  • src/app/server.tsx — Express server, that renders React to stream
  • src/app/client.tsx — Browser side entry point, that hydrates stores and react app
  • src/index.tsx — Node.js entry point, that have hot module replacement and imports server

pages

  • src/pages/index.tsx — Pages component
  • src/pages/routes.ts — Static routes config
  • src/pages/:page-name/index.tsx — View for single specific page
  • src/pages/:page-name/model.ts — Business-logic for specific page, that contains single level logic layer

shared

WIP: soon will be placed at src/shared

  • src/lib — Internal libraries
  • src/ui — Internal UIKit
  • src/lib/effector — START event name to use as page property

Extension points exported contracts — how you extend this code

Describer (Interface)
(no doc)
src/pages/comments/index.tsx
Props (Interface)
(no doc)
src/features/card/draft/ui/molecules/index.tsx
Named (Interface)
(no doc)
src/entities/user/lib.ts
Props (Interface)
(no doc)
src/app/application.tsx
StartParams (Interface)
(no doc)
src/shared/lib/page-routing.ts
Through (Interface)
(no doc)
typings/through.d.ts
Props (Interface)
(no doc)
src/features/card/draft/ui/atoms/submit-changes.tsx
Props (Interface)
(no doc)
src/entities/user/ui/user-card.tsx

Core symbols most depended-on inside this repo

stubId
called by 25
src/shared/api/mock/fixtures.ts
parseByStatus
called by 15
src/shared/api/internal/index.gen.ts
contract
called by 13
src/shared/lib/contract/index.ts
getPx
called by 11
src/shared/lib/theme.ts
measurement
called by 6
src/shared/lib/measure.ts
globMap
called by 5
.cz-config.js
getValueNode
called by 5
src/shared/lib/editor.ts
hasIncluding
called by 5
src/shared/api/mock/index.ts

Shape

Function 144
Interface 68
Enum 1

Languages

TypeScript100%

Modules by API surface

src/shared/api/internal/index.gen.ts32 symbols
src/app/server.tsx11 symbols
src/features/card/draft/ui/atoms/tag-input.tsx7 symbols
src/shared/lib/page-routing.ts5 symbols
src/entities/user/ui/user-preview.tsx5 symbols
src/entities/card/organisms/card-preview.tsx5 symbols
src/shared/ui/atoms/skeleton.tsx4 symbols
src/shared/lib/use-keyboard-focus.ts4 symbols
src/shared/api/request/server.ts4 symbols
src/shared/api/request/client.ts4 symbols
src/shared/api/mock/index.ts4 symbols
src/pages/search/page.tsx4 symbols

For agents

$ claude mcp add frontend \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact