Web Integrated Development Environment (WebIDE) is an online IDE provided by Function Compute that offers a cloud development experience similar to Visual Studio Code (VS Code). You can write, debug, and deploy code online without having to set up a complex development environment on a local machine. This topic describes the features and user interface of WebIDE and explains how to configure it in the Function Compute console.
Limits
WebIDE supports only Python, Node.js, PHP, and custom runtimes. Online editing is not supported for the Java, Go, or C# runtimes. For these runtimes, you can only upload compiled and packaged ZIP files or binary files.
WebIDE provides each user with 5 GB of storage space. Write operations fail if you exceed this limit. Clean up your storage space regularly.
When you open WebIDE for a function, an instance is automatically started. This instance is equivalent to a container instance with 1 vCPU and 1.5 GB of memory.
The WebIDE instance environment is the same as your function's runtime environment. However, this instance cannot load your custom layers or mounted NAS or OSS resources. It also cannot access the VPC environment configured for your function. If you need these features, you can deploy your code and then invoke the function, or use the dedicated WebIDE.
The dedicated WebIDE is available only in the China (Hangzhou), China (Shanghai), China (Beijing), China (Zhangjiakou), China (Hohhot), China (Shenzhen), China (Hong Kong), Singapore, Japan (Tokyo), Germany (Frankfurt), and US (Virginia) regions. To use the dedicated WebIDE in other regions, you can join the DingTalk group (ID: 64970014484) to apply.
WebIDE interface overview
The following figure shows the WebIDE interface in full-screen mode. It is divided into four areas: ① Resource manager, ② File editor, ③ Function operations, and ④ Command-line terminal.
① Resource manager: View the code structure, including code files and dependency files.
② File editor: Edit your function code. After you finish editing, you can click the
icon in the upper-right corner to debug your code. To synchronize the online code with the terminal environment, click Deploy Code in the ③ Function operations area.
③ Function operations: Deploy and test your function code. After you click Exit Full Screen, the function operations area moves to the upper-left corner of the WebIDE interface.
④ Command-line terminal: In the WebIDE toolbar, you can select
to open a command-line terminal. In the terminal, you can debug your code or install third-party dependencies.
Configure WebIDE in the console
Prerequisites
Create a function. For more information, see Create a function.
Procedure
Log on to the Function Compute console. In the left-side navigation pane, click Functions.
In the top navigation bar, select a region. On the Functions page, click the function that you want to manage.
(Optional) On the Code tab of the function details page, click Configure WebIDE in the upper-right corner. In the Configure WebIDE panel, select a WebIDE type.
You can select the Serverless or Dedicated WebIDE.
Serverless
The default version. It is free to use and does not support accessing resources in a VPC or mounting NAS or OSS resources.
Dedicated
If you need the instance to load your custom layers, mount NAS or OSS resources, or access the VPC environment configured for the service, select Dedicated WebIDE and configure the following items.
Instance Type
Execution Timeout
If you select the dedicated WebIDE, Function Compute reuses an existing VPC, vSwitch, and General-purpose NAS file system or automatically creates new ones based on the VPCs in the region where your function resides. For more information about the billing of automatically created resources, see Billing of General-purpose NAS file systems.
In the WebIDE interface, write and test your function code, and install third-party dependencies as needed.
For more information about the WebIDE interface, see WebIDE interface overview.
If you select the dedicated WebIDE, ensure that your function can be executed correctly. Otherwise, WebIDE may fail to open.
FAQ
What do I do if WebIDE fails to load?
What is a dedicated WebIDE?
Why does my function fail when I click Test Function even though it runs successfully in the terminal?
How to quickly reset the environment variables, runtime, and layers for a function's WebIDE
How long is Serverless WebIDE workspace data retained?
Can I debug code in WebIDE?
When I modify function code, the git plugin shows code differences. Is this because WebIDE hosts the function code?
Why is the code different when two RAM users from the same Alibaba Cloud account open the same function?
What do I do if the WebIDE terminal is slow to open or fails to open?
References
You can also use the WebIDE terminal to package third-party dependencies for your function. For more information, see Use WebIDE to package third-party dependencies for a function.
If your function code or the third-party dependencies to be installed are large, you can extract the function dependencies into a layer or use a Function Compute public layer to reduce the code package size. For more information, see Create a custom layer.
You can also use the local debugging feature of Serverless Devs to test functions locally. For more information, see Local debugging.