Overview
S10 applications consist of the user interface, the "views" in the form of HTML files, and the application logic, implemented as ABAP classes. The views are stored in the SAP MIME repository for productive operation and must normally be loaded from there for changes, modified and then transferred again. This is rather impractical during development, as one would like to test changes to the user interface immediately.

You can set up a local development environment on your PC with which all HTML files are read directly from a local directory on your PC instead of from the MIME repository. This makes it possible to test immediately after a "save" in your local HTML editor.

Implementation
In order for S10 applications to run locally, they must be made available via a web server. We use the Microsoft IIS (Internet Information Server) in the following, as it is included in all Windows versions and can be used free of charge.

The standard installation of the IIS does not contain all the functions we need; the "Microsoft Application Request Routing" package must also be installed. This makes it possible to forward some requests to an external location (URL Rewrite), in our case to the S10 service of the SAP system, which executes the ABAP methods.

The following steps are necessary to set up a local S10 application:
  1. Activate the IIS in the Windows features on your PC.



  2. Install the Microsoft URL Rewrite package and the Microsoft Application Request Routing for the IIS. You can do this one after the other via the following links:

    URL Rewrite : The Official Microsoft IIS Site 

    Application Request Routing : The Official Microsoft IIS Site

    Alternatively, you can use the Microsoft Web Platform Installer link at the bottom of the "Application Request Routing" page to install both components together. 

  3. In IIS, Application Request Routing, activate "Enable proxy" so that requests can be forwarded from IIS:







  4. Create any new directory on your PC that will contain the HTML files of your S10 projects, for example F:\s10.

  5. Add an application "S10" in IIS with this directory:




  6. It is advisable to set up a subdirectory in your local directory for each SAP system in which you want to develop, for example in the two systems "DEV" and "T01". The names of the subdirectories are arbitrary, but it is obvious to choose the SAP system names here:



  7. Now place a file "web.config" in each subdirectory



    with the following content:

    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
        <system.webServer>
            <rewrite>
                <rules>
                    <rule name="S10 Service">
                        <match url="^S10$|^S10\(.*" />
                        <action type="Rewrite" 
                           url="http://mysapdev.com:50000/{R:0}"/>
                    </rule>
                </rules>
            </rewrite>
        </system.webServer>
    </configuration>
    


    Replace "mysapdev.com:50000" with the HTTP address and, if necessary, the HTTP port of your SAP system. You can also use HTTPS.

    This forwards all S10 requests to the specified SAP system.

    Instead of copying the "web.config" file, you can also maintain the rewrite rule in the IIS Manager for the respective subdirectory via "URL Rewrite":







  8. You can then generate a test application in your directory in the SAP system with transaction /s10/util and execute it locally.

    For testing, use the URL localhost/s10/dev/XXX, where XXX is the directory of the respective application.

    Tip:
    It is best to open the F12 developer mode in the browser during development and deactivate the cache. You can simulate different output devices in Chrome:





Component S10 Framework