create-sbc-app 0.3.0 → 0.4.0
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/README.md +75 -5
- package/bin/cli.js +13 -5
- package/package.json +1 -1
- package/templates/README.md +53 -4
- package/templates/react/README.md.template +8 -9
- package/templates/react-dynamic/.env.template +1 -1
- package/templates/react-dynamic/README.md.template +131 -13
- package/templates/react-para/.env.template +1 -1
- package/templates/react-para/README.md.template +154 -13
- package/templates/react-turnkey/.env.template +26 -0
- package/templates/react-turnkey/README.md.template +206 -0
- package/templates/react-turnkey/eslint.config.js.template +32 -0
- package/templates/react-turnkey/index.html.template +14 -0
- package/templates/react-turnkey/package.json.template +45 -0
- package/templates/react-turnkey/public/sbc-logo.png +0 -0
- package/templates/react-turnkey/server/index.ts.template +271 -0
- package/templates/react-turnkey/src/App.tsx.template +1701 -0
- package/templates/react-turnkey/src/env.d.ts.template +17 -0
- package/templates/react-turnkey/src/index.css.template +16 -0
- package/templates/react-turnkey/src/main.tsx.template +11 -0
- package/templates/react-turnkey/tsconfig.json.template +25 -0
- package/templates/react-turnkey/tsconfig.node.json.template +10 -0
- package/templates/react-turnkey/vite.config.ts.template +10 -0
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/// <reference types="vite/client" />
|
|
2
|
+
|
|
3
|
+
interface ImportMetaEnv {
|
|
4
|
+
// SBC Configuration
|
|
5
|
+
readonly VITE_SBC_API_KEY: string;
|
|
6
|
+
readonly VITE_RPC_URL?: string;
|
|
7
|
+
readonly VITE_CHAIN?: string;
|
|
8
|
+
|
|
9
|
+
// Turnkey Configuration (Frontend only - public)
|
|
10
|
+
readonly VITE_TURNKEY_API_BASE_URL: string;
|
|
11
|
+
readonly VITE_TURNKEY_RPID: string;
|
|
12
|
+
readonly VITE_BACKEND_URL: string;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
interface ImportMeta {
|
|
16
|
+
readonly env: ImportMetaEnv;
|
|
17
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
@tailwind base;
|
|
2
|
+
@tailwind components;
|
|
3
|
+
@tailwind utilities;
|
|
4
|
+
|
|
5
|
+
body {
|
|
6
|
+
margin: 0;
|
|
7
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
|
|
8
|
+
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
|
|
9
|
+
sans-serif;
|
|
10
|
+
-webkit-font-smoothing: antialiased;
|
|
11
|
+
-moz-osx-font-smoothing: grayscale;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
code {
|
|
15
|
+
font-family: 'Courier New', Courier, monospace;
|
|
16
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import ReactDOM from 'react-dom/client';
|
|
3
|
+
import '@turnkey/sdk-react/styles';
|
|
4
|
+
import App from './App';
|
|
5
|
+
import './index.css';
|
|
6
|
+
|
|
7
|
+
ReactDOM.createRoot(document.getElementById('root')!).render(
|
|
8
|
+
<React.StrictMode>
|
|
9
|
+
<App />
|
|
10
|
+
</React.StrictMode>,
|
|
11
|
+
);
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2020",
|
|
4
|
+
"useDefineForClassFields": true,
|
|
5
|
+
"lib": ["ES2020", "DOM", "DOM.Iterable"],
|
|
6
|
+
"module": "ESNext",
|
|
7
|
+
"skipLibCheck": true,
|
|
8
|
+
|
|
9
|
+
/* Bundler mode */
|
|
10
|
+
"moduleResolution": "bundler",
|
|
11
|
+
"allowImportingTsExtensions": true,
|
|
12
|
+
"resolveJsonModule": true,
|
|
13
|
+
"isolatedModules": true,
|
|
14
|
+
"noEmit": true,
|
|
15
|
+
"jsx": "react-jsx",
|
|
16
|
+
|
|
17
|
+
/* Linting */
|
|
18
|
+
"strict": true,
|
|
19
|
+
"noUnusedLocals": true,
|
|
20
|
+
"noUnusedParameters": true,
|
|
21
|
+
"noFallthroughCasesInSwitch": true
|
|
22
|
+
},
|
|
23
|
+
"include": ["src"],
|
|
24
|
+
"references": [{ "path": "./tsconfig.node.json" }]
|
|
25
|
+
}
|