[Angular-Scaled web] 1. Architecture and file structure
We build a project according to its features or based on simple MVC structure. Put all controller into one folder and factory into another folder is hard to maintain and testing.
For this project, we have two main features
- Category
- Bookmark
And one Category contains serveal bookmarks.
For bookmarks, we can do 'edit', 'create' options.
We should also isolate one common model, in which we place something can be used for all other modules.

The stucture should be:
app
- category
- bookmarks
- create
- bookmarks-create.js
- bookmarks-create.tmpl.html
- edit
- bookmarks-edit.js
- bookmarks-edit.tmpl.html
- bookmarks.js
- bookmarks.tmpl.html
- create
- category.js
- category.tmpl.html
- bookmarks
- common
- models
- category-model.js
- bookmarks-model.js
- models
- app.complete.js
- app.start.js
- app.finish.js
assets //where to put css and image files
- css
- images
data // where to store the json files
- bookmarks.json
- categories.json
vendor //where to store extension js files
- angular-ui-router.min.js
app.complete.html
app.start.html
app.finish.html
[Angular-Scaled web] 1. Architecture and file structure的更多相关文章
- JDK and JRE File Structure JAVA_HOME HotSpot优化技术
https://docs.oracle.com/javase/8/docs/technotes/tools/windows/jdkfiles.html Java Platform, Standard ...
- 混合开发 Hybird Ionic Angular Cordova web 跨平台 MD
Markdown版本笔记 我的GitHub首页 我的博客 我的微信 我的邮箱 MyAndroidBlogs baiqiantao baiqiantao bqt20094 baiqiantao@sina ...
- 【Android Studio 小技巧】一键查看文件方法结构目录File Structure
看源代码的时候,如果可以查看class中的所有方法,可以提高效率.Android Studio 中可以使用快捷键一键显示所有方法的目录. Mac: command + fn + F12 (在mac中的 ...
- What is Web Application Architecture? How It Works, Trends, Best Practices and More
At Stackify, we understand the amount of effort that goes into creating great applications. That’s w ...
- Web for pentester_writeup之File Upload篇
Web for pentester_writeup之File Upload篇 File Upload(文件上传) Example 1 直接上传一句话木马,使用蚁剑连接 成功连接,获取网站根目录 Exa ...
- Web for pentester_writeup之File Include篇
Web for pentester_writeup之File Include篇 File Include(文件包涵) Example 1 加一个单引号 从报错中我们可以获取如下信息: 当前文件执行的代 ...
- Understanding Spring Web Application Architecture: The Classic Way--转载
原文地址:http://www.petrikainulainen.net/software-development/design/understanding-spring-web-applicatio ...
- BUILDING ANGULAR APPS USING FLUX ARCHITECTURE
Flux is an architectural pattern based on unidirectional data flow. Although it is originated in the ...
- 【DVWA】Web漏洞实战之File Upload
File Upload File Upload,即文件上传漏洞,一般的上传漏洞可能是未验证上传后缀 或者是验证上传后缀被bypass 或者是上传的文件验证了上传后缀但是文件名不重命名. LOW 直接上 ...
随机推荐
- android 打开 res raw目录 中 数据库文件
韩梦飞沙 韩亚飞 313134555@qq.com yue31313 han_meng_fei_sha 安卓不能直接打开 res raw 中的 数据库 文件. 通过 资源 获取资源 方法 , ...
- 3、Redis中对String类型的操作命令
写在前面的话:读书破万卷,编码如有神 -------------------------------------------------------------------- ------------ ...
- window.open如何返回值给父窗口
父窗口代码 function showMyWindowNew() { var iTop = (window.screen.availHeight - 30 - 450) / 2; //获得窗口的水平位 ...
- BZOJ 3875: [Ahoi2014]骑士游戏 spfa dp
3875: [Ahoi2014]骑士游戏 题目连接: http://www.lydsy.com/JudgeOnline/problem.php?id=3875 Description [故事背景] 长 ...
- Codeforces Round #FF (Div. 1) B. DZY Loves Modification 优先队列
B. DZY Loves Modification 题目连接: http://www.codeforces.com/contest/446/problem/B Description As we kn ...
- UVA 350 Pseudo-Random Numbers
Pseudo-Random Numbers Computers normally cannot generate really random numbers, but frequently are ...
- HDU 1692 Destroy the Well of Life 水题
Destroy the Well of Life Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 http://acm.hdu.edu.cn/showprob ...
- spring---aop(5)---Spring AOP的配置的背后的配置
写在前面 Spring AOP中Pointcut,dvice 和 Advisor三个概念 1)切入点 Pointcut 在介绍Pointcut之前,有必要先介绍 Join Point(连接点)概念. ...
- MySQL的转义符 ` 作用
` 是 MySQL 的转义符,避免和 mysql 的本身的关键字冲突,只要你不在列名.表名中使用 mysql 的保留字或中文,就不需要转义. 所有的数据库都有类似的设置,不过mysql用的是`而已.通 ...
- 正确理解java编译时,运行时以及构建时这三个概念
Java中的许多对象(一般都是具有父子类关系的父类对象)在运行时都会出现两种类型:编译时类型和运行时类型,例如:Person person = new Student();这行代码将会生成一个pers ...