How to Install and Apply the Code Override
Follow these quick steps to add the SmartSession override to your SmartPreloader component.
01
Create a New Code File
From the left sidebar, select Assets, find Code, and click the + sign, then select New Code File and New Override.
Name it as PreloaderLogic.
02
Paste the Code
Delete any boilerplate code, paste the code override, then save the file with Ctrl + S or Cmd + S.
03
Select the Component
Return to the canvas and select your SmartPreloader component.
Make sure your Smart Preloader component is on top of every layer. In the right sidebar, find Styles, set Z-index to 10, and Pointer Events to None.
04
Assign the Override
In the right sidebar, locate the Code Overrides section.
Under File, choose the PreloaderLogic code file. Under Function, select withSmartSession.