AngelMunoz/Perla

jsonc defaults explicit on new project and in samples.

ImaginaryDevelopment opened this issue · 2 comments

Is your feature request related to a problem? Please describe.
Certain defaults (possibly all defaults) would be better served to be included in the jsonc file. Especially the outdir setting.

Describe the solution you'd like
I'd like all defaults to be included, but especially ones like outdir that are likely to need changing if I want to use github pages.

Describe alternatives you've considered
I've considered needing to go to documentation for each key and keeping that page up to refer back to defaults, but why not include them in the file? I've been on a cruise ship before with little to no internet and would have been out of luck.

Perhaps it could be a template preference defaulting to omit none :)
Additional context
You axed for this issue to be created on discord.

I've been thinking about this I'm not too keen on adding all of the configuration properties by default, this tends to be quite noisy and it could intimidate new users on thinking that the tool is too complex

I think a more streamlined solution would be to include a describe command that would indeed write a full or partial description of the requested file to the console e.g.

  • perla describe perla.jsonc -k full

    This would print to the console the full file with all of the existing properties and corresponding description we already have those in perla's json schema

  • perla describe perla.jsonc -k property fable

  • perla describe perla.jsonc -k property devServer

    These would print the options that exist for the requested property in case the user is already somewhat familiar with a particular configuration property

This would allow us to continue using a conventions based config file and still providing easy access to some degree of documentation

Support for this command has been added in the dev branch!