@xphone/create-plugin
v0.4.0
Published
Scaffold xphone iframe plugins — npm create @xphone/plugin
Maintainers
Readme
@xphone/create-plugin
Scaffold iframe xphone plugins — works outside the monorepo with @xphone/sdk only.
Usage
npm create @xphone/plugin@latest my-app
cd xphone-my-app
npm install
npm run dev
npm run buildOptions
npx @xphone/create-plugin my-pizza \
--label "Pizza LS" \
--category productivity \
--color "#FF9500"| Flag | Default |
|------|---------|
| --label | Title derived from slug |
| --category | productivity |
| --color | #5856D6 |
Generated output
- TypeScript + Vue 3 + Vite, wired to
@xphone/sdk tsconfig.json+npm run typecheck(vue-tsc)fxmanifest.lua,client/,server/with the iframe manifestlocales/pt-BR.json+en.json- A 2×2 home-screen widget (
ui/widget.html) declared viawidgets[] sql/schema.sql+ auto-apply on start, and a per-pluginCHANGELOG.md- Sample NUI callback +
useXphonePlugin, showcasing the capability API (toast, Dynamic Island, audio, Siri, device state)
Requires Node 20.19+ or 22.12+ (Vite 8).
Monorepo (local dev)
node packages/create-xphone-plugin/bin/create-xphone-plugin.js test-app --label "Test App"