dohomi / storyblok-generate-ts

Generates TypeScript interface types based on Storyblok component file
MIT License
102 stars 33 forks source link

Tell user what format `Space ID` should be in #49

Closed tohrxyz closed 1 year ago

tohrxyz commented 1 year ago

Hey, so I've tried to generate types for storyblok components and it asked me to specify my space id . So I went to storyblok and copied #XXXXXX and put it inside [ ] like --space=[#XXXXXX]. It let me input that there, but created a file components.[#XXXXXX].json , but ofcourse this didn't work, the json was empty of components (none were there).

It took me a minute to realize that the cli tool maybe wants a different format of space id, so I've tried without # like [XXXXXX] , didn't work either.

So another approach was without those brackets like --space=XXXXXX and it finally worked. I'm not saying that I wasn't dumb for not realizing it on the first try, but your tool probably should notify user that the space id needs to be in particular format. It should even reject the wrong format.

Anywas, apart from this small issue, thanks for an awesome tool :)

dohomi commented 1 year ago

Hey after all the years this plugin is online you are the first person raising this issue. I created a small example to make sure people will know that it is just the numeric ID of a space ID