Skip to content

Instantly share code, notes, and snippets.

@hoiheart
Last active February 17, 2020 01:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hoiheart/a78c5cd44c28d43c556b083d5ff44f28 to your computer and use it in GitHub Desktop.
Save hoiheart/a78c5cd44c28d43c556b083d5ff44f28 to your computer and use it in GitHub Desktop.
es5 vue plugin (package.json)
{
"main": "dist/index.js", // umd
"module": "dist/esm/src/index.js", // esm : import 호출 시 main 보다 우선시 된다.
"sideEffects": [
// 기본적으로 트리쉐이킹 지원 모듈은 sideEffects: false 를 사용해야 하지만,
// vue-cli의 개발 환경에서는 이를 사용하면 안되기 때문에 개발 환경인 src 폴더만 sideEffects 를 허용한다.
// https://cli.vuejs.org/guide/build-targets.html#library
"src/**/*.*"
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment