houdini/config/webpack/environment.js

16 lines
477 B
JavaScript

const { environment } = require('@rails/webpacker')
const ForkTsCheckerWebpackPlugin = require("fork-ts-checker-webpack-plugin");
const path = require("path");
const erb = require('./loaders/erb')
environment.loaders.prepend('erb', erb)
environment.plugins.append(
"ForkTsCheckerWebpackPlugin",
new ForkTsCheckerWebpackPlugin({
typescript: {
tsconfig: path.resolve(__dirname, "../../tsconfig.json"),
},
async: false,
})
);
module.exports = environment