Skip to content
This repository was archived by the owner on Nov 3, 2021. It is now read-only.

Commit cdc8905

Browse files
authored
Bump to allow for React 16, fix test (#12)
* Bump to allow for React 16, fix test * Bump package version to 1.1.1
1 parent ad0b008 commit cdc8905

File tree

3 files changed

+12
-11
lines changed

3 files changed

+12
-11
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# Changelog
22

3+
## 1.1.1
4+
* Drop deprecated React.createClass, React.DOM from test
5+
* Bump to allow for React ^16.0.0
6+
37
## 1.1.0
48
* Update to Babel 6 and bump node testing version to 5.11.1
59

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "interpolate-components",
3-
"version": "1.1.0",
3+
"version": "1.1.1",
44
"description": "Convert strings into structured React components.",
55
"repository": {
66
"type": "git",
@@ -33,9 +33,9 @@
3333
"test": "test"
3434
},
3535
"dependencies": {
36-
"react": "^0.14.3 || ^15.1.0",
36+
"react": "^0.14.3 || ^15.1.0 || ^16.0.0",
3737
"react-addons-create-fragment": "^0.14.3 || ^15.1.0",
38-
"react-dom": "^0.14.3 || ^15.1.0"
38+
"react-dom": "^0.14.3 || ^15.1.0 || ^16.0.0"
3939
},
4040
"author": "Bob Ralian <bob.ralian@gmail.com> (http://github.com/rralian)",
4141
"license": "GPL-2.0"

test/test.jsx

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,13 @@ import React from 'react';
1111
import interpolateComponents from '../src/index';
1212

1313
describe( 'interpolate-components', () => {
14-
const input = React.DOM.input();
15-
const div = React.DOM.div();
14+
const input = <input />;
15+
const div = <div />;
1616
const link = <a href="#" />;
1717
const em = <em />;
18-
const CustomComponentClass = React.createClass( {
19-
displayName: 'CustomComponentClass',
20-
render() {
21-
return <span className="special">{ this.props.intro }{ this.props.children }</span>;
22-
}
23-
} );
18+
const CustomComponentClass = ( { children, intro } ) => (
19+
<span className="special">{ intro }{ children }</span>
20+
);
2421

2522
describe( 'with default container', () => {
2623
it( 'should return a react object with a span container', () => {

0 commit comments

Comments
 (0)