text: const path = require('path');
  const pjson = require('./package.json');
  
  const pluginName = pjson.name;
  
  const config = {
    entry: ['./src/index.js'],
    output: {
      path: path.resolve(__dirname, 'build'),
      filename: 'main.js',
      libraryTarget: 'umd',
    },
    resolve: {
      extensions: ['.js', '.jsx', '.sass', '.scss', '.css'],
      alias: {
        components: path.resolve(__dirname, 'src/components'),
        constants: path.resolve(__dirname, 'src/constants'),
        icons: path.resolve(__dirname, 'src/icons'),
        hooks: path.resolve(__dirname, 'src/hooks'),
        utils: path.resolve(__dirname, 'src/utils'),
      }
    },
    module: {
      rules: [
        {
          test: /\.(sa|sc)ss$/,
          exclude: /node_modules/,
          use: [
            'style-loader',
            {
              loader: 'css-loader',
              options: {
                modules: {
                  localIdentName: `${pluginName}_[name]__[local]--[hash:base64:5]`,
                },
              },
            },
            'sass-loader',
            {
              loader: 'sass-resources-loader',
              options: {
                resources: path.resolve(__dirname, './src/common/css/variables.scss'),
              },
            },
          ],
        },
        {
          test: /\.(js|jsx)$/,
          use: 'babel-loader',
          exclude: /node_modules/,
        },
        {
          test: /\.svg$/,
          loader: 'svg-inline-loader',
        },
      ],
    },
  };
  
  module.exports = config;
  