Standard library
Import a standard module with use:
use json
use fs
def main():
match fs.read("config.json"):
case Ok(text):
print(json.parse(text))
case Err(why):
print(why)| Module | Use it for |
|---|---|
json | parse and write JSON |
csv | read and write CSV rows |
fs | files, directories, images, and append-only writes |
http | HTTP requests with safe defaults |
sql | SQLite queries |
time | clocks and durations |
re | regular expressions |
env | environment variables |
notes | durable run scratch space |
pdf | extract PDF text and pages |
See the standard library reference for function signatures and capability requirements.
Last updated on