CLI command to upload code components

Created on 20 May 2025, about 1 month ago

Overview

The CLI tool needs to be able to upload code components from a local codebase. This means sending their data with POST to the /api/v0/config/js_component endpoint.

β†’ See: 🌱 [Meta] CLI tool for code components Active

Proposed resolution

  1. Implement this command using the implementation as a reference from the POC: https://github.com/lauriii/experience-builder-cli/blob/main/src/commands.... Use @clack/prompts.
  2. Read the location for your local directory for components from an environment variable or .env file established in πŸ“Œ Set up first authenticated request from CLI Postponed .
  3. Component format:
    my-component/
      β”œβ”€β”€ component.yml     # Component metadata and configuration
      β”œβ”€β”€ index.jsx         # React component source
      β”œβ”€β”€ index.css         # Optional CSS
    

    The component.yml file can match the shape of the data the /api/v0/config/js_component endpoint works with β€” excluding the JS and CSS source/compiled code.

  4. Allow users to select components interactively or passed as a CLI argument. Make sure there is an option to select all.
  5. Upload the CSS source for the global asset library (/api/v0/config/xb_asset_library/global) reading it from the global.css file located in the local folder for components.
  6. Out of scope: compiling and uploading compiled JS/CSS.
✨ Feature request
Status

Postponed

Version

0.0

Component

CLI Tool

Created by

πŸ‡³πŸ‡±Netherlands balintbrews Amsterdam, NL

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @balintbrews
  • First commit to issue fork.
  • πŸ‡ΊπŸ‡ΈUnited States hooroomoo
  • πŸ‡ΊπŸ‡ΈUnited States hooroomoo

    hooroomoo β†’ changed the visibility of the branch 3525587-cli-command-to to hidden.

  • Pipeline finished with Canceled
    8 days ago
    #523685
  • Pipeline finished with Failed
    8 days ago
    #523688
  • Pipeline finished with Failed
    8 days ago
    #523690
  • Pipeline finished with Failed
    8 days ago
    #523704
  • Pipeline finished with Running
    8 days ago
    #523710
  • Pipeline finished with Canceled
    8 days ago
    #523709
  • Pipeline finished with Failed
    8 days ago
    Total: 816s
    #523774
  • Pipeline finished with Failed
    7 days ago
    Total: 771s
    #523977
  • Pipeline finished with Failed
    7 days ago
    Total: 1037s
    #523984
  • Pipeline finished with Failed
    7 days ago
    #524471
  • Pipeline finished with Success
    7 days ago
    Total: 1075s
    #524797
  • Pipeline finished with Canceled
    6 days ago
    Total: 636s
    #525247
  • Pipeline finished with Canceled
    6 days ago
    Total: 294s
    #525252
  • Pipeline finished with Canceled
    6 days ago
    Total: 647s
    #525256
  • Pipeline finished with Failed
    6 days ago
    Total: 908s
    #525266
  • Pipeline finished with Success
    6 days ago
    Total: 899s
    #525275
  • Pipeline finished with Canceled
    6 days ago
    Total: 391s
    #525289
  • Pipeline finished with Canceled
    6 days ago
    Total: 398s
    #525295
  • Pipeline finished with Skipped
    6 days ago
    #525307
  • πŸ‡³πŸ‡±Netherlands balintbrews Amsterdam, NL
  • Pipeline finished with Failed
    6 days ago
    Total: 904s
    #525298
Production build 0.71.5 2024