Skip to content

Commit

Permalink
Upgrade to the new rollup hook and added rollup 65 peer
Browse files Browse the repository at this point in the history
  • Loading branch information
TrySound committed Aug 30, 2018
1 parent a39e9f9 commit ab6f418
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion index.js
Expand Up @@ -7,7 +7,7 @@ function uglify(userOptions) {
return {
name: "uglify",

transformBundle(code) {
renderChunk(code) {
const worker = new Worker(require.resolve("./transform.js"));

return worker
Expand Down
3 changes: 3 additions & 0 deletions package.json
Expand Up @@ -26,6 +26,9 @@
"@babel/code-frame": "^7.0.0-beta.47",
"uglify-js": "^3.3.25"
},
"peerDependencies": {
"rollup": ">=0.65.0 <1"
},
"devDependencies": {
"@babel/core": "^7.0.0-beta.47",
"@babel/preset-env": "^7.0.0-beta.47",
Expand Down
2 changes: 1 addition & 1 deletion test/test.js
Expand Up @@ -43,7 +43,7 @@ test("throw error on uglify fail", async () => {
input: "test/fixtures/failed.js",
plugins: [
{
transformBundle: () => ({ code: "var = 1" })
renderChunk: () => ({ code: "var = 1" })
},
uglify()
]
Expand Down

0 comments on commit ab6f418

Please sign in to comment.