mirror of
https://github.com/w-okada/voice-changer.git
synced 2025-02-03 08:43:57 +03:00
35 lines
852 B
JavaScript
35 lines
852 B
JavaScript
|
const path = require("path");
|
||
|
const webpack = require("webpack");
|
||
|
module.exports = {
|
||
|
entry: "./src/index.ts",
|
||
|
resolve: {
|
||
|
extensions: [".ts", ".js"],
|
||
|
},
|
||
|
module: {
|
||
|
rules: [
|
||
|
{
|
||
|
test: [/\.ts$/, /\.tsx$/],
|
||
|
use: [
|
||
|
{
|
||
|
loader: "ts-loader",
|
||
|
options: {
|
||
|
configFile: "tsconfig.json",
|
||
|
},
|
||
|
},
|
||
|
],
|
||
|
},
|
||
|
],
|
||
|
},
|
||
|
output: {
|
||
|
filename: "index.js",
|
||
|
path: path.resolve(__dirname, "dist"),
|
||
|
libraryTarget: "umd",
|
||
|
globalObject: "typeof self !== 'undefined' ? self : this",
|
||
|
},
|
||
|
plugins: [
|
||
|
new webpack.ProvidePlugin({
|
||
|
process: "process/browser",
|
||
|
}),
|
||
|
],
|
||
|
};
|