vincedream / ddd-fe-demo Goto Github PK
View Code? Open in Web Editor NEW⚙️Domain-Driven Design for frontEnd demo
⚙️Domain-Driven Design for frontEnd demo
直接引入common的路径不就行了?或者还有什么别的考虑?
每个页面都有接口按照领域去划分是可以划分的,但是接口还是独立的,也就是说,都是用户信息,每个页面需求的信息仍然不尽相同,所以各自有各自的接口是合理且高效的,那么此时的数据已经和页面有绑定关系了,如果再抽离一个数据处理层,那么为了使这个处理函数可以多处复用,势必要多处判断,时时修改(需求不会一成不变),然后这个数据清洗函数其实也是和页面相互绑定的(清理好后的数据应该直接被渲染【根据文章所描述】)
综上:一个和页面有关的请求,和一个和请求结果以及页面相关的数据清理函数,以及最后要用的页面,为什么要分开三处写?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.