Comments (3)
昨天 @genify 你没来 我先简单实现了 风格2 . 只是对可以链式的接口做了转移(如 _$addClassName等,细节都还没做,切换到方案1也方便)和简单扩展方式,对于上面提到的两个问题:
- 首先nej是个框架,接口的限制在这里不是很明显,(Mootools、Prototype都暴露了百来个全局, 当然这个不是典型案例, 已经与时代脱节)。
- 两份包装类(_Node、_NodeList),某些方法是可以共生的,我暂时是利用跟Mootools类似的方式,留个hook,在_Node扩展时,给_NodeList也做一份,这之中当然要有一些简单的约定
from nej.
选用 方案1
from nej.
This issue was moved to NEYouFan/nej-framework#1
from nej.
Related Issues (6)
- chain API HOT 1
- chainable 的 _$click 或者通过_$implement的 方法 在混淆时 会报错 HOT 1
- chainable在用html字符串生成DOM节点时,某些情况不正确 HOT 3
- NEJ使用中犯的错 record下 HOT 4
- 日历组件跨年BUG HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nej.