This package provides the ability to encode Golang structs to a buffer as JSON. Buffer is a simple custom buffer type that complies with io.Writer. Its main benefit is that it has a pooling built-in. This goes a long way to helping make jingo fast by reducing its allocations and ensuring good write speeds. When you create an instance of an encoder it recursively generates an instruction set that defines how to iteratively encode your structs. This gives it the ability to provide a clear API but with the same benefits as a build-time optimized encoder. It's almost exclusively able to do all types of assertions and reflection activity during the compile, then makes ample use of the unsafe package during the instruction-set execution (the Marshal call) to make reading and writing very fast.

Features

  • It's very fast. (We can't find a faster one)
  • Very low allocs, 0 in a lot of cases
  • Clear API - similar to the stdlib
  • No other library dependencies
  • It doesn't require a build step, like go generate
  • It just uses struct tags.

Project Samples

Project Activity

See All Activity >

Categories

JSON

License

Apache License V2.0

Follow Jingo

Jingo Web Site

Other Useful Business Software
$300 in Free Credit Towards Top Cloud Services Icon
$300 in Free Credit Towards Top Cloud Services

Build VMs, containers, AI, databases, storage—all in one place.

Start your project in minutes. After credits run out, 20+ products include free monthly usage. Only pay when you're ready to scale.
Get Started
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Jingo!

Additional Project Details

Programming Language

Go

Related Categories

Go JSON Software

Registered

2023-10-20