Mineuniverse
Log in Register
Mods

FASTJSON2 Serializer for YACL

A config serializer for YetAnotherConfigLib using FASTJSON2
by VesMaybeVesper
Download Claim this project
202 downloads
0 likes
Updated Jul 6, 2026
0 hypes
API and Library Utility & QoL

A serializer for YetAnotherConfigLib made using FASTJSON2.

Useage

Add as a dependancy as outlined on the version page*

// >= 1.21.11
    public static ConfigClassHandler<Config> HANDLER = ConfigClassHandler.createBuilder(Config.class)
            .id(Identifier.fromNamespaceAndPath(MOD_ID, "config"))
            .serializer(config -> FastJsonConfigSerializerBuilder.create(config)
                    .setPath(YACLPlatform.getConfigDir().resolve("modid.json"))
                    .build())
            .build();

// <= 1.21.10
    public static ConfigClassHandler<Config> HANDLER = ConfigClassHandler.createBuilder(Config.class)
            .id(ResourceLoccation.fromNamespaceAndPath(MOD_ID, "config"))
            .serializer(config -> FastJsonConfigSerializerBuilder.create(config)
                    .setPath(YACLPlatform.getConfigDir().resolve("modid.json"))
                    .build())
            .build();

JSON5

FastJSON2 doesn't offer any support for JSON5. If you need/want JSON5 for any reason, I would suggest continuing to use YACL's built-in Gson serializer.

FAQ

  • Is this faster than using the built-in Gson serializer? 
    • In a word, yes. In a few more words, based on pure library performance, yes. In practice it's a bit harder to say and will likely depend on the size of the config in question. Will it make a massive difference in anything when used in a single mod? Not noticeably; if you get several using it, you may start to see something a bit more tangible.
  • Why make it if it wont improve performance much? 
    • IDK, becuse I can? Free will and what not.
  • WAST has a better score on 3/4 of the tests, why not use it?† 
    • Becuse I am already familiar with FastJSON and didn't need to learn anything new to make it. If I need (or want) to learn WAST one day maybe I'll make something for it then.

*Until I set up another maven
†As of June 28th, 2026

 

FASTJSON2 Serializer for YACL 1.0.0 for 26.1 Neoforge
MC Client, NeoForge, Server, 26.1, 26.1.1, 26.1.2, 26.2
Release 2026-07-03 Get
FASTJSON2 Serializer for YACL 1.0.0 for 26.1 Fabric
MC Client, Fabric, Server, 26.1, 26.1.1, 26.1.2, 26.2
Release 2026-07-03 Get
FastJSONForYACL-1.0.0-beta.1+26.2-fabric.jar
MC Client, Fabric, 26.2
Beta 2026-06-30 Get
FastJSONForYACL-1.0.0-beta.1+26.1-neoforge.jar
MC Client, NeoForge, 26.1, 26.1.1, 26.1.2, 26.2
Beta 2026-06-30 Get

More from VesMaybeVesper

Evening Star Lib
9,182
Shiny Horses Reborn
5,716
Vesper's Compatibility Compendium
5,193
Pale Garden Effects
4,399
Extended Weather Radius
331
Lapis Reserve Reborn
2,709

You Might Also Like

Vivecraft
A Minecraft VR mod on a loader of your choice!
9,988,339
Athena
A crossplatform (Forge/Fabric) solution to connected block textures for 1.19.4+
99,799,527
Lodestone
A collection of code used throughout projects under the Lodestar team.
9,914,417
TheDragonLib
A library for most of sokratis12GR's Mods
9,910,232
Multi Mob Library
A library mod containing essential files for Daveyx0's mob mods
9,892,767
FTB Library (Forge) (Legacy)
FTB Library is a library mod that is used for some of our mods.
98,265,314