Skip to content
This repository was archived by the owner on Sep 9, 2025. It is now read-only.
This repository was archived by the owner on Sep 9, 2025. It is now read-only.

Request: add main property, or empty index.js #5

@lennym

Description

@lennym

I'm trying to build some modules which depend on this, but since it can't be found with require.resolve() as it has no canonical file it's proving quite difficult to reliably resolve the install location to do fs.readFile etc on it. Looking in ./node_modules works in most cases, but not if the parent project already has this as a dependency.

Either adding a main property in the package.json to point to the template file (ideal scenario for me), or adding a blank (or maybe log a usage warning) index.js file in the root will allow require.resolve('govuk_template_mustache'); to successfully resolve the install location, and so make it easier to build other modules which sit on top of this without needing additional caveats.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions