Skip to content

Commit 69ee654

Browse files
committed
Improving README.md
1 parent 33b78cc commit 69ee654

File tree

2 files changed

+27
-14
lines changed

2 files changed

+27
-14
lines changed

packages/astro/README.md

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,62 +1,75 @@
11
# Schematics for astro
22

3-
These schematics allow you to automate daily task as: Create components, layouts and pages.
3+
Astro Schematics streamlines your development workflow by automating routine tasks. Easily create components, layouts, and pages with our tools, supercharged by Project Builder.
44

5-
This schematics are powered by [Project Builder](https://schematics.pbuilder.dev/)
6-
7-
We recommend to add this library to your astro project:
5+
To integrate this powerful toolkit into your Astro project, execute:
86

97
```sh
108
npx @pbuilder/cli add @pbuilder/astro
119
```
1210

13-
## Note
11+
## Important Notes
12+
13+
* **CLI Installation:** Running the command above might prompt you to install the CLI. This is highly recommended as the CLI significantly simplifies the creation process for components, layouts, and pages beyond the capabilities of the generic `@pbuilder/cli`.
1414

15-
You will notice that the previous command will tell you if you want to install a CLI, the reason is because the CLI will help you to create: components, layouts and pages easier than if you use the generic @pbuilder/cli CLI.
15+
* **Discoverability:** For detailed command options, append `--help` to learn about all the available parameters and flags.
1616

17-
## Note 2
17+
## Quickstart Guides
1818

19-
For any command that you want to know the allowed options you can use the flag: `--help`.
19+
### Creating Components
2020

21-
## Create components
21+
To generate a new component, use:
2222

2323
```sh
2424
pastro g c <component-name>
2525
```
2626

27+
Or, for a direct approach:
28+
2729
```sh
2830
npx @pbuilder/astro-cli g c <component-name>
2931
```
3032

3133
## Create layouts
3234

35+
Generate a new layout by running:
36+
3337
```sh
3438
pastro g l <layout-name>
3539
```
3640

41+
Alternatively:
42+
3743
```sh
3844
npx @pbuilder/astro-cli g l <layout-name>
3945
```
4046

4147
## Create Pages
4248

49+
For page creation, specify the type and layout:
50+
4351
```sh
4452
pastro g p <page-name> --type [md, mdx, astro] --layout <layout file name>
4553
```
4654

55+
Or use the direct method:
56+
4757
```sh
4858
npx @pbuilder/astro-cli g p <page-name> --type [md, mdx, astro] --layout <layout file name>
4959
```
5060

51-
## Using schematics without the pastro cli
61+
## Beyond the CLI
5262

53-
You can use the generic cli for schematics named `pbuilder`. The reason is because some schematics no matter the frameworks you can will use them in every Javascript envioriment.
63+
## Utilizing Generic Schematics
64+
65+
For projects that don't directly utilize `pastro` CLI, the `pbuilder` CLI remains versatile across different JavaScript environments:
5466

5567
```sh
56-
npx @pbuilder/cli exec @pbuilder/astro <schematic-name(page, component, layout)> --name=<name> [options]
68+
npx @pbuilder/cli exec @pbuilder/astro <schematic-name> --name=<name> [options]
69+
5770
```
5871

59-
For example:
72+
For instance, to create a component:
6073

6174
```sh
6275
npx @pbuilder/cli exec @pbuilder/astro c --name=MyComponent2

packages/astro/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pbuilder/astro",
3-
"version": "1.1.2",
3+
"version": "1.1.3",
44
"description": "A set schematics for astro",
55
"scripts": {
66
"build": "rollup -c --bundleConfigAsCjs",

0 commit comments

Comments
 (0)