This repository has been archived by the owner on Jan 18, 2022. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 148
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: use default export mode for commonjs build
- Loading branch information
Showing
6 changed files
with
362 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,6 @@ | |
"version": "6.0.0-alpha.0", | ||
"license": "MIT", | ||
"main": "dist/index.js", | ||
"module": "dist/rollup-plugin-vue.esm.js", | ||
"typings": "dist/index.d.ts", | ||
"author": "Rahul Kadyan <[email protected]> (https://znck.me)", | ||
"files": [ | ||
|
@@ -12,24 +11,33 @@ | |
"dependencies": { | ||
"debug": "^4.1.1", | ||
"hash-sum": "^2.0.0", | ||
"lint-staged": "^10.1.1", | ||
"rollup-pluginutils": "^2.8.2", | ||
"sourcemap-codec": "^1.4.8" | ||
}, | ||
"peerDependencies": { | ||
"@vue/compiler-sfc": "*" | ||
}, | ||
"devDependencies": { | ||
"@vue/compiler-sfc": "^3.0.0-alpha.10", | ||
"@rollup/plugin-typescript": "^4.0.0", | ||
"@types/debug": "^4.1.5", | ||
"@types/jest": "^24.9.0", | ||
"@vue/compiler-sfc": "^3.0.0-alpha.10", | ||
"husky": "^4.2.0", | ||
"rollup": "^1.29.1", | ||
"tsdx": "^0.12.3", | ||
"tslib": "^1.10.0", | ||
"typescript": "^3.7.5" | ||
}, | ||
"husky": { | ||
"hooks": {} | ||
"hooks": { | ||
"pre-commit": "lint-staged" | ||
} | ||
}, | ||
"lint-staged": { | ||
"*.{ts,js,json}": [ | ||
"prettier --write" | ||
] | ||
}, | ||
"prettier": { | ||
"printWidth": 80, | ||
|
@@ -38,10 +46,10 @@ | |
"singleQuote": true | ||
}, | ||
"scripts": { | ||
"build": "tsdx build", | ||
"lint": "tsdx lint", | ||
"prepare": "tsdx build", | ||
"start": "tsdx watch", | ||
"build": "rollup -c", | ||
"lint": "tsdx lint src", | ||
"prepublishOnly": "npm run build", | ||
"start": "tsdx watch --target node", | ||
"test": "tsdx test" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import typescript from '@rollup/plugin-typescript' | ||
import { dependencies, peerDependencies } from './package.json' | ||
|
||
/** @type {import('rollup').RollupOptions} */ | ||
const config = { | ||
input: 'src/index.ts', | ||
output: { | ||
format: 'cjs', | ||
dir: 'dist', | ||
sourcemap: true, | ||
exports: 'default' | ||
}, | ||
external: [ | ||
'path', | ||
'querystring', | ||
...Object.keys(dependencies), | ||
...Object.keys(peerDependencies), | ||
], | ||
plugins: [typescript()] | ||
} | ||
|
||
export default config |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.