更新时间:2022-11-16 19:55:54
我有一个相当大的应用程序,这就是我的结构
I have a rather large application and this is how I have it structured
css
-- all css files
images
-- all image files
js
controller.js -- page events and element actions. Also contains PhoneGap specific methods
core
forms.js -- working with forms, saving info
mobile.js -- basic definitions, AJAX communications
encrypt.js -- encryption
global.js -- helper functions
storage.js -- database storage wrapper
cw
client.js -- a client object, > 400 lines of js code
Objects.js -- all other needed objects with <50 lines of js code each
question.js -- a question object, > 500 lines of js code
service.js -- a service object, > 700 lines of js code
jq
jquery-ui.min.js
jquery.min.js
jquery.mobile.min.js
phonegap-1.1.0.js
add_client.html
clients.html
client_list.html
index.html -- the only file that is structured like a real full html file
manager.html
schedule.html
service.html
除了我的 index.html 文件之外,所有其他 .html 文件都是存根.它们仅包含 <div data-role='page'></div>
和其他定义页面及其预期功能所需的 html 元素.
aside for my index.html file, all other .html files are stubs. They only contain the <div data-role='page'></div>
and other needed html elements that define the page and its intended functionality.
我在 VS2010 上开发应用程序,使用 Chrome 作为我的调试器.当我对自己的进步感到满意时,我会将所有内容复制到我的 Mac 中的一个 Eclipse 项目(对于 Android 设备)中的文件夹,这也是我的 xCode 项目(对于 iOS 设备)中的链接引用.
I develop the app on VS2010, using Chrome as my debugger. When I feel good with my progress, I copy everything over to my mac to a folder in an Eclipse project ( for Android devices ) which is also a linked reference in my xCode project ( for iOS devices ).
我已经在这个项目上工作了大约 3-4 个月,一旦我通过了 jQM 和 PhoneGap 的学习曲线,就在这个结构上取得了很好的进展.
I have been working on this project for about 3-4 months now and once I got past the learning curve of jQM and PhoneGap, have been making very good progress with this structure.