mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
docs: add a Disabling the formatting locally
section, about // vfmt off
and // vfmt on
(#17341)
This commit is contained in:
parent
2879c5110c
commit
d616fb0a43
17
doc/docs.md
17
doc/docs.md
@ -4940,6 +4940,23 @@ A vfmt run is usually pretty cheap (takes <30ms).
|
||||
|
||||
Always run `v fmt -w file.v` before pushing your code.
|
||||
|
||||
#### Disabling the formatting locally
|
||||
|
||||
To disable formatting for a block of code, wrap it with `// vfmt off` and
|
||||
`// vfmt on` comments.
|
||||
|
||||
```bash
|
||||
// Not affected by fmt
|
||||
// vfmt off
|
||||
|
||||
... your code here ...
|
||||
|
||||
// vfmt on
|
||||
|
||||
// Affected by fmt
|
||||
... your code here ...
|
||||
```
|
||||
|
||||
### v shader
|
||||
|
||||
You can use GPU shaders with V graphical apps. You write your shaders in an
|
||||
|
Loading…
Reference in New Issue
Block a user