Skip to content

Commit fd6d3a5

Browse files
committed
Update package name to @starfederation/datastar-sdk across all relevant files
- Changed package name in build.ts and package.json. - Updated installation instructions in README.md for Node.js, Deno, and Bun examples. - Adjusted import statements in example files to reflect the new package name.
1 parent e46514f commit fd6d3a5

File tree

8 files changed

+16
-16
lines changed

8 files changed

+16
-16
lines changed

README.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,32 +22,32 @@ Currently it only exposes an http1 server, if you want http2 I recommend you use
2222

2323
**Node.js:**
2424
```bash
25-
npm install datastar-sdk
25+
npm install @starfederation/datastar-sdk
2626
```
2727
```javascript
28-
import { ServerSentEventGenerator } from "datastar-sdk/node";
28+
import { ServerSentEventGenerator } from "@starfederation/datastar-sdk/node";
2929
```
3030

3131
**Deno:**
3232
```typescript
3333
// No installation needed, import directly from npm
34-
import { ServerSentEventGenerator } from "npm:datastar-sdk/web";
34+
import { ServerSentEventGenerator } from "npm:@starfederation/datastar-sdk/web";
3535
```
3636

3737
**Bun:**
3838
```bash
39-
bun add datastar-sdk
39+
bun add @starfederation/datastar-sdk
4040
```
4141
```javascript
42-
import { ServerSentEventGenerator } from "datastar-sdk/web";
42+
import { ServerSentEventGenerator } from "@starfederation/datastar-sdk/web";
4343
```
4444

4545
### Basic Usage
4646

4747
Here's a simple example in Node showing how to read client signals and send back element patches:
4848

4949
```javascript
50-
import { ServerSentEventGenerator } from "datastar-sdk/node";
50+
import { ServerSentEventGenerator } from "@starfederation/datastar-sdk/node";
5151

5252
// Read signals from the client request
5353
const reader = await ServerSentEventGenerator.readSignals(req);
@@ -284,17 +284,17 @@ typescript/
284284
## Runtime Support
285285

286286
### Node.js
287-
- Import: `datastar-sdk/node`
287+
- Import: `@starfederation/datastar-sdk/node`
288288
- Requires: Node.js 18+
289289
- Uses Node.js-specific HTTP APIs
290290

291291
### Deno
292-
- Import: `npm:datastar-sdk/web`
292+
- Import: `npm:@starfederation/datastar-sdk/web`
293293
- Requires: Deno 1.30+
294294
- Uses Web Standards APIs
295295

296296
### Bun
297-
- Import: `datastar-sdk/web`
297+
- Import: `@starfederation/datastar-sdk/web`
298298
- Requires: Bun 1.0+
299299
- Uses Web Standards APIs
300300

build.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ await build({
1616
},
1717
package: {
1818
// package.json properties
19-
name: "datastar-sdk",
19+
name: "@starfederation/datastar-sdk",
2020
version: Deno.args[0] || VERSION,
2121
description: "Cross-runtime Javascript SDK for Datastar",
2222
license: "MIT",

examples/bun/bun.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { ServerSentEventGenerator } from "datastar-sdk/web";
1+
import { ServerSentEventGenerator } from "@starfederation/datastar-sdk/web";
22

33
const server = Bun.serve({
44
port: 3000,

examples/bun/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"typescript": "^5"
1111
},
1212
"dependencies": {
13-
"datastar-sdk": "^1.0.0-RC.1"
13+
"@starfederation/datastar-sdk": "^1.0.0-RC.2"
1414
},
1515
"scripts": {
1616
"start": "bun bun.ts"

examples/deno/deno.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { serve } from "https://deno.land/[email protected]/http/server.ts";
2-
import { ServerSentEventGenerator } from "npm:datastar-sdk/web";
2+
import { ServerSentEventGenerator } from "npm:@starfederation/datastar-sdk/web";
33

44
serve(async (req: Request) => {
55
const url = new URL(req.url);

examples/node/node.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { createServer } from "node:http";
2-
import { ServerSentEventGenerator } from "datastar-sdk/node";
2+
import { ServerSentEventGenerator } from "@starfederation/datastar-sdk/node";
33

44
const hostname = "127.0.0.1";
55
const port = 3000;

examples/node/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,6 @@
99
"license": "ISC",
1010
"description": "",
1111
"dependencies": {
12-
"datastar-sdk": "^1.0.0-RC.2"
12+
"@starfederation/datastar-sdk": "^1.0.0-RC.2"
1313
}
1414
}

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "datastar-sdk",
2+
"name": "@starfederation/datastar-sdk",
33
"version": "1.0.0-RC.2",
44
"description": "TypeScript SDK for Datastar",
55
"scripts": {

0 commit comments

Comments
 (0)