open-index/open-npm huggingface dataset:
npm package: @koala-framework/trl-webpack-plugin
Description: ## Usage Add Plugin in `webpack.config.js`
Author: Alexander Kaufmann
Latest version: 1.0.1

# trl-webpack-plugin

## Usage
Add Plugin in `webpack.config.js`

    const vendorPoFiles = [];
    glob.sync(path.resolve(__dirname, '../vendor/*/*/trl/en.po')).forEach(i => {
        vendorPoFiles.push(i.replace(/\/en\.po$/, '/[language].po'));
    });
    const languages = ['de'];
    
    plugins: [
        ...
        new TrlPlugin.default({
            uniquePrefix,
            languages,
            webCodeLanguage: 'de',
            translations: {
                web: TrlPlugin.loadTranslations(['../trl/[language].po'], languages),
                kwf: TrlPlugin.loadTranslations(vendorPoFiles, languages),
            }
        })
        ...
    ]

also add uniquePrefix to define plugin, this is used as prefix for trl functions

    new webpack.DefinePlugin({
        UNIQUE_PREFIX: JSON.stringify(uniquePrefix ? uniquePrefix + "-" : "")
    })