spatie / typescript-transformer

Transform PHP types to TypeScript
https://docs.spatie.be/typescript-transformer/v2/introduction/
MIT License
275 stars 35 forks source link

Feature request: Make namespace in ts file optional #55

Closed Ferikl closed 1 year ago

Ferikl commented 1 year ago

Hi Spatie! Thanks for amazing package. I have some issue with generated ts file - our fe guys wants all entities be w\o namespaces.

Something like:

typescript-transformer.php

...
   'preserve_namespaces' => true/false,
.....

Please add this feature

Ferikl commented 1 year ago

resolved by using

'writer' => Spatie\TypeScriptTransformer\Writers\ModuleWriter::class,