create-nextly-app 0.0.1 → 0.0.2-alpha.1
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/LICENSE +22 -0
- package/README.md +131 -0
- package/bin/create-nextly-app.js +3 -0
- package/dist/chunk-AYJ2RKVJ.mjs +28752 -0
- package/dist/chunk-AYJ2RKVJ.mjs.map +1 -0
- package/dist/cli.cjs +32410 -0
- package/dist/cli.cjs.map +1 -0
- package/dist/cli.d.cts +1 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.mjs +3633 -0
- package/dist/cli.mjs.map +1 -0
- package/dist/index.cjs +24776 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +69 -0
- package/dist/index.d.ts +69 -0
- package/dist/index.mjs +6 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +83 -10
package/LICENSE
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 NextlyHQ <info@nextlyhq.com>
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
6
|
+
a copy of this software and associated documentation files (the
|
|
7
|
+
'Software'), to deal in the Software without restriction, including
|
|
8
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
|
9
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
|
10
|
+
permit persons to whom the Software is furnished to do so, subject to
|
|
11
|
+
the following conditions:
|
|
12
|
+
|
|
13
|
+
The above copyright notice and this permission notice shall be
|
|
14
|
+
included in all copies or substantial portions of the Software.
|
|
15
|
+
|
|
16
|
+
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
|
|
17
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
18
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
19
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
|
20
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
|
21
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
|
22
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
# create-nextly-app
|
|
2
|
+
|
|
3
|
+
The official CLI for scaffolding a new Nextly CMS project.
|
|
4
|
+
|
|
5
|
+
<p align="center">
|
|
6
|
+
<a href="https://www.npmjs.com/package/create-nextly-app"><img alt="npm" src="https://img.shields.io/npm/v/create-nextly-app?style=flat-square&label=npm&color=cb3837" /></a>
|
|
7
|
+
<a href="https://github.com/nextlyhq/nextly/blob/main/LICENSE.md"><img alt="License" src="https://img.shields.io/github/license/nextlyhq/nextly?style=flat-square&color=blue" /></a>
|
|
8
|
+
<a href="https://nextlyhq.com/docs"><img alt="Status" src="https://img.shields.io/badge/status-alpha-orange?style=flat-square" /></a>
|
|
9
|
+
</p>
|
|
10
|
+
|
|
11
|
+
> [!IMPORTANT]
|
|
12
|
+
> Nextly is in alpha. APIs may change before 1.0. Pin exact versions in production.
|
|
13
|
+
|
|
14
|
+
## Quickstart
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
# pnpm
|
|
18
|
+
pnpm create nextly-app@alpha my-app
|
|
19
|
+
|
|
20
|
+
# npm
|
|
21
|
+
npx create-nextly-app@alpha my-app
|
|
22
|
+
|
|
23
|
+
# yarn
|
|
24
|
+
yarn create nextly-app@alpha my-app
|
|
25
|
+
|
|
26
|
+
# bun
|
|
27
|
+
bun create nextly-app@alpha my-app
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
The CLI walks you through:
|
|
31
|
+
|
|
32
|
+
1. Project name (or `.` to install in the current directory)
|
|
33
|
+
2. Template (`blank` or `blog`)
|
|
34
|
+
3. Schema approach (`code-first` or `visual`), only for templates that support both
|
|
35
|
+
4. Database (`sqlite`, `postgresql`, or `mysql`)
|
|
36
|
+
5. Database connection string (skipped for SQLite)
|
|
37
|
+
|
|
38
|
+
After scaffolding, `pnpm dev` runs the project. Visit [http://localhost:3000/admin/setup](http://localhost:3000/admin/setup) to create the first admin user.
|
|
39
|
+
|
|
40
|
+
## Templates
|
|
41
|
+
|
|
42
|
+
| Template | Description |
|
|
43
|
+
| --------- | ----------------------------------------------------------------------------------- |
|
|
44
|
+
| **blank** | Empty config. Define your own collections from scratch. |
|
|
45
|
+
| **blog** | Posts, categories, tags, frontend pages, RSS, sitemap, and admin-editable homepage. |
|
|
46
|
+
|
|
47
|
+
More templates (portfolio, e-commerce, SaaS admin) are planned.
|
|
48
|
+
|
|
49
|
+
## Schema approaches
|
|
50
|
+
|
|
51
|
+
| Approach | Description |
|
|
52
|
+
| -------------- | --------------------------------------------------------------------------------------------------------- |
|
|
53
|
+
| **code-first** | Schemas live in `nextly.config.ts` plus files under `src/collections/`. Type-safe and version-controlled. |
|
|
54
|
+
| **visual** | Schemas are defined in the Admin UI's Schema Builder. Stored in the database. |
|
|
55
|
+
|
|
56
|
+
The two approaches are not mutually exclusive: a code-first project can add UI-defined collections later, and vice versa.
|
|
57
|
+
|
|
58
|
+
## Non-interactive usage
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
# Blog with code-first approach
|
|
62
|
+
pnpm create nextly-app@alpha my-blog --template blog --approach code-first
|
|
63
|
+
|
|
64
|
+
# Blank project with PostgreSQL
|
|
65
|
+
pnpm create nextly-app@alpha my-app --template blank --database postgresql
|
|
66
|
+
|
|
67
|
+
# Skip prompts entirely (defaults: blank, SQLite, local storage)
|
|
68
|
+
pnpm create nextly-app@alpha my-app -y
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
## CLI flags
|
|
72
|
+
|
|
73
|
+
| Flag | Short | Description | Default |
|
|
74
|
+
| ------------------- | ----- | ------------------------------------------------------------ | ------------------ |
|
|
75
|
+
| `--yes` | `-y` | Skip prompts and use defaults (blank, SQLite, local storage) | `false` |
|
|
76
|
+
| `--template <name>` | `-t` | Project template: `blank`, `blog` | Interactive prompt |
|
|
77
|
+
| `--approach <type>` | `-a` | Schema approach: `code-first`, `visual` | Interactive prompt |
|
|
78
|
+
| `--database <db>` | `-d` | Database: `sqlite`, `postgresql`, `mysql` | Interactive prompt |
|
|
79
|
+
| `--branch <branch>` | `-b` | Git branch for template download | `main` |
|
|
80
|
+
| `--version` | `-V` | Print the CLI version | |
|
|
81
|
+
| `--help` | `-h` | Show help text | |
|
|
82
|
+
|
|
83
|
+
Run `pnpm create nextly-app@alpha --help` for the inline reference.
|
|
84
|
+
|
|
85
|
+
<details>
|
|
86
|
+
<summary><strong>Contributor flags</strong> (development only)</summary>
|
|
87
|
+
|
|
88
|
+
These flags exist for Nextly maintainers and contributors working on the framework locally. They are not intended for end-user projects and are not covered by the alpha-stability promise.
|
|
89
|
+
|
|
90
|
+
| Flag | Description |
|
|
91
|
+
| ------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
92
|
+
| `--local-template <path>` | Read templates from a local filesystem path instead of downloading them from GitHub. |
|
|
93
|
+
| `--skip-install` | Skip the dependency-installation step. Useful when testing the scaffolder against unpublished package versions. |
|
|
94
|
+
| `--use-yalc` | Install Nextly packages from a local [yalc](https://github.com/wclr/yalc) store instead of npm. Used for end-to-end testing of unpublished changes. |
|
|
95
|
+
|
|
96
|
+
See [CONTRIBUTING.md](https://github.com/nextlyhq/nextly/blob/main/CONTRIBUTING.md) for the local development workflow.
|
|
97
|
+
|
|
98
|
+
</details>
|
|
99
|
+
|
|
100
|
+
## Documentation
|
|
101
|
+
|
|
102
|
+
- [**Quick start**](https://nextlyhq.com/docs/getting-started/quick-start)
|
|
103
|
+
- [**Installation**](https://nextlyhq.com/docs/getting-started/installation)
|
|
104
|
+
- [**Project structure**](https://nextlyhq.com/docs/getting-started/project-structure)
|
|
105
|
+
- [**Templates**](https://nextlyhq.com/docs/templates)
|
|
106
|
+
|
|
107
|
+
## See also
|
|
108
|
+
|
|
109
|
+
- [`nextly`](https://github.com/nextlyhq/nextly/tree/main/packages/nextly): the core framework this CLI scaffolds.
|
|
110
|
+
- The [Nextly monorepo](https://github.com/nextlyhq/nextly) for the full ecosystem of packages.
|
|
111
|
+
|
|
112
|
+
## Community
|
|
113
|
+
|
|
114
|
+
- [**GitHub Discussions**](https://github.com/nextlyhq/nextly/discussions) for questions, ideas, and show-and-tell
|
|
115
|
+
- [**Issues**](https://github.com/nextlyhq/nextly/issues) for bug reports and feature requests
|
|
116
|
+
- [**Discord**](https://discord.gg/hJUg9AZMn) for real-time chat with the team and other users
|
|
117
|
+
- [**Contributing guide**](https://github.com/nextlyhq/nextly/blob/main/CONTRIBUTING.md) for local setup, the dev workflow, and PR conventions
|
|
118
|
+
|
|
119
|
+
## Contributing
|
|
120
|
+
|
|
121
|
+
Contributions of every size are welcome. Start with the [Contributing guide](https://github.com/nextlyhq/nextly/blob/main/CONTRIBUTING.md) for local setup and PR conventions.
|
|
122
|
+
|
|
123
|
+
## Telemetry
|
|
124
|
+
|
|
125
|
+
The Nextly CLI (`create-nextly-app` and `nextly`) collects anonymous usage data to help us improve the tool. No personal information, project contents, file paths, or secrets are collected. Telemetry is automatically disabled in CI, Docker, production, and non-interactive shells.
|
|
126
|
+
|
|
127
|
+
See [nextlyhq.com/docs/telemetry](https://nextlyhq.com/docs/telemetry) for the full list of what is and is not collected, and for instructions on opting out (`nextly telemetry disable` or `NEXTLY_TELEMETRY_DISABLED=1`).
|
|
128
|
+
|
|
129
|
+
## License
|
|
130
|
+
|
|
131
|
+
[MIT](https://github.com/nextlyhq/nextly/blob/main/LICENSE.md). Free to use, modify, and distribute.
|