Search code examples
javascriptextjsextjs4extjs6

Upgrading from extjs 4 to extjs 6


I have my webapp written in extjs 4 and I am using apache-tomcat as server and java as backend implementation.I am not using sencha cmd till now. I am calling extjs library in index.html like below

    <link rel="stylesheet" href="/css/ext-all.css"     />
    <script type="text/javascript" src="/js/ext-4.0.7/ext-all.js"  >    </script>

I have a few doubts.
1. Can I just replace extjs 4 with extjs 6 lib files in index.html for upgrading?

2.Since I am not using sencha cmd, Is it possible to use the tookits feature(tomcat as server) while calling from index.html even if it means rewriting from scratch(without sencha cmd though)?

  1. If i use sencha cmd,is it possible to deploy the app in tomcat server and call the bootstrap.js from index.html?

Solution

  • If you don't use Cmd, then replacing ExtJS 4 with ExtJS 6 is the first step in upgrade process (if you use Cmd, don't just replace the framework - make a new app with new Cmd and new Framework version, and copy over your code). Afterwards, the tedious part begins: you will have to clean up and rework your code until it runs correctly. For our app, the rework process took two weeks, including refactoring.

    While the toolkit feature is not available out of the box if you just link to the ext-all.js, you can of course rewrite index.html to get the browser/OS and then load the ExtJS files you need depending on the browser.

    If you use Sencha Cmd, you can still deploy the app in tomcat server. You can edit the index.html to include anything you want, as long as you don't touch the part that is marked "the following line is required for Sencha Cmd to build".