Skip to content

Commit 42964d0

Browse files
authored
Merge pull request #103 from ganderzz/feature/update-deps
Feature/update deps
2 parents 8d53f6d + 71e1d93 commit 42964d0

File tree

5 files changed

+3435
-2351
lines changed

5 files changed

+3435
-2351
lines changed

.storybook/webpack.config.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
const path = require("path");
22

3-
module.exports = (baseConfig, env, config) => {
3+
module.exports = ({ config }) => {
44
config.module.rules.push({
55
test: /\.(ts|tsx)$/,
66
use: [
@@ -12,6 +12,8 @@ module.exports = (baseConfig, env, config) => {
1212
}
1313
]
1414
});
15+
1516
config.resolve.extensions.push(".ts", ".tsx");
17+
1618
return config;
1719
};

package.json

Lines changed: 25 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-scroll-to",
3-
"version": "2.0.5",
3+
"version": "2.0.9",
44
"description": "Scroll to a position using react",
55
"main": "./dist/react-scroll-to.js",
66
"types": "./dist/definitions",
@@ -9,6 +9,7 @@
99
"test:cover": "jest --coverage",
1010
"build": "webpack --config=./config/webpack.config.js --mode=development",
1111
"build:prod": "webpack --config=./config/webpack.config.js --mode=production",
12+
"prepublish": "npm run build:prod",
1213
"contributors:add": "all-contributors add",
1314
"contributors:generate": "all-contributors generate",
1415
"storybook": "start-storybook -p 9001 -c .storybook",
@@ -32,36 +33,37 @@
3233
},
3334
"homepage": "https://github.com/ganderzz/react-scroll-to#readme",
3435
"peerDepedencies": {
35-
"react": "^15.0.0 || ^16.0.0"
36+
"react": ">= ^16.0.0"
3637
},
3738
"devDependencies": {
38-
"@babel/core": "7.2.2",
39-
"@babel/plugin-proposal-class-properties": "7.2.3",
40-
"@babel/preset-env": "7.2.3",
39+
"@babel/core": "7.4.5",
40+
"@babel/plugin-proposal-class-properties": "7.4.4",
41+
"@babel/preset-env": "7.4.5",
4142
"@babel/preset-react": "7.0.0",
42-
"@storybook/react": "4.1.6",
43-
"all-contributors-cli": "5.7.0",
43+
"@storybook/react": "5.0.11",
44+
"all-contributors-cli": "6.6.0",
4445
"babel-core": "7.0.0-bridge.0",
45-
"babel-jest": "23.6.0",
46-
"babel-loader": "8.0.5",
46+
"babel-jest": "24.8.0",
47+
"babel-loader": "8.0.6",
4748
"copy-webpack-plugin": "4.6.0",
4849
"enzyme": "3.7.0",
4950
"enzyme-adapter-react-16": "1.6.0",
50-
"eslint": "5.12.0",
51+
"eslint": "5.16.0",
5152
"eslint-config-airbnb": "17.1.0",
52-
"eslint-config-prettier": "3.3.0",
53-
"eslint-plugin-import": "2.14.0",
54-
"eslint-plugin-jsx-a11y": "6.1.2",
55-
"eslint-plugin-react": "7.12.3",
56-
"husky": "1.3.1",
57-
"jest": "23.6.0",
58-
"lint-staged": "8.1.0",
59-
"prettier": "1.15.3",
60-
"react": "16.7.0",
61-
"react-dom": "16.7.0",
62-
"react-testing-library": "5.4.4",
63-
"webpack": "4.28.4",
64-
"webpack-cli": "3.2.1"
53+
"eslint-config-prettier": "4.3.0",
54+
"eslint-plugin-import": "2.17.2",
55+
"eslint-plugin-jsx-a11y": "6.2.1",
56+
"eslint-plugin-react": "7.13.0",
57+
"husky": "2.3.0",
58+
"jest": "24.8.0",
59+
"lint-staged": "8.1.7",
60+
"prettier": "1.17.1",
61+
"react": "16.8.6",
62+
"react-dom": "16.8.6",
63+
"react-testing-library": "7.0.1",
64+
"ts-loader": "^6.0.1",
65+
"webpack": "4.32.1",
66+
"webpack-cli": "3.3.2"
6567
},
6668
"jest": {
6769
"setupFiles": [

src/tests/ScrollToHOC.spec.jsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,15 @@ describe("Test HOC.", () => {
4646
<div>
4747
<div id="foo" />
4848
<button onClick={() => props.scrollTo({ id: "foo", x: 100, y: 200 })}>
49-
test
49+
test-btn
5050
</button>
5151
</div>
5252
);
5353
});
5454

5555
const { getByText, container } = render(<WrappedComponent />);
5656

57-
fireEvent.click(getByText("test"));
57+
fireEvent.click(getByText("test-btn"));
5858

5959
expect(container).toMatchSnapshot();
6060
});

src/tests/__snapshots__/ScrollToHOC.spec.jsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ exports[`Test HOC. Should call scrollById. 1`] = `
77
id="foo"
88
/>
99
<button>
10-
test
10+
test-btn
1111
</button>
1212
</div>
1313
</div>

0 commit comments

Comments
 (0)