From 65b6f6741900232799c11a64d5924d8f4e002aa1 Mon Sep 17 00:00:00 2001 From: fern <126544928+fern-bot@users.noreply.github.com> Date: Tue, 28 May 2024 07:41:35 -0400 Subject: [PATCH] :herb: update casing in readme --- README.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/README.md b/README.md index dbf357f..0a39536 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# FileForge TypeScript Library +# Fileforge TypeScript Library [![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-SDK%20generated%20by%20Fern-brightgreen)](https://buildwithfern.com/) -The FileForge TypeScript library provides convenient access to the FileForge API from JavaScript/TypeScript. +The Fileforge TypeScript library provides convenient access to the Fileforge API from JavaScript/TypeScript. ## Documentation @@ -11,18 +11,18 @@ API reference documentation is available [here](https://fileforge.docs.buildwith ## Installation ```bash -npm install --save fileforge +npm install --save @fileforge/client # or -yarn add fileforge +yarn add @fileforge/client ``` ## Usage ```typescript -import { FileForgeClient, FileForge } from "guesty"; +import { FileforgeClient, Fileforge } from "@fileforge/client"; import * as fs from "fs"; -const fileforge = new FileForgeClient({ +const fileforge = new FileforgeClient({ apiKey: "...", }); @@ -37,15 +37,15 @@ await fileforge.generate({ ## Exception Handling When the API returns a non-success status code (4xx or 5xx response), -a subclass of [FileForgeError](./src/errors/FileForgeError.ts) will be thrown: +a subclass of [FileforgeError](./src/errors/FileforgeError.ts) will be thrown: ```ts -import { FileForgeError } from 'fileforge'; +import { FileforgeError } from '@fileforge/client'; try { await fileforge.generate(...); } catch (err) { - if (err instanceof FileForgeError) { + if (err instanceof FileforgeError) { console.log(err.statusCode); console.log(err.message); console.log(err.body); @@ -105,9 +105,9 @@ running in an unsupported environment, this provides a way for you to break the ensure the SDK works. ```ts -import { FileForge } from 'fileforge'; +import { Fileforge } from '@fileforge/client'; -const guesty = new FileForge({ +const guesty = new Fileforge({ apiKey: "...", fetcher: // provide your implementation here });