Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/RubyLouvre/anu
the React16-compat library with hooks
https://github.com/RubyLouvre/anu
anu react wechat-mini-program zhifubao-mini-program
Last synced: 4 months ago
JSON representation
the React16-compat library with hooks
- Host: GitHub
- URL: https://github.com/RubyLouvre/anu
- Owner: RubyLouvre
- License: apache-2.0
- Created: 2017-02-28T07:20:30.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2020-09-18T02:59:39.000Z (over 4 years ago)
- Last Synced: 2024-10-29T23:19:46.160Z (4 months ago)
- Topics: anu, react, wechat-mini-program, zhifubao-mini-program
- Language: JavaScript
- Homepage: https://rubylouvre.github.io/anu/
- Size: 41 MB
- Stars: 3,184
- Watchers: 112
- Forks: 319
- Open Issues: 38
-
Metadata Files:
- Readme: readme.md
- License: LICENSE
Awesome Lists containing this project
- awesome-github-star - anu - compat library with hooks | RubyLouvre | 3195 | (JavaScript)
- awesome-star-libs - RubyLouvre / anu
README

[](https://github.com/Rubylouvre/anu/blob/master/LICENSE)
[](https://www.npmjs.com/package/anujs)
[](https://circleci.com/gh/RubyLouvre/anu/tree/master)
[](https://github.com/RubyLouvre/anu/pulls)```bash
npm install anujs
```A mini React-like framework that is extremely compatible with React16。
QQ group: 370262116
source: https://bundlephobia.com/
### advantage:
1. Support various new features of **React16**, Fragment, componentDidCatch, creactContext, createRef, forwardRef...
2. The size is very small (only 3000 lines, gzip only 13kb, one third of React+ReactDOM)
3. Pass more than 700 official unit tests (other mini libraries can not run the official test)
4. Share the huge ecology of React(React-router-dom, react-router-redux, react-lazy-load, react-hot-loader...)
5. Supports 99% antd components (`antd`is an enterprise-class UI components in China).
6. Excellent browser compatibility, easy to handle all kinds of business under IE6-8.
7. It comes with a painless state manager **Rematch** and a handy router **Reach**.### nanachi
nanachi已经交回原公司 qunar.com 维护了,不放在此仓库 ,详见 https://qunarcorp.github.io/anu
### boilerplate
* https://github.com/RubyLouvre/anu-ie8-example (IE8)
* https://github.com/magicapple/anujs-webpack4-ie7-8
* https://gitee.com/menhal/React_IE8_boilerplate
* https://github.com/meeteason/react-webpack-ie6-boilerplate### License
MIT
### webpack config
```js
resolve: {
alias: {
'react': 'anujs',
'react-dom': 'anujs',
// For compatibility with IE please use the following configuration
// 'react': 'anujs/dist/ReactIE',
// 'react-dom': 'anujs/dist/ReactIE',
// 'redux': 'anujs/lib/ReduxIE', /// This is mainly for IE6-8, because of the poor performance of the isPlainObject method in the official source code.
// If you reference prop-types or create-react-class
// Need to add the following alias
'prop-types': 'anujs/lib/ReactPropTypes',
'create-react-class': 'anujs/lib/createClass',
// If you use the onTouchTap event on the mobile side
'react-tap-event-plugin': 'anujs/lib/injectTapEventPlugin',
}
},
```### Testing
```
npm test
```