Search code examples
extjssencha-cmd

Upgrading extjs 4 to 5 or 6, without using sencha cmd


I'm developing on an application that wasn't built using sencha command. Right now we are using extjs 4.2, but we need to upgrade it to extjs 5 or 6. Preferebly extjs 6. Furthermore, our application does not follow the structure of MVC.

  1. Is it possible to convert the application so it uses sencha cmd somehow, when it wasn't created using sencha command?
  2. If not, what will be the easiest and most comprehensive way to upgrade to extjs 5 or 6? I have tried this approach: How to upgarde my Extjs application from 4 to 6? but after some fight, I am still not able to make it work.
  3. extjs 4 uses ext-all.css. Is there a way to get the semilar file in extjs 6, that I just can't find?
  4. Has any of you succeeded in upgrading to extjs 6 without using sencha command? Our application is pretty big, so deleting everything and start a new application as a solution, is not an option

Thanks for any help you can provide


Solution

  • I would recommend to use Cmd, as this will reduce your application's footprint. I would recommend to upgrade to the latest framework version available, since the amount of work required should be the same whether you switch from 4.2 to 5 or from 5 to 6 or directly from 4.2 to 6.2, and one less of these "full upgrades" mean less testing and less overall work.

    I cannot answer question 4, because we did already use Cmd with ExtJS 4.2, but the other ones as follows:

    1. To convert your existing app into a Cmd application, you would create a new application with Cmd (going by the same name, located in a different directory) first, and then move over all the old code into the new application directory. Cmd doesn't care whether you follow MVC structure or not, as long as file names and component names match (MyApp.someName.someOtherName.SomeComponent should be defined in app\someName\someOtherName\SomeComponent.js).

    2. Please note that upgrade of big applications from 4.2. to 6 takes months, not hours, because there are so many API changes forcing you to change your code and test and change and test. You could fill a book with all loopholes I encountered when I upgraded our application. The upgrade was really a good thing, though - I came across nearly all code from back then when I didn't know shit about ExtJS, and while I was debugging, I made major refactoring and code improvements (including full switch from CSS to SASS).

    3. If you choose not to use Cmd, precompiled stylesheets are in build\classic\theme-<yourtheme>\resources folders.