Movatterモバイル変換


[0]ホーム

URL:


Dev guideRecipesAPI ReferenceChangelog
Dev guideAPI ReferenceRecipesChangelogUser GuideGitHubDev CommunityOptimizely AcademySubmit a ticketLog InFeature Experimentation
Dev guide
All
Pages
Start typing to search…

Install the JavaScript (Node) SDK prior to v6

The steps necessary to install the Optimizely Feature Experimentation JavaScript (Node) SDK into your application.

The JavaScript (Node) SDK is distributed throughnpm:

Usingnpm:

npm install --save @optimizely/optimizely-sdk

Usingyarn:

yarn add @optimizely/optimizely-sdk

Usingpnpm:

pnpm add @optimizely/optimizely-sdk

Usingdeno (no installation required):

import optimizely from "npm:@optimizely/optimizely-sdk"

The full JavaScript SDK source code is available onGitHub.

Requirements

The JavaScript (Node) SDK requires Node version 8.0+.

The following peer dependencies may be required for use in production:

{    "[email protected]": {      "licenses": [        "AFLv2.1",        "BSD"      ],      "publisher": "Kris Zyp",      "repository": "<https://github.com/kriszyp/json-schema>"    },    "[email protected]": {      "licenses": "MIT\*",      "repository": "<https://github.com/perezd/node-murmurhash>"    },    "[email protected]": {      "licenses": "MIT",      "repository": "<https://github.com/kelektiv/node-uuid>"    },    "[email protected]": {      "licenses": "MIT",      "repository": "<https://github.com/sindresorhus/decompress-response>"    }  }

To regenerate this, run the following command:

npx license-checker --production --json | jq 'map_values({ licenses, publisher, repository }) | del(.[][] | nulls)'

and remove the self (@optimizely/optimizely-sdk) entry.

📘

Note

Thejq command-line JSON processor is required to run the above script. You may installjq to your environment by usingHomebrew on MacOS using the commandbrew install jq. For Windows users, please visit thejq GitHub repository to learn more.

Next

After installing, you need toinitialize the SDK.

Updated 17 days ago



[8]ページ先頭

©2009-2025 Movatter.jp