Skip to content

Commit aa812f9

Browse files
committed
docs(mods): update index.md
1 parent 9daa7e0 commit aa812f9

1 file changed

Lines changed: 20 additions & 11 deletions

File tree

‎docs/src/mods/index.md‎

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,21 @@
1414
</a>
1515
</p>
1616

17-
`mods` is a comprehensive Lua utility library featuring predictable APIs, lazy-loaded inter-module dependencies, and wide Lua runtime compatibility.
17+
`mods` is a comprehensive Lua utility library featuring lazy-loaded modules and
18+
wide runtime compatibility.
1819

1920
## ✨ Features
2021

21-
- **Predictable APIs**: Standard utility functions for strings, tables, filesystem paths, lists, sets, and template rendering.
22-
- **Lazy Loading**: Automatic lazy loading of sub-modules to keep startup times fast.
22+
- **Predictable APIs**: A cohesive collection of helper utilities for common
23+
programming tasks and data structures.
24+
- **Lazy Loading**: Automatic lazy loading of sub-modules to keep startup times
25+
fast.
2326
- **Cross-Platform**: Works consistently across Windows, macOS, and Linux.
24-
- **Multiple Lua Versions**: Compatible with LuaJIT, Lua 5.1, 5.2, 5.3, 5.4, and 5.5.
27+
- **Multiple Lua Versions**: Compatible with LuaJIT, Lua 5.1, 5.2, 5.3, 5.4, and
28+
5.5.
29+
- **Lightweight**: Pure Lua with no dependencies, except optional [LFS] for file
30+
operations.
31+
- **Autocomplete**: [LuaLS] type annotations.
2532

2633
## 📦 Installation
2734

@@ -40,14 +47,16 @@ luarocks install mods
4047
```lua [example.lua]
4148
local mods = require "mods"
4249

43-
-- Use the lazy-loaded stringcase sub-module
44-
local title = mods.stringcase.titlecase("hello world")
45-
print(title) -- Output: Hello World
50+
local stripped = mods.str.strip(" hello world ")
51+
print(stripped) -- Output: "hello world"
4652

47-
-- Use the lazy-loaded List class
48-
local items = mods.List { 1, 2, 3 }
49-
local doubled = items:map(function(x) return x * 2 end)
50-
print(doubled:join(", ")) -- Output: 2, 4, 6
53+
local items = mods.list({ 1, 2, 3 })
54+
local reversed = items:reverse()
55+
print(reversed:join(", ")) -- Output: "3, 2, 1"
5156
```
5257

5358
:::
59+
60+
[documentation]: https://bluelua.github.io/mods
61+
[LFS]: https://github.com/lunarmodules/luafilesystem
62+
[LuaLS]: https://github.com/LuaLS/lua-language-server

0 commit comments

Comments
 (0)