From adcc3f90e64ea0bda98af8f8960574466e69b88e Mon Sep 17 00:00:00 2001 From: Aaron S Date: Thu, 10 Oct 2024 16:22:18 -0500 Subject: [PATCH] Add internal docs for exported behavior --- packages/appsync-modelgen-plugin/src/plugin.ts | 3 +++ packages/appsync-modelgen-plugin/src/preset.ts | 3 +++ packages/appsync-modelgen-plugin/src/types/sync.ts | 3 +++ packages/graphql-generator/src/models.ts | 3 +++ 4 files changed, 12 insertions(+) diff --git a/packages/appsync-modelgen-plugin/src/plugin.ts b/packages/appsync-modelgen-plugin/src/plugin.ts index e66e9c14..52738812 100644 --- a/packages/appsync-modelgen-plugin/src/plugin.ts +++ b/packages/appsync-modelgen-plugin/src/plugin.ts @@ -11,6 +11,9 @@ import { AppSyncModelDartVisitor } from './visitors/appsync-dart-visitor'; import { AppSyncModelIntrospectionVisitor } from './visitors/appsync-model-introspection-visitor'; import { SyncTypes } from './types/sync'; +/** + * @internal + */ export const pluginSync: SyncTypes.PluginFunction = ( schema: GraphQLSchema, rawDocuments: Types.DocumentFile[], diff --git a/packages/appsync-modelgen-plugin/src/preset.ts b/packages/appsync-modelgen-plugin/src/preset.ts index c27a16e3..267342d4 100644 --- a/packages/appsync-modelgen-plugin/src/preset.ts +++ b/packages/appsync-modelgen-plugin/src/preset.ts @@ -351,6 +351,9 @@ const buildGenerations = (options: PresetFnArgs): GenerateOptions[] => { } }; +/** + * @internal + */ export const presetSync: SyncTypes.OutputPreset = { buildGeneratesSection: (options: SyncTypes.PresetFnArgs): SyncTypes.GenerateOptions[] => { const {cache, pluginMap, ...otherOptions} = options; diff --git a/packages/appsync-modelgen-plugin/src/types/sync.ts b/packages/appsync-modelgen-plugin/src/types/sync.ts index e1dfc05f..550d83ad 100644 --- a/packages/appsync-modelgen-plugin/src/types/sync.ts +++ b/packages/appsync-modelgen-plugin/src/types/sync.ts @@ -17,6 +17,9 @@ export type SyncCache = Omit & { cache?: ((namespace: string, key: string, factory: () => T) => T) | undefined }; +/** + * @internal + */ export declare namespace SyncTypes { type GenerateOptions = SyncCache>; diff --git a/packages/graphql-generator/src/models.ts b/packages/graphql-generator/src/models.ts index fd85cfcd..b1b5c836 100644 --- a/packages/graphql-generator/src/models.ts +++ b/packages/graphql-generator/src/models.ts @@ -82,6 +82,9 @@ export async function generateModels(options: GenerateModelsOptions): Promise outputs.reduce((curr, next) => ({ ...curr, ...next }), {})); } +/** + * @internal + */ export function generateModelsSync(options: GenerateModelsOptions): GeneratedOutput { const appsyncLocalConfig = appSyncDataStoreCodeGen.presetSync.buildGeneratesSection({ ...mapBuilderOptions(options),