租房小程序前端代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
561 B

3 months ago
  1. import { createRequire } from 'module';
  2. import { fileURLToPath } from 'url';
  3. import { dirname } from 'path';
  4. /**
  5. * @fileoverview Universal module importer
  6. */
  7. //-----------------------------------------------------------------------------
  8. // Helpers
  9. //-----------------------------------------------------------------------------
  10. const __filename = fileURLToPath(import.meta.url);
  11. const __dirname = dirname(__filename);
  12. const require = createRequire(__dirname + "/");
  13. const { ModuleImporter } = require("./module-importer.cjs");
  14. export { ModuleImporter };