text: /* eslint-disable @typescript-eslint/no-var-requires */
  const path = require('path')
  const HtmlWebpackPlugin = require('html-webpack-plugin')
  
  module.exports = {
      entry: './src/index.jsx',
      output: {
          filename: 'bundle.js',
          path: path.resolve(__dirname, '../dist'),
      },
      module: {
          rules: [
              {
                  test: /\.tsx?$/,
                  loaders: ['babel-loader', 'ts-loader'],
                  exclude: [/(node_modules|bower_components)/],
              },
              {
                  test: /\.(jsx?)$/,
                  loaders: ['babel-loader'],
                  exclude: [/(node_modules|bower_components)/],
              },
              { test: /\.css$/, use: ['style-loader', 'css-loader'] },
              {
                  test: /\.scss$/,
                  loader: ['style-loader', 'css-loader', 'sass-loader'],
              },
              {
                  test: /\.(png|jpe?g|gif|ttf|otf)$/,
                  use: [
                      {
                          loader: 'file-loader',
                          options: {
                              name: '[path][name].[ext]',
                          },
                      },
                  ],
              },
          ],
      },
      plugins: [
          new HtmlWebpackPlugin({
              title: 'Hello World',
              template: 'template.html',
          }),
      ],
      resolve: {
          extensions: ['.js', '.jsx', '.ts', '.tsx', '.d.tsx', '.css', '.scss'],
      },
  }
  