mirror of
https://github.com/ringtools/ringtools-web-v2.git
synced 2024-11-19 07:40:01 +01:00
27 lines
566 B
TypeScript
27 lines
566 B
TypeScript
import * as webpack from 'webpack';
|
|
import {
|
|
CustomWebpackBrowserSchema,
|
|
TargetOptions,
|
|
} from '@angular-builders/custom-webpack';
|
|
const Dotenv = require('dotenv-webpack');
|
|
|
|
require('dotenv').config();
|
|
|
|
export default (
|
|
config: webpack.Configuration,
|
|
_options: CustomWebpackBrowserSchema,
|
|
_targetOptions: TargetOptions
|
|
) => {
|
|
config.plugins?.push(new Dotenv({
|
|
allowEmptyValues: true,
|
|
systemvars: true,
|
|
defaults: true
|
|
}));
|
|
|
|
config.plugins?.push(new webpack.ProvidePlugin({
|
|
Buffer: ['buffer', 'Buffer'],
|
|
}));
|
|
|
|
return config;
|
|
};
|