diff --git a/package.json b/package.json index 0d921ce..3d9e299 100644 --- a/package.json +++ b/package.json @@ -18,7 +18,7 @@ "dev": "rollup --config --watch", "prebuild": "yarn run clean", "build": "rollup --config", - "postbuild": "cp ./src/medium-zoom.d.ts ./dist", + "postbuild": "cp ./src/medium-zoom.d.ts ./dist && cp ./src/medium-zoom.d.ts ./dist/pure/index.d.ts", "prepublishOnly": "npm run build", "lint": "eslint .", "format": "prettier --write *.{js,json,css,md} && yarn run lint --fix", diff --git a/rollup.config.js b/rollup.config.js index d77fc27..ef16297 100644 --- a/rollup.config.js +++ b/rollup.config.js @@ -67,4 +67,27 @@ export default [ }, plugins: [...sharedPlugins, terser(), license({ banner })], }, + // pure + { + input: 'src/medium-zoom.js', + output: { + file: 'dist/pure/index.js', + format: 'es', + }, + plugins: [...sharedPlugins, license({ banner })], + }, + { + input: 'src/medium-zoom.css', + output: { + file: 'dist/pure/style.css', + format: 'es', + }, + plugins: [ + postcss({ + extract: true, + minimize: true, + }), + license({ banner }), + ], + }, ]