<commit_before>import { IFs, fs } from "memfs";
import * as path from "path";


export class HmrHelper
{
    private static _devFs: IFs = null;
    private static _outputPath: string = null;
    
    
    public static get devFs(): IFs { return this._devFs; }
    public static get outputPath(): string { return this._outputPath; }
    
        
    /**
     * @static
     */
    private constructor() { }
    
    
    public static configure(): void
    {
        const devFs: any = fs;
        devFs.join = path.join.bind(path); // no need to bind
        this._devFs = devFs;
        
        const config = require(path.join(process.cwd(), "webpack.config.js"));
        this._outputPath = config.output.path;
    }<commit_msg>dev middleware fs changes<commit_after>import { IFs, createFsFromVolume, Volume } from "memfs";
import * as path from "path";
const mkdirp = require("mkdirp");


export class HmrHelper
{
    private static _devFs: IFs = null;
    private static _outputPath: string = null;
    
    
    public static get devFs(): IFs { return this._devFs; }
    public static get outputPath(): string { return this._outputPath; }
    
        
    /**
     * @static
     */
    private constructor() { }
    
    
    public static configure(): void
    {
        const devFs: any = createFsFromVolume(new Volume());
        devFs.join = path.join.bind(path);
        devFs.mkdirp = mkdirp.bind(mkdirp);
        this._devFs = devFs;
        
        const config = require(path.join(process.cwd(), "webpack.config.js"));
        this._outputPath = config.output.path;
    }
{'fraction_non_alphanumeric': 0.11627906976744186, 'fraction_numerical': 0.0, 'mean_word_length': 2.316666666666667, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1828436', 'n_tokens_mistral': 499, 'n_tokens_neox': 475, 'n_words': 130}