Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

ClientSidePersistence.js MODE_LOCAL to MODE_SESSION

Avatar

Level 2

CQ.shared.ClientSidePersistence - /libs/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js
How do I override the value from my js code base?
I need to change it from default value of MODE_LOCAL to MODE_SESSION.
Thanks in advance.

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @oleksandrr13925 

 

You can create one overlay under apps and then make the changes as needed.

/apps/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js

 

Thanks!

View solution in original post

5 Replies

Avatar

Community Advisor

Hi @oleksandrr13925 

 

Can you give more information about this file, 

ClientSidePersistence.js

 

From where this file is getting loaded?

Avatar

Level 2

Hi @Asutosh_Jena_ 
here is the path to it /libs/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js

Avatar

Correct answer by
Community Advisor

Hi @oleksandrr13925 

 

You can create one overlay under apps and then make the changes as needed.

/apps/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js

 

Thanks!

Avatar

Community Advisor

Hi @oleksandrr13925 

 

1. Override ClientSidePersistence.js - Copy file from 

/libs/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js

 

2. Create same structure in /apps folder & paste it

/apps/clientlibs/granite/legacy/shared/source/ClientSidePersistence.js


3. Change value from MODE_LOCAL to MODE_SESSION

Regards,

Santosh