mirror of
https://github.com/whekin/household-bot.git
synced 2026-03-31 17:34:03 +00:00
Codex/whe 15 bootstrap workspace (#1)
* feat(WHE-15): bootstrap bun workspace with app and package scaffolds * chore(WHE-17): switch workspace typecheck to tsgo * chore(WHE-16): configure oxlint and oxfmt no-semicolon style * chore: address CodeRabbit review feedback * chore: apply coderabbit fixes and add review script * docs: add ADR decision metadata
This commit is contained in:
12
apps/bot/package.json
Normal file
12
apps/bot/package.json
Normal file
@@ -0,0 +1,12 @@
|
||||
{
|
||||
"name": "@household/bot",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "bun run src/index.ts",
|
||||
"build": "bun build src/index.ts --outdir dist --target bun",
|
||||
"typecheck": "tsgo --project tsconfig.json --noEmit",
|
||||
"test": "bun test --pass-with-no-tests",
|
||||
"lint": "oxlint \"src\""
|
||||
}
|
||||
}
|
||||
7
apps/bot/src/index.ts
Normal file
7
apps/bot/src/index.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
const startupMessage = '@household/bot scaffold is ready'
|
||||
|
||||
if (import.meta.main) {
|
||||
console.log(startupMessage)
|
||||
}
|
||||
|
||||
export { startupMessage }
|
||||
7
apps/bot/tsconfig.json
Normal file
7
apps/bot/tsconfig.json
Normal file
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"composite": true
|
||||
},
|
||||
"include": ["src/**/*.ts"]
|
||||
}
|
||||
25
apps/miniapp/.gitignore
vendored
Normal file
25
apps/miniapp/.gitignore
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
dist
|
||||
.wrangler
|
||||
.output
|
||||
.vercel
|
||||
.netlify
|
||||
.vinxi
|
||||
app.config.timestamp_*.js
|
||||
|
||||
# Environment
|
||||
.env
|
||||
.env*.local
|
||||
|
||||
# dependencies
|
||||
/node_modules
|
||||
|
||||
# IDEs and editors
|
||||
/.idea
|
||||
.project
|
||||
.classpath
|
||||
*.launch
|
||||
.settings/
|
||||
|
||||
# System Files
|
||||
.DS_Store
|
||||
Thumbs.db
|
||||
25
apps/miniapp/README.md
Normal file
25
apps/miniapp/README.md
Normal file
@@ -0,0 +1,25 @@
|
||||
# @household/miniapp
|
||||
|
||||
SolidJS + Vite Telegram Mini App workspace package.
|
||||
|
||||
## Install dependencies
|
||||
|
||||
```bash
|
||||
bun install
|
||||
```
|
||||
|
||||
Alternative package managers:
|
||||
|
||||
```bash
|
||||
npm install
|
||||
pnpm install
|
||||
yarn install
|
||||
```
|
||||
|
||||
## Available scripts
|
||||
|
||||
```bash
|
||||
bun run dev
|
||||
bun run build
|
||||
bun run typecheck
|
||||
```
|
||||
15
apps/miniapp/index.html
Normal file
15
apps/miniapp/index.html
Normal file
@@ -0,0 +1,15 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<meta name="theme-color" content="#000000" />
|
||||
<title>Solid App</title>
|
||||
</head>
|
||||
<body>
|
||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||
<div id="root"></div>
|
||||
|
||||
<script src="/src/index.tsx" type="module"></script>
|
||||
</body>
|
||||
</html>
|
||||
23
apps/miniapp/package.json
Normal file
23
apps/miniapp/package.json
Normal file
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"name": "@household/miniapp",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite",
|
||||
"build": "vite build",
|
||||
"typecheck": "tsgo --project tsconfig.json --noEmit",
|
||||
"test": "bun test --pass-with-no-tests",
|
||||
"lint": "oxlint \"src\""
|
||||
},
|
||||
"dependencies": {
|
||||
"solid-js": "^1.9.9"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@tailwindcss/vite": "^4.1.13",
|
||||
"solid-devtools": "^0.34.3",
|
||||
"tailwindcss": "^4.1.13",
|
||||
"typescript": "^5.9.2",
|
||||
"vite": "^7.1.4",
|
||||
"vite-plugin-solid": "^2.11.8"
|
||||
}
|
||||
}
|
||||
10
apps/miniapp/src/App.tsx
Normal file
10
apps/miniapp/src/App.tsx
Normal file
@@ -0,0 +1,10 @@
|
||||
function App() {
|
||||
return (
|
||||
<main>
|
||||
<h1>Household Mini App</h1>
|
||||
<p>SolidJS scaffold is ready</p>
|
||||
</main>
|
||||
)
|
||||
}
|
||||
|
||||
export default App
|
||||
1
apps/miniapp/src/index.css
Normal file
1
apps/miniapp/src/index.css
Normal file
@@ -0,0 +1 @@
|
||||
@import 'tailwindcss';
|
||||
13
apps/miniapp/src/index.tsx
Normal file
13
apps/miniapp/src/index.tsx
Normal file
@@ -0,0 +1,13 @@
|
||||
/* @refresh reload */
|
||||
import { render } from 'solid-js/web'
|
||||
|
||||
import './index.css'
|
||||
import App from './App'
|
||||
|
||||
const root = document.getElementById('root')
|
||||
|
||||
if (!root) {
|
||||
throw new Error('Root element not found')
|
||||
}
|
||||
|
||||
render(() => <App />, root)
|
||||
11
apps/miniapp/tsconfig.json
Normal file
11
apps/miniapp/tsconfig.json
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"extends": "../../tsconfig.base.json",
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"jsx": "preserve",
|
||||
"jsxImportSource": "solid-js",
|
||||
"types": ["vite/client"],
|
||||
"lib": ["ESNext", "DOM", "DOM.Iterable"]
|
||||
},
|
||||
"include": ["src/**/*.ts", "src/**/*.tsx", "vite.config.ts"]
|
||||
}
|
||||
14
apps/miniapp/vite.config.ts
Normal file
14
apps/miniapp/vite.config.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import tailwindcss from '@tailwindcss/vite'
|
||||
import { defineConfig } from 'vite'
|
||||
import solidPlugin from 'vite-plugin-solid'
|
||||
import devtools from 'solid-devtools/vite'
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [devtools(), solidPlugin(), tailwindcss()],
|
||||
server: {
|
||||
port: 3000
|
||||
},
|
||||
build: {
|
||||
target: 'esnext'
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user