Skip to content

Commit

Permalink
Allow more types to be converted to TypeScript
Browse files Browse the repository at this point in the history
  • Loading branch information
azimux committed Jan 22, 2024
1 parent 0bd37c3 commit 874c7df
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/remote_generator/services/base_generator.rb
Original file line number Diff line number Diff line change
Expand Up @@ -271,18 +271,12 @@ def foobara_type_to_ts_type(
return dependency_group.non_colliding_type(error_generator)
end

if type_declaration.relevant_manifest.size > 1
# :nocov:
raise "Converting a #{type_declaration.inspect} to a TS type yet supported"
# :nocov:
end

type_symbol = type_declaration.type

type_string = case type_symbol
when "string", "boolean"
type_symbol
when "integer"
when "number", "integer", "float"
"number"
# TODO: should apply relevant processors to make email a real email type instead of "string"
when "symbol", "email"
Expand Down

0 comments on commit 874c7df

Please sign in to comment.