Single Page Applications as XML Definitions

A single page application (SPA) is a web application or site that loads a single HTML page and dynamically updates that page when the user interacts with it.

In NetSuite, you can use SPAs to build a customized user interface. SPAs are created as part of SuiteApp projects created using the SuiteCloud Development Framework (SDF). SPAs are defined in SDF as a singlepageapp SDF custom object.

To see the list of SPAs deployed in your NetSuite account, go to Customization > Scripting > Single Page Applications.

For information about working with SPAs, see the following help topics:

Take note of the following guidelines when creating the XML definition file for a singlepageapp SDF custom object:

For information about the attributes and fields in a singlepageapp SDF custom object, see singlepageapp.

For a complete example showing all the supported fields, see Single Page Application XML Definition Example.

The basic XML definition for an SPA object in a SuiteApp looks like the following:

          <singlepageapp scriptid="custspa_helloworld"> 
    <name>Hello World</name> 
    <description>This is a sample SuiteApp that uses NetSuite UIF components.</description> 
    <url>helloworld-suiteapp-spa</url> 
    <folder>[/SuiteApps/com.netsuite.spa/helloworld/]</folder> 
   <clientscriptfile>[/SuiteApps/com.netsuite.spa/helloworld/SpaClient.js]</clientscriptfile> 
    <serverscriptfile>[/SuiteApps/com.netsuite.spa/helloworld/SpaServer.js]</serverscriptfile> 
    <assetsfolder>[/SuiteApps/com.netsuite.spa/helloworld/assets/]</assetsfolder>
</singlepageapp> 

        

For information about errors related to SPAs in SDF SuiteApp projects, see Troubleshooting Single Page Applications.

Related Topics

General Notices