Replies: 1 comment 1 reply
-
@Antonytm this is a fair request, but please let me clarify your usecase a little. I think this is one of the reasons rootItemId was not made part of configuration - the resolver used in internal JSS logic should get it for you, as long as your site's root template is /sitecore/templates/Foundation/JavaScript Services/App |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Is your suggestion related to a problem? Please describe.
I have a question about this part of the code in
dictionary-servce-factory.ts
:I majorly worked with Next.js implementations and I almost always needed to specify
rootItemId
.For a major part of cases, I moved this setting to configuration/environment variables.
I think that it will be convenient to move
rootItemId
to the configuration. (environment variables)But that wasn't done for any of the web frameworks. I guess that there is some reason for that that I miss.
What is the reason for avoiding
rootItemId
in the configuration?Describe the solution you'd like
I want
rootItemId
to be present together with other configurable settings: sitecoreApiKey, sitecoreApiHost, jssAppName, etc.Is there a way to achieve this functionality with exisiting tools?
Yes.
You can write code by yourself. Usually, I change config generation to work with
rootItemId
in a similar way as with other configurations. (sitecoreApiKey, sitecoreApiHost, etc.)Additional information
If you are interested in this change, I will be able to implement it.
As it is looks like an easy change. Only the testing for different frameworks may take additional time.
Beta Was this translation helpful? Give feedback.
All reactions