magic-virtual-element
Advanced tools
Comparing version 1.0.6 to 2.0.0-rc1
{ | ||
"name": "magic-virtual-element", | ||
"version": "1.0.6", | ||
"version": "2.0.0-rc1", | ||
"repository": "dekujs/magic-virtual-element", | ||
"description": "Build virtual tree elements with magic attributes", | ||
"main": "index.js", | ||
"main": "lib/index.js", | ||
"devDependencies": { | ||
"babelify": "^6.1.1", | ||
"bfc": "^0.3.1", | ||
"browserify": "^11.0.1", | ||
"hihat": "^2.4.0", | ||
"snazzy": "^1.0.1", | ||
"standard": "^4.5.4", | ||
"babel-cli": "^6.4.0", | ||
"babel-preset-es2015": "^6.3.13", | ||
"babelify": "^7.2.0", | ||
"hihat": "^2.6.1", | ||
"rimraf": "^2.5.0", | ||
"snazzy": "^2.0.1", | ||
"standard": "^5.4.1", | ||
"tap-dev-tool": "^1.3.0", | ||
"tape": "^4.0.1" | ||
"tape": "^4.4.0" | ||
}, | ||
"dependencies": { | ||
"classnames": "^2.1.3", | ||
"component-type": "~1.1.0", | ||
"sliced": "^1.0.1", | ||
"to-style": "^1.3.3", | ||
"virtual-element": "^1.1.2" | ||
"deku": "~2.0.0-rc", | ||
"classnames": "^2.2.3", | ||
"component-type": "~1.2.0", | ||
"to-style": "^1.3.3" | ||
}, | ||
"scripts": { | ||
"build": "mkdir -p build && browserify -s magic-virtual-element -e index.js | bfc > build/magic-virtual-element.js", | ||
"clean": "rimraf lib", | ||
"build": "babel index.js --out-dir lib", | ||
"prepublish": "npm run clean && npm run build", | ||
"preversion": "npm run clean && npm run test", | ||
"version": "npm run build", | ||
"postversion": "git push && git push --tags && npm run clean", | ||
"test": "standard index.js && hihat test/index.js -- --debug -t babelify -p tap-dev-tool" | ||
} | ||
} | ||
} |
# magic-virtual-element | ||
[![version](https://img.shields.io/npm/v/magic-virtual-element.svg?style=flat-square)](https://www.npmjs.com/package/magic-virtual-element) [![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square)](https://github.com/feross/standard) | ||
A library for building virtual tree elements, with enhanced support for class and style properties. | ||
``` | ||
npm install magic-virtual-element | ||
``` | ||
You can also use Duo, Bower or [download the files manually](https://github.com/dekujs/magic-virtual-element/releases). | ||
## Top-Level API | ||
```js | ||
element(component: string|Function , [props: object], [...children: Array]): Component | ||
``` | ||
## Example | ||
```js | ||
import element from 'magic-virtual-element'; | ||
let divStyle = { | ||
color: 'white', | ||
backgroundImage: 'url(' + imgUrl + ')', | ||
WebkitTransition: 'all', // note the capital 'W' here | ||
msTransition: 'all' // 'ms' is the only lowercase vendor prefix | ||
}; | ||
element('div', { class: ["App", "foo", "bar"], style: divStyle }, [ | ||
element('button', { class: "Button" }, 'Click Me!') | ||
]); | ||
``` | ||
See https://github.com/dekujs/deku#virtual-elements |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
4
36
3591
9
6
33
2
+ Addeddeku@~2.0.0-rc
+ Addedbit-vector@0.1.6(transitive)
+ Addedcomponent-type@1.2.2(transitive)
+ Addeddeku@2.0.0-rc9(transitive)
+ Addeddift@0.1.12(transitive)
+ Addedindex-of@0.2.0(transitive)
+ Addedis-svg-attribute@1.2.0(transitive)
+ Addedis-svg-element@1.0.1(transitive)
+ Addednatural-selection@1.0.1(transitive)
+ Addedramda@0.15.1(transitive)
+ Addedsetify@1.0.4(transitive)
+ Addeduid@0.0.2(transitive)
+ Addedunion-type@0.1.6(transitive)
- Removedsliced@^1.0.1
- Removedvirtual-element@^1.1.2
- Removedarray-flatten@1.1.1(transitive)
- Removedcomponent-type@1.1.0(transitive)
- Removedsliced@0.0.51.0.1(transitive)
- Removedvirtual-element@1.2.0(transitive)
Updatedclassnames@^2.2.3
Updatedcomponent-type@~1.2.0