Questions tagged [jss]
For questions about the Sitecore JavaScriptServices module and JSS CLI.
593
questions
0
votes
2
answers
468
views
Image not working when fetching it with GraphQL in connected mode
This is on sitecore 10 / jss 14.0.1
I'm using JSS in connected mode (jss start:connected) since I will be fetching data with GraphQL. In my graphQL I fetch an image using this code:
item(path: $item)...
2
votes
0
answers
205
views
Personalization on Layout Service not working when calling from JSS App
My Sitecore CD website in IIS is http://cd.my-website.com with a role as ContentDelivery. This site contains Sitecore and custom API code in Headless mode.
The React code for the JSS app is on a ...
0
votes
0
answers
237
views
Failed prop type: Invalid prop `errorComponent` supplied to `PlaceholderComponent`
I'm trying to improve error handling for my app, so I've create a very simple component ErrorComponet.jsx:
import React from "react";
const ErrorComponent = (props) => {
return (<...
0
votes
0
answers
164
views
Sitecore JSS Personalization simple display rule not working
We are using Sitecore 9.1 with JSS and have a fully functional site running using Angular -- all working great. Now, we would like to add personalization to our site. To do so as a simple starting ...
1
vote
1
answer
207
views
JSS Deployed to Docker Container: Links to media files missing port number
When I deploy a JSS app to a Sitecore instance running in a Docker Container and run our applications in Integrated Mode, our application is accessible with a hostname and port number (e.g. http://jss....
1
vote
1
answer
375
views
Sitemap in SXA JSS Site
We are using REACT App in the front end and using capabilities of Sitecore JSS(12.0) for headless view and SXA(1.9).
I have configured settings to get sitemap settings (by inheriting sitemap template ...
1
vote
1
answer
1k
views
Node render engine project directory path '{website-path}\app' does not exist
We reently moved Sitecore First from CodeFirst. Which means we have deployed jss app to the Sitecore. But when we try to open Exprience Editor, we face below issue:
Error Rendering Sitecore....
3
votes
1
answer
288
views
How to create a new JSS angular app with older versions of angular/typescript
I want to create a new JSS app but with older versions of angular and typescript.
I have version 11.0.2 for JSS
and when I run
ng --version
this is what I get
@angular-devkit/build-angular 0.12.4
@...
2
votes
1
answer
715
views
How to handle item not found in jss headless
Our requirement is to show site specific error page if the requested page is not found.
We have handled item not found using HttpRequestBegin pipeline Item resolver. If the context item is null we are ...
2
votes
1
answer
608
views
Unexpected response from import service: Invalid Authentication
I'm trying to perform the command to deploy my application to a remote CM server
jss deploy app --includeContent --includeDictionary
but I receive the following error
Sending package sitecore\package\...
2
votes
0
answers
231
views
A rendering error occurred: Cannot read property 'fields' of undefined
Trying to add RouteType item (as provided in samples on creating a new JSS app).
Once I add in experience editor, it appears fine like below
But as soon as I click save, I got below error message. ...
1
vote
3
answers
451
views
How to run multi language JSS frontend websites on same azure app service?
One of my projects is using Sitecore 9.1.1 & JSS, also Server-Side Rendering (SSR) Mode is running successfully on Azure App Service. Ex. www.example.com - which is an English language website is ...
2
votes
1
answer
340
views
ASP.NET Core RenderingHost in Experience Editor
I'm currently testing Sc10 with ASP.NET Core Rendering Host from the following Getting Started documentation.
So far the rendering host works fine but whenever I want to access the Experience Editor I ...
4
votes
2
answers
1k
views
JSS Component is missing React implementation
Recently we moved from code-first to Sitecore-first approach. After deploying the react and sitecore in Sitecore-first mode, we can't see the renderings on the page.
Getting below error
"JSS ...
2
votes
1
answer
356
views
How to use Sitecore forms with Sitecore jss(Angular app)
Can anybody please help with any reference of how to use sitecore forms with sitecore jss angular app. For react application library is available "npm i @sitecore-jss/sitecore-jss-react-forms&...
7
votes
1
answer
1k
views
Identity server container fails to launch due to license error using headless Getting Started project in Sitecore 10 docker
Using the getting started project from Sitecore 10 docs, as per https://doc.sitecore.com/developers/100/developer-tools/en/walkthrough--using-the-getting-started-template.html
the Identity server ...
0
votes
1
answer
148
views
Node version issue in Multisite Sitecore jss application in Azure
I have 2 jss apps deployed to azure. Both are built on node 12.15.0 and I have WEBSITE_NODE_DEFAULT_VERSION as 12.15.0 in azure app settings but Only one of the apps is getting loaded at a time. For ...
1
vote
1
answer
1k
views
Sitecore jss headless mode with multiple sites
I have downloaded jss proxy and configured my site to run in headless mode. How to configure multiple sites with different domains
1
vote
0
answers
161
views
Sitecore Analytics not working in Sitecore 9.2 JSS Application
I have enabled the following settings
<setting name="Sitecore.JSS.TrackerServiceEnabled" value="true" />
<setting name="Xdb.Enabled" value="true" />
...
0
votes
0
answers
206
views
Sitecore First Approach Can't see the component added to child placeholder
We are working on POC to test new page addition through SitecoreFirst workflow. Have added a sample template and JSON rendering to my Sitecore app from the content editor and created a route to host a ...
0
votes
0
answers
19
views
Creating Layout service url for Sitecore Jss multisite application in azure [duplicate]
I am completely new to Sitecore Jss. i am trying to implement a multisite sitecore application using jss. I already have a jss site hosted in azure with layout service "https://abc.org/sitecore/...
1
vote
1
answer
435
views
Unable to get local issuer certificate with Sitecore JSS Create
I am trying to create JSS app locally however getting below error while running the Sitecore JSS creates command.
Error:Unable to get local issuer certificate
Command: jss create appname react
I am ...
0
votes
0
answers
29
views
Unable to import JSS app to Sitecore [duplicate]
I’m trying to deploy JSS App on Sitecore, all seems to be in order but when I run this command
jss deploy app -c -d I am getting the following error
Unexpected response from import service:
Status ...
4
votes
1
answer
709
views
Creating multi site using Sitecore JSS
I am new to creating Multisite using Sitecore JSS. Little confused with what configuration should I go ahead with,
Current configuration,
We have currently 1 site added to the site node in Sitecore....
3
votes
1
answer
120
views
How do I query GraphQL using SPE?
How do I leverage SPE to query Solr via GraphQL?
5
votes
3
answers
3k
views
Running JSS-CLI to create app I'm getting "JSS CLI is running in global mode because it was not installed in the local node_modules folder" messaging
I'm running Windows 10, node v14.5.0 and JSS v13.2.0 which is the latest at this time (I've literally just installed it). I'm trying to create an angular app with the JSS-CLI with the following:
jss ...
1
vote
1
answer
181
views
Create Validation Rules via JSS
I'm working on a Sitecore 9.2 JSS project that needs a required field that results to FatalError. The default required field in Sitecore is using CriticalError.
I can create it manually in Sitecore ...
1
vote
1
answer
362
views
How to pass a variable to search context?
I have created a SearchContext, defined query, provider etc. I have a variable to pass so can get result depending on what is being passed.
Now, how do I pass this $query variable (which will be a ...
2
votes
1
answer
527
views
How to get "jssmedia" word in Sitecore JSS app image URL?
My JSS app is not showing images though they exist. When I open the same link in my browser, then the browser is showing those images.
I am getting the URL of my JSS image as
http://first-jss-app.dev....
1
vote
1
answer
158
views
Editing JSS SXA route fields in Experience Editor
Using a JSS site deployed on SXA 9.3, is it possible to edit route fields in Experience Editor ?
I have assigned simple fields to the route template and in Experience Editor I have tried using the ...
2
votes
0
answers
86
views
Running jss cli commands from c# class
Im trying to run jss cli commands (Windows Powershell) from my C# Class. I`m creating the commands dynamically, but i noticed that jss commands are not running.
PowerShell ps = PowerShell....
2
votes
0
answers
59
views
How to set a Datasource explicitly in yml file and change it when I go for personalization?
I'm using Jss react. I want to pass a datasource to a component which is coming from a different location (not from component itself or sitecore context). I want to use personalization so the ...
2
votes
0
answers
43
views
Can I create a native android app by retrieving data from Sitecore?
Current situation
I have Sitecore 9.3. My Sitecore runs locally inside a vm. I've created a jss website and deployed it to sitecore following the official guide.
What i want
I want to create an ...
2
votes
1
answer
562
views
How to embed Youtube & Vimeo videos in Sitecore JSS with React
I have create a video player component in Sitecore jss/react. I have tried with react-player player plugin. It is working fine in disconnected mode but as soon as I deployed it in Sitecore, it is ...
1
vote
1
answer
84
views
Angular JSS - References to Window Break In Experience Editor
I have a couple references to the window object in my Angular JSS component:
@HostListener('window:resize', ['$event'])
onResize(event) {
if (window && typeof window !== 'undefined') {...
1
vote
1
answer
480
views
Caching in Headless Architecture Mode - How does the Caching works for each ReactJs Component?
I hope you all are keeping safe during these uncertain times.
I have two questions.
I am creating a simple react-js page with 4 components. Can someone please guide me how the caching works in ...
3
votes
1
answer
182
views
Why is JSS rendering items of template Sample Item but not of any other template?
I installed Sitecore JavaScript Services Server for Sitecore 9.3 XP 13.0.0 rev. 190924 in a 9.3 instance.
I then created an item under the Home item using the /sitecore/templates/Sample/Sample Item ...
1
vote
0
answers
70
views
Consume sitecore jss data from a separate sitecore instance
I have a Sitecore 9.1 MVC implementation where I want to consume the layout service response from a different Sitecore endpoint as an rendering.
I have gone through the ways mentioned in Sitecore ...
2
votes
1
answer
411
views
Value cannot be null. Parameter name: element
After I input the command with the certificate
jss deploy app --includeContent --includeDictionary --acceptCertificate ww:ww:11:....
Following error shows up.I'm using Sitecore 9.0.2 and doing the ...
3
votes
1
answer
340
views
JSS Field naming convention
Will or should Sitecore automatically sanitize field names when serialising them as part of the layout service or do we need ensure we define fields in Sitecore using a consistent format?
e.g. would "...
1
vote
1
answer
160
views
Does front-end JSS trial includes Sitecore Experience platform?
It seems 60 day developer trial license is no longer available, and the only trial available is the front-end JSS trial. Does the front-end JSS trial includes Sitecore Experience platform?
Can I run ...
3
votes
2
answers
761
views
Unexpected response from import service: Status message: Forbidden
I have a JSS Tenant and Site working and Running. I created another Jss Tenant and JSS Site in it using Sitecore 9.3. Created a JSS App as I did before.
I created a new API Key for my second Site. ...
2
votes
1
answer
250
views
SitecoreJSS DateField is not able to format date coming from GraphQl query
I'm getting a Date from GraphQl query. When I get the result, it is coming as 20200415T123050Z.
If I try to format using
<DateField field={item.publishDate} render={(date) => date....
1
vote
0
answers
209
views
JSS Import media file returns error that Media does not exist [SC JSS+Angular]
I created a custom template to be used in my content items and one of it's field is an Image field.
Also, created a content item under "data/content" using that template and supplying the correct ...
1
vote
0
answers
2k
views
Get current system Date and Time using GraphQL (SitecoreJSS)
Is there way to get the current system date and time using GraphQL (on GraphQL UI)?
Working on a requirement that I need to compare the Sitecore item expiration date(custom field) with the current ...
1
vote
2
answers
747
views
GraphQL query to search for pages based on template
The following GraphQL query returns items based on the Page template:
search(keyword: "Dream",
first: 10,
language: "en",
fieldsEqual: [{name:"_templatename&...
1
vote
0
answers
105
views
Can't call login-page from JSS app
I tried to follow this guide to login from the JSS-app, but I get an error when posting:
Access to XMLHttpRequest at 'https://myApp/sitecore/api/ssc/auth/login?sc_apikey={APIKey}' from origin 'http://...
2
votes
0
answers
180
views
Not able to edit text inline in button tags
I am using Sitecore 9.3 with JSS.
I have created few components that have buttons. The button labels are editable in sitecore.
The issue is when I edit those button labels inline, e.g, I need to add ...
1
vote
1
answer
161
views
Do not create rendering for a template during jss deploy
I am using Sitecore 9.3 Instance with JSS.
I need to create a component that consists of 2 templates - say - Template1.sitecore.js and Template2.sitecore.js and 1 rendering - RenderingName/index.js.
...
1
vote
0
answers
54
views
Preferred method of populating rendering data with route / context item instead of datasource item
I have component that has no explicit datasource because I want it to get its field values from the route item (which also happens to be the Sitecore context item). What would be the preferred method ...