Skip to content

Commit 00d2db8

Browse files
committed
Improved hooks documentation
1 parent c89e9b2 commit 00d2db8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

extending-cli.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
Extending the CLI
22
=================
33

4-
NativeScript CLI allows you to extend its behavior and customize it for your project.
5-
When the CLI executes a particular command (for example `tns build`) it checks whether you have added such extending hooks and executes them.
4+
NativeScript CLI allows you to extend its behavior and customize it according to your needs.
5+
Each time the CLI executes a particular command (for example `tns build`) it checks whether you have added any extending hooks and executes them.
66
Additionally, plugins can use these hooks to control the compilation of the program.
77

88
What are the hooks
99
==================
1010

11-
The hooks are any executable code, Node.js script or a directory placed under the `hooks` subdirectory of your project.
12-
The hook name must follow a strict scheme. The name describes:
11+
Hooks can be executable code, Node.js script, or even a directory containing other files. To be executed however, the hooks must be placed under the `hooks` subdirectory of your project.
12+
The hook name must follow a strict scheme, describing:
1313

1414
- the action being hooked
1515
- whether the user code must be called before or after the action
@@ -29,8 +29,8 @@ my-app/
2929
└── after-prepare (this is an executable file)
3030
```
3131

32-
To support multiple scripts extending the same action, you can use a different approach. Create a sud-directory in the `hooks` directory using the naming convention described above.
33-
Place all extending code into it. The CLI will execute them one after another but the order is not guaranteed.
32+
To support multiple scripts extending the same action, you ccan create a sud-directory in the `hooks` directory using the naming convention described bellow.
33+
Tehn place the extending code into it. The CLI will execute them one after another but the order is not guaranteed.
3434

3535
```
3636
my-app/

0 commit comments

Comments
 (0)