multipassify-ts
Version:
This is an example TypeScript Package ready to be published on npm. It has been set up with automated tests and package publishing workflow using GitHub Actions CI/CD. It is made primarily for GitHub + VS Code (Windows / Mac / Linux) users who are about t
43 lines (41 loc) • 945 B
JavaScript
const path = require('path')
module.exports = {
mode: 'production',
entry: './src/index.ts',
output: {
path: path.resolve(__dirname, '../dist/umd'),
filename: 'index.js',
library: 'exampleTypescriptPackage',
libraryTarget: 'umd',
globalObject: 'this',
},
module: {
rules: [
{
test: /\.ts(x*)?$/,
exclude: /node_modules/,
use: {
loader: 'ts-loader',
options: {
configFile: 'config/tsconfig.umd.json',
},
},
},
],
},
resolve: {
extensions: ['.ts', '.js', '.tsx', '.jsx'],
fallback: {
fs: false,
tls: false,
net: false,
path: false,
zlib: false,
http: false,
https: false,
stream: false,
crypto: false,
'crypto-browserify': require.resolve('crypto-browserify'), //if you want to use this module also don't forget npm i crypto-browserify
},
},
}