To turn on this feature, select JSL code folding in the Script Editor preferences. Then you can expand and collapse blocks of code by right-clicking on a script and selecting Advanced > Expand All or Collapse All.
After you select this preference, Function and Expr expressions are foldable. See Add More Folding Keywords for details about adding folding markers to other expressions.
Figure 3.7 Code Folding Markers Shown in a Script
{"If", "For", "For Each Row", "While", "Try", "New Window", "V List Box", "H List Box"}
JMP supports multiple keyword lists. A system administrator can define a set of keywords in jmpKeywords.jsl and save the script in C:/ProgramData/SAS/JMP/ or designated directory listed below. You save your version of jmpKeywords.jsl in your C:/Users/<user>/Documents/ folder. JMP merges all keyword lists from the designated directories.
Note that jmpKeywords.jsl is stored in the designated JMP directory, even if you are using JMP Pro.
Notes: 
The list in jmpKeywords.jsl is case insensitive.
After you edit and save the list in jmpKeywords.jsl, turn the Allow additional code folding keywords preference off and then back on for the changes to take effect. Messages in the log indicate that the keywords were loaded.

Help created on 10/11/2018