Options
All
  • Public
  • Public/Protected
  • All
Menu

@youwol/cdn-client

cdn-client

Maintenance License: MIT

Javascript library for dynamic dependencies fetching from YouWol's CDN

Installation, Build & Test

To install the required dependencies:

yarn 

To build for development:

yarn build:dev

To build for production:

yarn build:prod

To test:

yarn test

To generate code documentation:

yarn doc

Usage

This library is used to dynamically fetch dependencies from YouWol's CDN in a front-end application, e.g.:

await cdn.fetchBundles(
    {
        'd3': '5.15.0',
        "@youwol/fv-tree": "0.0.3",
        "@youwol/flux-lib-core": '1.8.0'
    })

Missing dependencies from the provided mapping will be fetched using their latest version.

This client is only dealing with packages stored in the YouWol's CDN: the dependencies requested, as well as their direct and indirect dependencies, must exist in there.

The library can also be used to install stylesheets or javascript addons, see the developer documentation.

Generated using TypeDoc