Skip to main content

A lightweight Python library to parse and lazily resolve Nuxt 3 _payload.json files.

Project description

nuxt-payload

A lightweight Python library to parse and lazily resolve Nuxt 3 _payload.json files.

Installation

pip install nuxt-payload

## Usage

from nuxt_payload import load_payload

# Load a Nuxt 3 _payload.json file
data = load_payload("_payload.json")

# Access elements lazily
first_item = data[0]

# If the item contains LazyRef, force resolution
print(first_item["id"].resolve())

# Iterate over a lazy dictionary
for key, value in first_item.items():
    print(key, value.resolve() if hasattr(value, "resolve") else value)

License

This project is licensed under the GNU Affero General Public License v3.0 or later (AGPL-3.0).

See LICENSE for details.

Authors

See AUTHORS.md for the list of contributors.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nuxt_payload-0.1.1-py3-none-any.whl (14.6 kB view details)

Uploaded Python 3

File details

Details for the file nuxt_payload-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: nuxt_payload-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 14.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.6

File hashes

Hashes for nuxt_payload-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 330483af323ccfa8d0f51f0a9fb0c561731860a96c1a78c1c3db424a54e4697c
MD5 8b40752e73e0363337744dfafec3538d
BLAKE2b-256 1a6942909afccc2929b2a72d41530b069d1ba81dd6ed2f54619646f66ce36239

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page