Skip to content
This repository was archived by the owner on Jan 27, 2023. It is now read-only.

Commit 5c2544b

Browse files
committed
update rollup config for name of file
1 parent 80a18fa commit 5c2544b

File tree

6 files changed

+6
-5
lines changed

6 files changed

+6
-5
lines changed

dist/ScrollMemory.min.js

+1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/bundle.js

-1
This file was deleted.

index.js

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
module.exports = require('./dist/ScrollMemory.min.js');

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
"scripts": {
77
"test": "echo \"Error: no test specified\" && exit 1",
88
"flow": "node_modules/.bin/flow",
9-
"prepublish": "webpack --config webpack.config.js"
9+
"build": "rollup -c",
10+
"prepublish": "npm run build"
1011
},
1112
"repository": {
1213
"type": "git",

rollup.config.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import babel from 'rollup-plugin-babel';
33
import uglify from 'rollup-plugin-uglify';
44

55
export default {
6-
entry: 'src/index.js',
6+
entry: 'src/ScrollMemory.js',
77
format: 'cjs',
88
plugins: [
99
resolve(),
@@ -13,5 +13,5 @@ export default {
1313
uglify(),
1414
],
1515
external: ['react', 'react-router-dom'],
16-
dest: 'dist/bundle.js',
16+
dest: 'dist/ScrollMemory.min.js',
1717
};

src/index.js renamed to src/ScrollMemory.js

-1
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ class ScrollMemory extends Component {
5858
});
5959
}
6060
render(): null {
61-
// return Children.only(this.props.children);
6261
return null;
6362
}
6463
}

0 commit comments

Comments
 (0)