New answers tagged

0

As far as I can see, you have pre-optimized-min item created under the folder to which you try to upload custom styles. Did you re-generate pre-optimize-min file after adding your custom one? If SXA will find pre-optimize-min file it will always take it and skip generation of normal optimize-min file. If you want to check if your styles will be included in ...


1

SXA has a custom pipeline called normalizeSearchPhrase which is removing all special characters from the search phrase. All the characters from this HashSet are removed: new HashSet<string> { "-", "+", "&", "|", "!", "{", "}", "[", "]", "^", "(&...


3

If local or page relative SXA data sources are not resolved you need to resolve them manually. Run resolveRenderingDatasource pipeline: ResolveRenderingDatasourceArgs renderingDatasourceArgs = new ResolveRenderingDatasourceArgs(YOUR_DATA_ROURCE_STRING); renderingDatasourceArgs.CustomData.Add("contextItem", CONTEXT_ITEM); CorePipeline.Run("...


0

I don't know how Sitecore.IndexRenderedContent plugin is exactly working but it's definitely not aware of the SXA local data sources (and probably about page relative data sources too). Try to resolve them manually: if (YOUR_DATA_SOURCE.StartsWith(Sitecore.XA.Foundation.LocalDatasources.Constants.PageRelativePrefix, StringComparison....


0

In my case, the solution was to accept cookie of website. However, to make it work without cookie consent, I think you need to go to support since it is bug of Sitecore (https://support.sitecore.com/kb?id=kb_article_view&sysparm_article=KB0647546).


0

SXA JSS sites should not be defined in the configuration files. Instead, they are configured using Sitecore items. Please refer to this article for more details on how to manage JSS apps with SXA. Don't use jss deploy config command on an SXA JSS website. If you use it to deploy config for the graphql endpoint. Ensure the site and apps node are commented. &...


1

It looks like it could not be done with SXA CLI out of the box. But, it is possible to do with modification of SXA gulp scripts. Option 1: Quick and dirty. It is possible to save CSS source map in the same .css file. (it doesn't work for production, but for all other environments it should be OK) Open \node_modules\@sxa\celt\util\cssMinificator.js Change ...


1

In my case, the base template in the Site Node template was missing the _Modules template /sitecore/templates/Foundation/Experience Accelerator/Scaffolding/_Modules So, after adding this, the script error has been resolved.


3

As Mark mentioned in his comment you should use the SXA tokens to achieve this. You can find a list here: https://doc.sitecore.com/en/developers/sxa/101/sitecore-experience-accelerator/the-sxa-pipelines.html Useful ones for sources in templates could be: $tenant - path to the current tenant. $site - path to the current site. $home - path to the current site ...


0

If your depth of data source is is same in both sites. Below should work, query:../data/tag .. is a parent selector. You can increase based on the depth you have. My depth of data source is 1, as mentioned below screenshot. Site1: contains two elements Site2: contains three elements


0

Below is how it worked for me in Sitecore 10 Added resolve="true" in patch file like below: <processor type="Sitecore.Foundation.Multisite.Pipelines.ItemNotFoundMvcHandler, Sitecore.Foundation.Multisite" resolve="true" patch:after="processor[@type='Sitecore.Mvc.Pipelines.Response.GetPageItem.GetFromOldContext, Sitecore....


0

Scriban has some nice date functions built in so you can use those. Unfortunately, Sitecore stores the raw value as yyyMMddThhmmssZ - so 20210709T102600Z for example. This is not a valid format for C#'s DateTime.Parse function, (which is what Scriban uses under the hood). So we need to get a bit sneaky with string parsing. There are 2 options: Option 1: No ...


5

The Page Design that you're seeing isn't processed by the React application, it's just part of the default Item serialization. The power of SXA's Page + Partial Designs will translate into a list of placeholders, components, and nested placeholders in the JSON, no different than a non-SXA site. You need to start off with ensuring your JSS Layout definition ...


3

There are few options: Use Sitecore RESTful API. It doesn't matter SXA or not, but you will be able to get items in JSON format. Use JSON device to get page data. SXA allows you to model your data in JSON. You are able to use special JSON renderings to model data in a way that you need. But even if your website uses default renderings, you can use the SXA ...


Top 50 recent answers are included