create-sia-app 0.1.15 → 0.1.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-sia-app",
3
- "version": "0.1.15",
3
+ "version": "0.1.16",
4
4
  "type": "module",
5
5
  "bin": {
6
6
  "create-sia-app": "./dist/index.js"
@@ -2,9 +2,9 @@
2
2
 
3
3
  ## Overview
4
4
 
5
- A starter template for building decentralized storage apps on the Sia network. Uses [`sia-storage`](https://www.npmjs.com/package/sia-storage) — a TypeScript SDK that ships a pre-compiled WASM binary for encryption, uploads, downloads, and key management. WASM runs on the main thread (Rust async — no workers required).
5
+ A starter template for building decentralized storage apps on the Sia network. Uses [`@siafoundation/sia-storage`](https://www.npmjs.com/package/@siafoundation/sia-storage) — a TypeScript SDK that ships a pre-compiled WASM binary for encryption, uploads, downloads, and key management. WASM runs on the main thread (Rust async — no workers required).
6
6
 
7
- **Tech stack:** React 19, TypeScript, Vite, Tailwind CSS 4, Zustand, `sia-storage`
7
+ **Tech stack:** React 19, TypeScript, Vite, Tailwind CSS 4, Zustand, `@siafoundation/sia-storage`
8
8
 
9
9
  ## Architecture
10
10
 
@@ -28,7 +28,7 @@ Returning users skip `requestConnection`/`waitForApproval`/`register` entirely.
28
28
 
29
29
  ### SDK
30
30
 
31
- `sia-storage` handles:
31
+ `@siafoundation/sia-storage` handles:
32
32
  - Encrypted file uploads/downloads (erasure coding + encryption)
33
33
  - Key derivation from recovery phrases (BIP-39)
34
34
  - Object pinning and metadata management
@@ -62,7 +62,7 @@ Auth state persists to localStorage via Zustand's `persist` middleware. The stor
62
62
  ### Upload a file
63
63
 
64
64
  ```ts
65
- import { PinnedObject } from 'sia-storage'
65
+ import { PinnedObject } from '@siafoundation/sia-storage'
66
66
 
67
67
  const object = new PinnedObject()
68
68
  const pinnedObject = await sdk.upload(object, file.stream(), {
@@ -76,7 +76,7 @@ const sdk = useAuthStore((s) => s.sdk)
76
76
  - [Tailwind CSS](https://tailwindcss.com) 4
77
77
  - [Zustand](https://zustand.docs.pmnd.rs) (state management)
78
78
  - [Biome](https://biomejs.dev) (linting & formatting)
79
- - [sia-storage](https://www.npmjs.com/package/sia-storage) (Sia SDK — encryption, erasure coding, direct host transfers via WASM)
79
+ - [@siafoundation/sia-storage](https://www.npmjs.com/package/@siafoundation/sia-storage) (Sia SDK — encryption, erasure coding, direct host transfers via WASM)
80
80
 
81
81
  ## Project Structure
82
82
 
@@ -94,4 +94,4 @@ src/
94
94
  ## Learn More
95
95
 
96
96
  - [Sia Documentation](https://docs.sia.tech)
97
- - [sia-storage](https://www.npmjs.com/package/sia-storage)
97
+ - [@siafoundation/sia-storage](https://www.npmjs.com/package/@siafoundation/sia-storage)
@@ -12,7 +12,7 @@
12
12
  "dependencies": {
13
13
  "react": "^19.2.0",
14
14
  "react-dom": "^19.2.0",
15
- "sia-storage": "^0.0.8",
15
+ "@siafoundation/sia-storage": "^0.0.8",
16
16
  "zustand": "^5.0.11"
17
17
  },
18
18
  "devDependencies": {
@@ -1,5 +1,5 @@
1
1
  import { useEffect, useRef, useState } from 'react'
2
- import type { Builder } from 'sia-storage'
2
+ import type { Builder } from '@siafoundation/sia-storage'
3
3
  import { useAuthStore } from '../../stores/auth'
4
4
  import { CopyButton } from '../CopyButton'
5
5
  import { DevNote } from '../DevNote'
@@ -1,5 +1,5 @@
1
1
  import { useEffect, useRef } from 'react'
2
- import { AppKey, Builder, initSia } from 'sia-storage'
2
+ import { AppKey, Builder, initSia } from '@siafoundation/sia-storage'
3
3
  import { APP_META } from '../../lib/constants'
4
4
  import { useAuthStore } from '../../stores/auth'
5
5
  import { ApproveScreen } from './ApproveScreen'
@@ -1,5 +1,5 @@
1
1
  import { useState } from 'react'
2
- import { Builder } from 'sia-storage'
2
+ import { Builder } from '@siafoundation/sia-storage'
3
3
  import { APP_META, DEFAULT_INDEXER_URL } from '../../lib/constants'
4
4
  import { useAuthStore } from '../../stores/auth'
5
5
  import { DevNote } from '../DevNote'
@@ -3,7 +3,7 @@ import {
3
3
  type Builder,
4
4
  generateRecoveryPhrase,
5
5
  validateRecoveryPhrase,
6
- } from 'sia-storage'
6
+ } from '@siafoundation/sia-storage'
7
7
  import { useAuthStore } from '../../stores/auth'
8
8
  import { CopyButton } from '../CopyButton'
9
9
  import { DevNote } from '../DevNote'
@@ -1,5 +1,5 @@
1
1
  import { useCallback, useEffect, useRef, useState } from 'react'
2
- import { encodedSize, PinnedObject, type ShardProgress } from 'sia-storage'
2
+ import { encodedSize, PinnedObject, type ShardProgress } from '@siafoundation/sia-storage'
3
3
  import { APP_KEY, DATA_SHARDS, PARITY_SHARDS } from '../../lib/constants'
4
4
  import { useAuthStore } from '../../stores/auth'
5
5
  import { DevNote } from '../DevNote'
@@ -1,4 +1,4 @@
1
- import type { AppMetadata } from 'sia-storage'
1
+ import type { AppMetadata } from '@siafoundation/sia-storage'
2
2
 
3
3
  // biome-ignore format: long hex literal
4
4
  export const APP_KEY = '{{APP_KEY}}'
@@ -1,4 +1,4 @@
1
- import type { Sdk } from 'sia-storage'
1
+ import type { Sdk } from '@siafoundation/sia-storage'
2
2
  import { create } from 'zustand'
3
3
  import { persist } from 'zustand/middleware'
4
4
  import { APP_KEY } from '../lib/constants'
@@ -6,5 +6,5 @@ export default defineConfig({
6
6
  plugins: [react(), tailwindcss()],
7
7
  // sia-storage loads its WASM via `new URL(..., import.meta.url)`; excluding
8
8
  // it from the deps pre-bundler keeps that URL pointing at the real file.
9
- optimizeDeps: { exclude: ['sia-storage'] },
9
+ optimizeDeps: { exclude: ['@siafoundation/sia-storage'] },
10
10
  })