js-gravatar
Version:
A vanilla JS library to get a user's gravatar and if it doesn't exist provides one different from gravatar default
28 lines (24 loc) • 525 B
JavaScript
const path = require('path');
const BUILD_DIR = path.resolve(__dirname, 'dist/');
const APP_DIR = path.resolve(__dirname, 'lib/');
const config = {
entry: APP_DIR + '/js-gravatar.js',
output: {
path: BUILD_DIR,
filename: 'js-gravatar.js',
publicPath: 'dist/',
library: 'jsGravatar',
libraryExport: 'default',
libraryTarget: 'umd',
},
module: {
rules: [
{
test: /\.js/,
include: APP_DIR,
loader: 'babel-loader'
}
]
}
};
module.exports = config;