mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-07 21:04:26 +08:00
<!--
Make sure you've read the CONTRIBUTING.md guidelines:
https://github.com/stack-auth/stack-auth/blob/dev/CONTRIBUTING.md
-->
<img width="474" alt="image"
src="https://github.com/user-attachments/assets/5fb5a632-d605-49ed-89d6-b26533d84a2f"
/>
<!-- ELLIPSIS_HIDDEN -->
----
> [!IMPORTANT]
> Adds `DemoFloatingWindow` component for development, integrated into
demo layout and stack initialization, providing user actions like
sign-in and account settings.
>
> - **Behavior**:
> - Adds `DemoFloatingWindow` component in `demo-floating-window.tsx`,
visible only in development mode.
> - Provides user actions: sign-in, sign-out, account settings.
> - **Integration**:
> - Integrates `DemoFloatingWindow` into `layout.tsx` within the
`StackProvider` and `StackTheme`.
> - Updates `getUpdatedLayout()` in `index.ts` to include
`DemoFloatingWindow` in the layout.
> - **Exports**:
> - Exports `DemoFloatingWindow` in `index.ts` for external use.
>
> <sup>This description was created by </sup>[<img alt="Ellipsis"
src="https://img.shields.io/badge/Ellipsis-blue?color=175173">](https://www.ellipsis.dev?ref=stack-auth%2Fstack-auth&utm_source=github&utm_medium=referral)<sup>
for
|
||
|---|---|---|
| .. | ||
| src | ||
| .eslintrc.cjs | ||
| .gitignore | ||
| CHANGELOG.md | ||
| LICENSE | ||
| package.json | ||
| README.md | ||
| tsconfig.json | ||
| tsup.config.ts | ||
| vitest.config.ts | ||
Stack Auth Initialization Tool
This package provides a command-line tool to initialize Stack Auth in your project.
Usage
npx init-stack [project-path] [options]
Options
--help,-h: Show help message--dry-run: Run without making any changes--neon: Use Neon database--js: Initialize for JavaScript project--next: Initialize for Next.js project--npm: Use npm as package manager--yarn: Use yarn as package manager--pnpm: Use pnpm as package manager--bun: Use bun as package manager--client: Initialize client-side only--server: Initialize server-side only--no-browser: Don't open browser for environment variable setup
Environment Variables
STACK_DISABLE_INTERACTIVE: Set to any value to disable interactive prompts. Useful for CI/CD environments.
Examples
Initialize Stack Auth in a Next.js project without opening the browser:
npx init-stack --next --no-browser
Initialize Stack Auth in a JavaScript project with npm:
npx init-stack --js --npm
For more information, please visit Stack Auth Documentation.