Search code examples
javascriptmodel-view-controllerextjssencha-architect

Sencha Architect creates ViewModel and ViewController Automaticly


I am working on Sencha Architect and following this video which made by Sencha dev-team to walks around basics of application.

I got errors when i run the project and later figure out that somehow Sencha Architect created 'ViewModel' and 'ViewController' automatically.

Why could be? or is there any setting in application to block?

Here is a sample folder structure of 'View'. Files with '(*)' symbol not created by me..

view/
.. TicketDataView.js
.. TicketDataViewViewController.js (*)
.. TicketDataViewViewModel.js (*)
.. TicketPanel.js
.. TicketPanelViewController.js (*)
.. TicketPanelViewModel.js (*)

Solution

  • and i overcome on this situation with deleting 'ViewModel' and 'ViewController' files yet in Sencha Architect:

    • On 'Project Inspector' zone, clicked on 'TicketDataView' and it shows related items such as 'TicketDataViewViewModel' and 'TicketDataViewViewController'.
    • Just right-click to see 'Delete' button and deleted those unnecessary files. So the app.js and metadata/Application.js files updated as well...

    As well as changed the Project Settings:

    • General> Overwrite index file on save: unchecked (leave blank)
    • Framework> Build Tools: Disabled

    Then saved the project and opened index.html and changed script tags for ext-all.js, theme.js and link tag for theme.css to cdnjs' library. Sencha CDN links not working! so imported cdnjs instead of it.