Last updated

Dataloop JS-SDK Library components version release status

Written in TypeScript, this repository contains the core of Dataloop's JavaScript SDK.

Installation

npm install @dataloop-ai/jssdk

Quick Start

import { initializeFrameDriver } from '@dataloop-ai/jssdk';

// Initialize the SDK
await initializeFrameDriver();

Architecture

The SDK consists of three main components:

1. appLib

The core communication layer containing:

  • xFrame: Main communication tool between Dataloop's platform and external web applications
  • SDK Drivers:
    • Dataloop Driver (REST)
    • xFrameDriver (xFrame)

The appLib is compiled into a single dlAppLib.js file that can be used as an external script in any application.

2. sdkApi

The source of truth for the JS-SDK API, containing:

  • Entity definitions
  • Interface declarations
  • Type definitions
  • Core API implementations

Development

Prerequisites

  • Node.js (v12 or higher)
  • npm (v6 or higher)

Setup

  1. Clone the repository
git clone git@github.com:dataloop-ai/jssdk.git
cd jssdk
  1. Install dependencies
npm install

Build Commands

  1. Create an updated version of dlAppLib:
npm run build:applib
  1. Full build (includes all components):
npm run build
  1. Watch mode for development:
npm run build:watch

Documentation

The SDK uses TypeDoc to generate documentation. To generate the docs:

npm run tsdoc

Documentation will be generated in the docs directory and includes:

  • API Reference
  • Type Definitions
  • Usage Examples
  • Interface Descriptions

Contributing

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

This project is licensed under the Apache-2.0 License - see the LICENSE file for details.

Support

For support and questions, please open an issue or contact our support team.