From f7c28065ae37cd0c90394c85926bf5ea67229ee7 Mon Sep 17 00:00:00 2001 From: Zeke Sikelianos Date: Tue, 14 May 2024 16:11:44 -0700 Subject: [PATCH] document node 18 requirement --- README.md | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index f6d798c8..b6742581 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,8 @@ and everything else you can do with ## Installation +This library requires Node.js >= 18. + Install it from npm: ```bash @@ -20,7 +22,7 @@ npm install replicate ## Usage -Create the client: +Import or require the package: ```js // CommonJS (default or using .cjs extension) @@ -30,9 +32,11 @@ const Replicate = require("replicate"); import Replicate from "replicate"; ``` -``` +Instantiate the client: + +```js const replicate = new Replicate({ - // get your token from https://replicate.com/account + // get your token from https://replicate.com/account/api-tokens auth: "my api token", // defaults to process.env.REPLICATE_API_TOKEN }); ```