Created
October 27, 2018 08:02
-
-
Save ultrox/518a4b0dac3d404343c1ad07402e95a6 to your computer and use it in GitHub Desktop.
From how to build open source lib - Kent C. Dodds
This file contains hidden or 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
//https://egghead.io/lessons/javascript-add-a-browser-build-to-an-npm-module | |
import { join } from "path"; | |
export default { | |
entry: "./src/index.js", | |
output: { | |
path: join(__dirname, "dist"), | |
libraryTarget: "umd", | |
library: "starWarsNames" | |
}, | |
devtool: "source-map", | |
module: { | |
rules: [{ test: /\.js$/, use: "babel-loader" }] | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment