Creating Additional Modules for Extensions in SuiteCloud

Enhance your SuiteCloud extension by adding modules with the `gulp extension:create-module` command and optimize your development.

·2 min read·View Oracle Docs

To develop a more complex extension in SuiteCloud, you'll often need to create additional modules beyond the baseline. Using the gulp extension:create command establishes a baseline extension with one module, but the developer tools allow you to expand this functionality as needed.

How to Add Additional Modules to Your Extension

To create additional modules in your extension, follow these steps:

  1. Create a baseline extension (if you haven’t done so). Reference the official documentation on Creating a Baseline Extension for guidance.

  2. Open your command line or terminal.

  3. Access your extension development directory. This is the top-level directory created during the installation of the extension developer tools.

  4. Run the command:

    gulp extension:create-module
  5. Follow the prompts:

    • Set the Module Name: Enter a name for the new module using only alphanumeric characters and no spaces.
    • Select the File Types Needed: Choose one or more file types that your extension will use, such as:
      • JavaScript
      • SuiteScript
      • Templates
      • Sass
      • Configuration
      • SuiteScript2
    • Select the Extension: If multiple extensions exist in your Workspace, select the one to which this module will be added.
  6. Repeat as necessary for any additional modules.

Important Considerations

  • Naming Restrictions: Ensure all entries are using only alphanumeric characters without spaces unless otherwise directed.
  • Record Limits: NetSuite has specific limits to prevent overconsumption of web services. When developing themes and extensions, keep the number of files and folders at the same level to a maximum of 100 to avoid deployment issues. Organizing images across various folders and placing custom modules in separate top-level directories can help manage this.
  • Developing Extensions: Once your baseline extension files are completed, you can begin developing your extension. For comprehensive guidance on this, check the documentation on Developing Extensions.

Key Takeaways

  • Use gulp extension:create-module to add modules seamlessly to existing extensions.
  • Name modules and select file types with care, adhering to character restrictions.
  • Understand and manage NetSuite's web services record limits during development.
  • Always refer back to the official documentation for detailed guidance and best practices.

Frequently Asked Questions (4)

What command is used to create additional modules for a NetSuite extension?
You can create additional modules for a NetSuite extension using the command `gulp extension:create-module` in the command line interface.
Are there specific requirements for naming a module in NetSuite extensions?
Yes, the module name must consist only of alphanumeric characters without spaces.
Do I need a specific version of the Extension Developer Tools to access SuiteScript 2.0 file types?
Yes, the `SuiteScript 2.0` file type is available only in versions of the Extension Developer Tools from 2020.1 onwards.
What are some strategies to manage record limits when creating additional modules?
To manage record limits, avoid exceeding a maximum of 100 files and folders at the same level by distributing images across several folders or placing custom modules in a separate top-level directory.
Source: Create Additional Modules for an Extension Oracle NetSuite Help Center. This article was generated from official Oracle documentation and enriched with additional context and best practices.

Was this article helpful?

More in SuiteCloud Development Framework

View all SuiteCloud Development Framework articles →