From 70655387ffb57ab165d433b566acad408ee12c12 Mon Sep 17 00:00:00 2001 From: owenpearson Date: Thu, 15 May 2025 10:17:25 +0100 Subject: [PATCH] fix getting started project setup instructions --- content/chat/getting-started/javascript.textile | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/content/chat/getting-started/javascript.textile b/content/chat/getting-started/javascript.textile index 1252c951e2..f5b40f95d8 100644 --- a/content/chat/getting-started/javascript.textile +++ b/content/chat/getting-started/javascript.textile @@ -38,20 +38,23 @@ ably apps switch ably auth keys switch ``` -* Install "Node.js":https://nodejs.org/en version 18 or greater. -* Install "ts-node":https://www.npmjs.com/package/ts-node to execute TypeScript files: +* Install any current LTS version of "Node.js":https://nodejs.org/en and create a new project: ```[sh] -npm install ts-node +npm init -y ``` -* Create a new project in your IDE and install the Ably Chat JavaScript SDK. This will also install the Ably Pub/Sub SDK as it is a dependency: +* Install "typescript":https://www.npmjs.com/package/typescript to compile TypeScript files. +* Install "ts-node":https://www.npmjs.com/package/ts-node to execute TypeScript files directly. ```[sh] -npm init -y -tsc --init +npm install @ably/chat typescript ts-node +``` -npm install @ably/chat +* Create a default TypeScript configuration in your project + +```[sh] +npx tsc --init ```