Skip to content

Plugin output schemeΒ #4

@paul-sachs

Description

@paul-sachs

Less an issue and more of a discussion point. I've noticed the scheme for our generated file structure looks like:

import {
  deleteOrganizationByName,
  listOrganizations,
} from "@bufbuild/apigen/buf/alpha/registry/v1alpha1/organization-OrganizationService_connectquery";

I love that we can just import the specific methods we use, which can reduce bundle size, but I wonder about the scheme of {service}-{serviceName}_connectquery. Since this is effectively an api surface, maybe it makes sense to instead do:

import {
  deleteOrganizationByName,
  listOrganizations,
} from "@bufbuild/apigen/buf/alpha/registry/v1alpha1/organization_connectquery/organization_service";

This way we can stay consistent with our existing plugins which generate one file/folder for each protofile. And we can just nest the multiple services inside.

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