static async loadCJS(filepath, code) {
        // Once transpiled, we temporarily modify the require function
        // so that when it loads the config file, it will load the transpiled
        // version instead, and all of the require calls inside that will still work.
        let defaultLoader = require.extensions['.js'];
        require.extensions['.js'] = (module, filename) => {
            if (filename === filepath) {
                // @ts-ignore
                module._compile(code, filename);
            } else {
                defaultLoader(module, filename);
            }
        };

        delete require.cache[filepath];

        // Load the config file. If it uses ESM export, it will
        // be exported with a default key, so get that. Otherwise
        // if it was written in CJS, use the root instead.
        let config = require(filepath);
        config = config.default || config;
        require.extensions['.js'] = defaultLoader;

        return config;
    }
Uses compiler to compile rollup.config.js file.
This allows config file to use ESM, but compiles to CJS
so that import statements change to require statements.

@param {string} filepath
@param {string} code
@return {Promise<object>}