Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
[elm] Add signature to enum variants
  • Loading branch information
eriktim committed Jan 24, 2020
commit afb94d3d548e960efdf19e19a3134788796b6dd1
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ type {{^paramName}}{{classname}}{{/paramName}}{{enumName}}
{{/allowableValues}}


{{#lambda.camelcase}}{{^paramName}}{{classname}}{{/paramName}}{{enumName}}{{/lambda.camelcase}}Variants : List {{^paramName}}{{classname}}{{/paramName}}{{enumName}}
{{#lambda.camelcase}}{{^paramName}}{{classname}}{{/paramName}}{{enumName}}{{/lambda.camelcase}}Variants =
{{#allowableValues}}
{{#enumVars}}
Expand Down
2 changes: 2 additions & 0 deletions samples/openapi3/client/elm/src/Api/Data.elm
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ type Enum
| EnumBaz


enumVariants : List Enum
enumVariants =
[ EnumFoo
, EnumBar
Expand All @@ -153,6 +154,7 @@ type Enumeric
| Enumeric3


enumericVariants : List Enumeric
enumericVariants =
[ Enumeric1
, Enumeric2
Expand Down
3 changes: 3 additions & 0 deletions samples/openapi3/client/elm/src/Api/Request/Default.elm
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ type HeaderType
| HeaderTypeRight


headerTypeVariants : List HeaderType
headerTypeVariants =
[ HeaderTypeLeft
, HeaderTypeRight
Expand All @@ -57,6 +58,7 @@ type Enumeration
| EnumerationC


enumerationVariants : List Enumeration
enumerationVariants =
[ EnumerationA
, EnumerationB
Expand Down Expand Up @@ -85,6 +87,7 @@ type Enum
| EnumC


enumVariants : List Enum
enumVariants =
[ EnumA
, EnumB
Expand Down