Changelog

October 22, 2021

API β€” 2.4.1

    We fixed a bug with the API (and in-app exports) that included hidden text in flat and structured JSON exports. Now, hidden text will correctly not be included in these export formats!

Ditto Demo

    We included the files to import into the component library separately from where they'd be synced via the CLI
    We included more instructions on linking the demo app with its corresponding design file

October 7, 2021

General

    Refactored API documentation to be easier to navigate and communicate critical concepts more clearly

Ditto CLI β€” 1.1.1

    When the pull command is executed, all .json and .js files are now removed from the ditto folder prior to new data being written
    Support added for new options in ditto/config.yml:
      variants: true or false
        If set to true, data will be fetched for both base and variant text and stored in separate JSON files
      format: flat or structured
        If specified, data will be fetched and stored in the specified format
    Refactored README
    GET /variants will now return names and API IDs for variants in the workspace associated with the requesting user.

Ditto React β€” 0.0.5

    Support added for flat and structured formats
    Support added for passing a variant value to DittoProvider
    Bug fixes around support for integrating with workspace component libraries (as opposed to individual projects)
    Refactored README

Ditto Demo

    Refactored ditto-sdk usage to integrate with a component library instead of an individual project
    Added a language picker to showcase ditto-react and ditto-cli support for variants
    Refactored README, including adding instructions for connecting the repo to a component library

September 27, 2021

General

    Fixed incorrect example of /projects usage in API Reference. The projectIds query parameter should be specified as follows:
      Correct
        ?projectIds[]=<PROJECT_ID>&projectIds[]=<PROJECT_ID>
      Incorrect
        ?projectIds[]=<PROJECT_ID>,<PROJECT_ID>

API β€” 2.4.0

    GET /variants will now return names and API IDs for variants in the workspace associated with the requesting user.

September 8, 2021

API β€” 2.3.0

    GET /projects and GET /projects/:id now accept an optional query parameter of variant; when provided, the data exported will be specific to the variant with an API ID that matches the parameter's value. For default and structured formats, the variants key will not be included when the variant parameter is provided.
      Example: /projects/<PROJECT_ID>?variant=xxx-xxx-xxx
    GET /projects/:id will not include top-level projects and project_xyz keys
      Example request: GET /projects/123
      Example response before change:
        { projects: { project_123: { text_item: "Hello World", ... }}}
      Example response after change:
        { text_item: "Hello World", ... }

August 11, 2021

API β€” 2.2.0

    GET /projects and GET /projects/:id now accepts an optional query parameter of format, which can be either flat or structured. If no format is provided, the full JSON of the project will be returned with blocks and frames.
      Example: /projects/<PROJECT_ID>?format=flat

July 28, 2021

With the recent release of Variants for Components, we've included them in both exports from our web-app and the JSON response from the API.

API β€” 2.1.0

    GET /projects/:id will now return component variants. This applies both for when fetching projects or when fetching the component library (i.e. id = ditto_component_library)
    GET /projects/:id will now match the project JSON export from the web-app to include component information (is_comp and component_api_id) in the text object

June 21, 2021

We've updated our React library and our demo project to work with the multi-project JSON structure that the CLI now saves in text.json.

Ditto React β€” 0.0.4

    TypeScript bindings are now exported πŸŽ‰β€‹
    A new projectId prop can be passed to DittoProvider or Ditto
      If passed to DittoProvider, all descendant Ditto components will default to pulling text from the associated project
      If passed to Ditto, the component will pull text from the associated project
      If passed to both DittoProvider and Ditto, the value passed to Ditto will take precedence
      Breaking change: If a Ditto component is rendered that is not provided a projectId via direct prop or DittoContext ancestor, an error will be thrown
See more details in the updated documentation.

Ditto Demo

    Upgraded ditto-react to version 0.0.4
    Updated source to work with new ditto-react version by passing projectId props to all instances of DittoContext

June 7, 2021

We've updated both our CLI and API to handle multiple projects.
Heads up! This results in some breaking changes to the CLI in order for it to list projects, and will change the format of the text.json fetched by the CLI. Please upgrade your Ditto CLI via either npm or yarn.

API β€” 2.0.0

    GET /project-names is the new name of the previous GET /projects endpoint. Just as before, this will return the names and IDs of projects in your Ditto workspace with Developer Mode turned on
    GET /projects/:id will now return the structured JSON in a format compatible with multiple projects
    GET /projects is a new endpoint that will return the content of multiple projects (specified via the query parameter projectIds) as a single JSON object

CLI β€” 1.0.0

    We've updated the CLI to handle syncing multiple projects in a single directory! This means several things:
      /ditto/config.yml now supports multiple projects. ditto-cli pull will pull all projects in the current directory's /ditto/config.yml
      We've added two new commands to add and remove projects from /ditto/config.yml
        ditto-cli project add
        ditto-cli project remove
        The regular ditto-cli project command will now function as ditto-cli project add

April 1, 2021

API β€” 1.1.0

    GET /projects now includes the Component Library if Developer Mode is enabled for the Component Library
    GET /projects/:id will return the Component Library as a structured JSON if the ID provided is ditto_component_library

February 25, 2021

API β€” 1.0.0

    GET /projects endpoint for fetching Ditto projects from workspace
    GET /projects/:id endpoint for fetching content in Ditto project as structured JSON
Last modified 3d ago