About Placeholder API
It's a small, JIJ-able API that allows creation and parsing placeholders within strings and Minecraft Text Components.
Placeholder API uses a simple format of %modid:type% or %modid:type data% (%modid:type/data% prior to 1.19).
It also includes simple, general usage text format indented for simplifying user input in configs/chats/etc.
For users
It allows users to configure multiple mods in similar way without losing compatibility between mods. Placeholders allow changing what and where any information is present within compatible mods.
Additionally, Simplified Text Format allows to style them in readable way without the requirement of writing JSON manually or using generators.
Mods generally using this api should just include it directly, but you can downloaded updated version from here if needed!
For developers
Usage of Placeholder API is a simple way to achieve good mod compatibility without having to implement multiple mod specific apis. Additionally, the placeholder parsing system can be used for replacing own static (or dynamic placeholders) in Text created by player or read from config. This with combination of Simplified Text Format allows creating great user/admin experience.
- Getting Started
- Adding placeholders
- Parsing placeholders
- TextNodes and NodeParsers
- Using Simplified Text Format (TextParserV1)
*[JIJ]: Jar-in-Jar
All Versions
+ Add Version| Name | Game version | Platforms | Published | Downloads | Actions |
|---|---|---|---|---|---|
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 | ||||
| 20h ago | 1 |
- Bump Gradle, Fix build.yml, etc by @sakura-ryoko in https://github.com/Patbox/TextPlaceholderAPI/pull/93
- Create zh_cn.json by @NumberSir in https://github.com/Patbox/TextPlaceholderAPI/pull/63
- 🌐 add Argentine Spanish localization by @Texaliuz in https://github.com/Patbox/TextPlaceholderAPI/pull/77
- Added language support for Turkish with tr_tr.json by @Runteryaa in https://github.com/Patbox/TextPlaceholderAPI/pull/84
- Create uk_ua.json by @StarmanMine142 in https://github.com/Patbox/TextPlaceholderAPI/pull/94
## New Contributors
- @NumberSir made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/63
- @Texaliuz made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/77
- @Runteryaa made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/84
- @StarmanMine142 made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/94
For migration, most notable changes:
What previously was PlaceholderContext was moved to ServerPlaceholderContext, and alike (ParserBuilder changed placeholders() -> serverPlaceholders()) for those who want previous features.
Renamed getText and alike to getComponent. TextNodes are still TextNodes through.
- Add player head texture argument by @DrexHD in https://github.com/Patbox/TextPlaceholderAPI/pull/87
- Fix parsing during server start by @arvitus in https://github.com/Patbox/TextPlaceholderAPI/pull/83
## New Contributors
- @arvitus made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/83
- Fix objective_name_top & objective_score_top not sorted correctly (issue #75) by @ItsJustMiaouss in https://github.com/Patbox/TextPlaceholderAPI/pull/76
## New Contributors
- @ItsJustMiaouss made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/76
- Update to 25w14craftmine. by @Mikarific in https://github.com/Patbox/TextPlaceholderAPI/pull/74
## New Contributors
- @Mikarific made their first contribution in https://github.com/Patbox/TextPlaceholderAPI/pull/74
- Ensure parser is deterministic by @DrexHD in https://github.com/Patbox/TextPlaceholderAPI/pull/67
- Port to 1.21.5-pre3+ by @sakura-ryoko in https://github.com/Patbox/TextPlaceholderAPI/pull/70
- Update to 1.21.2 by @DrexHD in https://github.com/Patbox/TextPlaceholderAPI/pull/57
- Update mod-placeholders.md by @sakura-ryoko in https://github.com/Patbox/TextPlaceholderAPI/pull/49
- AfkPlus 1.4.2 updates by @sakura-ryoko in https://github.com/Patbox/TextPlaceholderAPI/pull/52
- Update to 1.21-pre2 by @sakura-ryoko in https://github.com/Patbox/TextPlaceholderAPI/pull/55