Hybrid Apps with Sencha – Part 3

The first two parts in this series developed a life of their own. They remained out of focus with the subject of this series. Out of focus is the state of web development in the current landscape. So many things are changing in both the web as we know it and mobile development due to the massive increase of demand for mobile access.

PWA’s (progressive web apps) are growing. Though when developing a hybrid app this technique isn’t intended to become a PWA. It does allow development of both full classic web application and a mobile accessible web application. Neither of these two will out of the box handle or become a PWA. Your mobile access can be converted to a PWA but there will be several steps to take to accomplish this task.

Currently Sencha Architect doesn’t support developing a “universal”/hybrid app. You can either develop a modern or classic toolkit when creating a new project in Architect. Should you decide to work with Architect on this type of project the best method is to define a workspace first. You can create a workspace by running the following in terminal (Mac) or command prompt (Windows).

sencha generate workspace /path/to/workspace

This creates the following structure in the specified folder.


Workspaces are both handy and a curse depending how you organize your companies projects. With projects organized in a workspace you are not able to update just one project within the workspace when upgrading Ext JS. The reason this occurs is because all projects within the workspace share the same version of Ext JS and are not required to be guilt from their own. Doing this streamlines upgrades and works best to insure your all your projects are working with the latest.

Using this method is best for new projects and not attempting to upgrade an existing project.

Create a new project using Sencha cmd by entering the following:

sencha -sdk /path/to/extjs generate app /workspace/path/project

Use the above cmd when your workspace does not have an Ext JS version installed. If you have Ext JS installed you can use the command:

sencha generate app /workspace/path/project

If you’re using Architect you would forgo the above steps and create a new project from Architect and point the path to a directory within your workspace.

From this point forward you would follow your normal development path.

Those preferring the hand coding their projects have an edge in creating a new project. When creating a new project using Sencha cmd you can create a universal app without having the need of a workspace. This as stated above leaves you free to upgrade projects independently.

Next and final part will be discussion of the universal app and development using cmd and hand coding.

Author: aallord

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.