Skip to content

Commit

Permalink
Update deps and CHANGELOG
Browse files Browse the repository at this point in the history
  • Loading branch information
bcomnes committed Apr 20, 2018
1 parent 03d0d9a commit fcf60f1
Show file tree
Hide file tree
Showing 10 changed files with 27 additions and 21 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ npm-debug.log*
.DS_Store
dist
.source*
.vscode
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@
All notable changes to this project will be documented in this file.
This project adheres to [Semantic Versioning](http://semver.org/).

## 6.5.2 - 2018-04-20
- Allow SVGs as the root node (https://github.com/choojs/nanocomponent/pull/79)
- Update deps

## 6.5.1 - 2018-02-11
- Update nanotiming@7.2.0
- Update devdeps: tap-run, dependency-check, browserify, bankai
Expand Down Expand Up @@ -133,6 +137,6 @@ class Meta extends Component {

[ol]: https://github.com/shama/on-load
[cc]: https://github.com/hypermodules/cache-component
[bel]: http://ghub.io/bel
[nanohtml]: http://ghub.io/nanohtml
[nm]: http://ghub.io/nanomorph
[getter]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions/get
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@ Native DOM components that pair nicely with DOM diffing algorithms.
- Implemented in only a few lines
- Only uses native DOM methods
- Class based components offering a familiar component structure
- Works well with [bel][bel] and [yoyoify][yoyoify]
- Works well with [nanohtml][nanohtml] and [yoyoify][yoyoify]
- Combines the best of `nanocomponent@5` and [`cache-component@5`][cc].

## Usage

```js
// button.js
var Nanocomponent = require('nanocomponent')
var html = require('bel')
var html = require('nanohtml')

class Button extends Nanocomponent {
constructor () {
Expand Down Expand Up @@ -50,7 +50,7 @@ module.exports = Button
```js
// index.js
var choo = require('choo')
var html = require('bel')
var html = require('nanohtml')

var Button = require('./button.js')
var button = new Button()
Expand Down Expand Up @@ -102,7 +102,7 @@ This can be done by binding the method that's going to be passed around:

```js
var Nanocomponent = require('nanocomponent')
var html = require('bel')
var html = require('nanohtml')

class Component extends Nanocomponent {
constructor () {
Expand Down Expand Up @@ -134,7 +134,7 @@ Nanocomponent can be written using prototypal inheritance too:

```js
var Nanocomponent = require('nanocomponent')
var html = require('bel')
var html = require('nanohtml')

function Component () {
if (!(this instanceof Component)) return new Component()
Expand Down Expand Up @@ -166,7 +166,7 @@ themselves.

```js
var Nanocomponent = require('nanocomponent')
var html = require('bel')
var html = require('nanohtml')

class Component extends Nanocomponent {
constructor () {
Expand Down Expand Up @@ -201,7 +201,7 @@ components.

```js
var Nanocomponent = require('nanocomponent')
var html = require('bel')
var html = require('nanohtml')
var Button = require('./button.js')

class Component extends Nanocomponent {
Expand Down Expand Up @@ -266,7 +266,7 @@ using them. Hence the proxy pattern, and the recently added support for it in
certain diffing engines:

```js
var html = require('bel')
var html = require('nanohtml')

var el1 = html`<div>pink is the best</div>`
var el2 = html`<div>blue is the best</div>`
Expand Down Expand Up @@ -391,7 +391,7 @@ in the `beforerender` hook.
- [nanomap][nanomap] - Functional mapping into keyed component instances
- [choojs/choo][choo]
- [choojs/nanocomponent-adapters][nca]
- [shama/bel](https://github.com/shama/bel)
- [choojs/nanohtml](https://github.com/choojs/nanohtml)
- [shama/on-load](https://github.com/shama/on-load)

## Examples
Expand Down Expand Up @@ -422,7 +422,7 @@ in the `beforerender` hook.
[9]: https://npmjs.org/package/nanocomponent
[10]: https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square
[11]: https://github.com/feross/standard
[bel]: https://github.com/shama/bel
[nanohtml]: https://github.com/choojs/nanohtml
[yoyoify]: https://github.com/shama/yo-yoify
[md]: https://github.com/patrick-steele-idem/morphdom
[210]: https://github.com/patrick-steele-idem/morphdom/pull/81
Expand Down
2 changes: 1 addition & 1 deletion example/leaflet.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ var Nanocomponent = require('../')
var nanologger = require('nanologger')
var leaflet = require('leaflet')
var onIdle = require('on-idle')
var html = require('bel')
var html = require('nanohtml')

module.exports = Leaflet

Expand Down
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Nanocomponent.prototype.render = function () {
renderTiming()
return el
} else if (this.element) {
el = this.element // retain reference, as the ID might change on render
el = this.element // retain reference, as the ID might change on render
var updateTiming = nanotiming(this._name + '.update')
var shouldUpdate = this._rerender || this.update.apply(this, args)
updateTiming()
Expand Down
9 changes: 5 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"test": "run-s test:*",
"test:deps": "dependency-check .",
"test:node": "NODE_ENV=test node test/node.js | tap-format-spec",
"test:browser": "browserify test/browser/index.js | tape-run | tap-format-spec",
"test:browser": "browserify test/browser/index.js | tape-run --render='tap-format-spec'",
"test:lint": "standard *.js",
"start": "bankai start example"
},
Expand All @@ -19,6 +19,7 @@
"url": "git+https://github.com/choojs/nanocomponent.git"
},
"keywords": [
"nanohtml",
"bel",
"choo",
"element",
Expand Down Expand Up @@ -49,7 +50,6 @@
"devDependencies": {
"@tap-format/spec": "^0.2.0",
"bankai": "^9.5.1",
"bel": "^5.1.1",
"browserify": "^16.0.0",
"choo": "^6.0.1",
"choo-log": "^8.0.0",
Expand All @@ -58,11 +58,12 @@
"leaflet": "^1.1.0",
"microbounce": "^1.0.0",
"nanobus": "^4.2.0",
"nanohtml": "^1.2.3",
"nanologger": "^1.3.1",
"npm-run-all": "^4.0.2",
"on-idle": "^3.1.0",
"standard": "^10.0.0",
"standard": "^11.0.1",
"tape": "^4.7.0",
"tape-run": "^3.0.4"
"tape-run": "^4.0.0"
}
}
2 changes: 1 addition & 1 deletion test/browser/blog-section.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
var Nanocomponent = require('../../')
var html = require('bel')
var html = require('nanohtml')

class BlogSection extends Nanocomponent {
constructor (name = 'BlogSection') {
Expand Down
2 changes: 1 addition & 1 deletion test/browser/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ var test = require('tape')
var SimpleComponent = require('./simple')
var BlogSection = require('./blog-section')
var Nanocomponent = require('../../')
var html = require('bel')
var html = require('nanohtml')
var compare = require('../../compare')
var nanobus = require('nanobus')

Expand Down
2 changes: 1 addition & 1 deletion test/browser/simple.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
var Nanocomponent = require('../../')
var html = require('bel')
var html = require('nanohtml')

module.exports = SimpleComponent

Expand Down
2 changes: 1 addition & 1 deletion test/node.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
var Nanocomponent = require('../')
var test = require('tape')
var html = require('bel')
var html = require('nanohtml')

test('cache', (t) => {
t.test('should validate input types', (t) => {
Expand Down

0 comments on commit fcf60f1

Please sign in to comment.