INNER CODE UNIT · TypeScript

generateTerraformAttribute

jianyuan/terraform-provider-sentry · internal/providergen/index.ts:18

function generateTerraformAttribute({
  parent,
  attribute,
}: {
  parent: string;
  attribute: Attribute;
}) {
  const parts: string[] = [];

  if (attribute.enum) {
    parts.push(`${tfEnumWrapperFunction(attribute)}(`);
  }

  parts.push(`${tfSchemaAttributeType({ type: attribute.type })}{`);

  parts.push(
    `MarkdownDescription: ${JSON.stringify(tfAttributeDescription(attribute))},`,
  );

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…