mirror of
https://github.com/lune-org/docs.git
synced 2024-12-14 06:00:42 +00:00
27 lines
1.2 KiB
Markdown
27 lines
1.2 KiB
Markdown
# Built-in Libraries
|
|
|
|
Lune contains a large set of built-in libraries, much like Luau itself. These libraries include, but
|
|
are not limited to, these libraries and their common use cases:
|
|
|
|
- The [`fs`](../../api-reference/fs.md) library for manipulating files
|
|
- The [`net`](../../api-reference/net.md) library for making HTTP requests
|
|
- The [`process`](../../api-reference/process.md) library for executing external programs and
|
|
processes
|
|
|
|
This is just a small subset of what is available in Lune, but for now, what is important is that
|
|
these libraries must be imported using a special kind of `require` statement:
|
|
|
|
```lua copy
|
|
local fs = require("@lune/fs")
|
|
local net = require("@lune/net")
|
|
local process = require("@lune/process")
|
|
```
|
|
|
|
As you can see above, unlike Luau's standard libraries such as
|
|
[`math`](https://luau-lang.org/library#math-library),
|
|
[`table`](https://luau-lang.org/library#table-library),
|
|
[`string`](https://luau-lang.org/library#string-library), and others, Lune's built-in libraries are
|
|
not available as global variables and importing them before using them is required (pun intended).
|
|
|
|
The next few sections will contain examples of how to run scripts, more specific usage of Lune's
|
|
built-in libraries, and what they are most commonly used for.
|