Allow config of templating util settings from app directly #1782
philipbushnell-valtech
started this conversation in
Ideas
Replies: 1 comment 3 replies
|
@philipbushnell-valtech sounds like we have been trying to implement something similar to this. I have added these details to our backlog for review. |
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Is your suggestion related to a problem? Please describe.
In sitecore-jss-dev-tools/src/templating/utils.ts there are settings for finer control over how items are retrieved yet these settings are not configurable beyond their internal usages (e.g. in sitecore-jss-dev-tools/src/templating/components.ts).
In our app, we have additional co-located files alongside our components (e.g. for testing) but without being able to change the
fileFormatsetting, it fails our build due to it outputting irrelevant files in the generatedcomponentBuilderfile (and things such as test globals likedescribeare not being explicitly imported so fail).Describe the solution you'd like
It would be massively helpful if these could be configured from the application directly (e.g. via generateComponentBuilder). It should be relatively quick to update function params to allow better customisation.
Is there a way to achieve this functionality with exisiting tools?
I've had to
patch-packagea regex setting change to work around this issue but it would be much better to just configure the settings directly in the app (i.e. inscripts/generate-component-builder/plugins/component-builder.ts) but I can't.Additional information
Copied over from #1775 where I incorrectly raised this.
All reactions