Best Way to Organize an ExtJS Project

前端 未结 4 1117
梦如初夏
梦如初夏 2021-01-04 02:22

I\'ve just started developing an ExtJS application that I plan to support with a very lightweight JSON PHP service. Other than that, it will be standalone. My question is,

4条回答
  •  心在旅途
    2021-01-04 03:26

    When starting new big project, I decided to make it modular. Usually, in big projects not all modules are used by a particular user, so I load them on demand. F.e., if a project would have 50+ modules, the big probability is that user is working only with 10-.

    Such architecture lets you to have the initial code relatively small.

    Modules are stored on the server and loaded by AJAX call, eval'uating the responseText in AJAX callback. The only issue with this, you must keep track on module dependencies, which could be stored inside modules as well. I have a class called Module, and I check every new module instance for existance within the task. If it doesn't yet exist, I load it from the server.

提交回复
热议问题