New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

anix

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

anix - npm Package Compare versions

Comparing version 0.2.2 to 0.2.3

2

package.json
{
"name": "anix",
"version": "0.2.2",
"version": "0.2.3",
"license": "BSD",

@@ -5,0 +5,0 @@ "keywords": [

# AniX
The Simplest Animation Plugin for react.
Super easy and lightweight transitions animation library。
## Overview
AniX is an animation plugin for react.
AniX is a lightweight and easy-to-use animation library with excellent performance and good compatibility for modern browsers.
It is very simple and convenient to use. At the same time it has very good compatibility.
It uses the native **css transition** attribute, better than js simulation animation performance. And can use hardware acceleration.
## Install and Usage
Quick Start
Install and manage AniX with npm.
AniX is less than **10k** in size, and it does not change your coding habit as much as possible.
There are multiple versions of the AniX option, [umd version](https://github.com/a-jie/AniX/blob/master/dist/umd/anix.umd.js), [jQuery version](https://github.com/a-jie/AniX/blob/master/dist/jq/anix.jq.js) and [react version](https://github.com/a-jie/react-anix)...
## Install and Include
#### Install and manage with npm.
```
$ npm install anix --save
$ npm install anix --save-dev
...
import { AniX } from 'anix';
```
[![anix](https://nodei.co/npm/anix.png)](https://npmjs.org/package/anix)
import and use the AniX library.
#### The umd version [anix.umd.js](https://github.com/a-jie/AniX/blob/master/dist/umd/anix.umd.js). Check out the [UMD](https://github.com/umdjs/umd) repository for more details.
```
//1. import module
import { AniX } from 'anix';
<script src="./js/anix.umd.ts" type="text/javascript"></script>
```
//2. use
#### jQuery plugin [anix.jq.js](https://github.com/a-jie/AniX/blob/master/dist/jq/anix.jq.js), that supports chain syntax.
```
<script src="./js/jquery.js" type="text/javascript"></script>
<script src="./js/anix.jq.ts" type="text/javascript"></script>
```
## Usage
use the pure AniX library.
```
AniX.to(dom, 1, {
width: "200px",
height: "100px",
delay: .5,
onComplete: ()=>{
delay: 0.5,
onComplete: function(){
alert("over");

@@ -34,12 +52,63 @@ }

```
use jquery plugin [anix.jq.js](https://github.com/a-jie/AniX/blob/master/dist/jq/anix.jq.js)
## Examples
```
$('.con').css({'left':'0px'}).to(.5, {
'left': Math.random() * $(window).width() + 'px',
'background-color': getRandomColor()
});
```
## Documentation
vist on [https://a-jie.github.io/AniX/](https://a-jie.github.io/AniX/)
#### the jquery plugin anix.jq.js Api
```
//AniX.to
$(..).to(time: number, args: {ease?:string; delay?:number; [propName:string]:any;})
//AniX.fromTo
$(..).to(time: number, fromArgs: Object, toArgs: Object)
//AniX.kill
$(..).kill(complete?: boolean)
//AniX.get
$(..).getTransform(param: any)
//AniX.ease
$.ease.easeOut
```
## Test and Build
#### build all task
```
git clone git@github.com:a-jie/AniX.git
npm install
npm run all
```
#### build jq and umd
```
npm run jq
npm run umd
```
#### test and build example (the document page) made by [create-react-app](https://github.com/facebookincubator/create-react-app)
```
cd ./example
npm install
npm start
npm run build
```
view on http://localhost:3000/
#### debug the test page
view the ./test/test.html
## License
[The BSD License](https://opensource.org/licenses/BSD-3-Clause).
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc