Skip to content
Niko Table

Contributing Code

How to set up the repo and send a pull request.

Read this page before your first pull request. Also check open issues and pull requests. Someone may already be working on the same thing.

This repository is an Astro Starlight project.

  • We use pnpm for development (npm also works).
  • We use prettier for code formatting. It runs on commit.

The repo is laid out like this:

  • Directorysrc
    • Directoryassets/
      • …
    • Directorycomponents/
      • …
    • Directorycontent/docs
      • Directorygetting-started/
        • …
      • Directoryniko-table/
        • …
      • Directorydata-grid/
        • …
      • Directoryexamples/
        • …
      • Directorycontributing/
        • …
    • Directoryregistry/new-york
      • Directoryexamples/
        • …
    • Directorycomponents/niko-table/
      • …
  • src/assets: Logos and images for the docs site.
  • src/components: Site UI (markdown helpers, overrides, etc.).
  • src/content/docs/getting-started: Install and intro guides.
  • src/content/docs/niko-table and data-grid: Overview and API, by layer.
  • src/content/docs/examples: Table and grid example pages you can run.
  • src/content/docs/contributing: How to help (code, requests, docs).
  • src/registry/new-york/examples: Demo components that CodePreview shows.
  • src/components/niko-table: Component sources people install. The root registry.json packages them.

For how to shape docs and example pages, see Documentation Guidelines.

  1. Fork the repository

  2. Clone on your local machine

    git clone [email protected]:Semkoo/niko-table-registry.git
  3. Navigate to project directory

    cd niko-table-registry
  4. Create a new Branch

    git checkout -b my-new-branch
  5. Install dependencies

    pnpm install
    # or
    npm install
  6. Copy .env.example to .env

    cp .env.example .env
  7. Run the development server

    pnpm dev
    # or
    npm run dev

To check that the registry builds, run:

pnpm registry:build
# or
npm run registry:build

Then install any component from it in a new project with shadcn add:

npx shadcn@latest add http://localhost:4321/r/<component-name>.json