createFile
Requires a Node.js runtime ('qsu/node')Create a file of empty data. If the same file already exists, it is ignored.
Any parent directory the path needs is created along with the file.
A path that is empty or nothing but whitespace does nothing, so an empty form field does not become a file literally named .
Parameters
| Name | Type | Required | Default |
|---|---|---|---|
filePath | stringStringstr | ● | – |
| File or directory path | |||
Returns
Promise<void>
Future<void>
None
Examples
javascript
await createFile('/home/user/test.txt');dart
await createFile('/home/user/test.txt');python
createFile('/home/user/test.txt')