Skip to content

Best practices for package containing many JSON files #1146

@sffc

Description

@sffc

We're looking into whether we can make the CLDR JSON packages more friendly. Currently, we ship packages on npm such as cldr-core which contain no code, not even an index.js file, but contain JSON files that can be loaded via require.resolve or similar.

My understanding is that JSR aims to support packages such as cldr-core that contain primarily JSON data files. (If this is not the case, this issue can be closed.)

Are there best practices on how to structure this type of package?

I've read the JSR docs page on exports, which suggests that perhaps we could add a registry of all the JSON files. Is this an ergonomic and efficient solution? How would that work when publishing to npm?

CC @srl295

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status

    Needs Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions