'use strict';

var chunkAF3E2D32_cjs = require('./chunk-AF3E2D32.cjs');
var readFile = require('@stryke/fs/read-file');
var correctPath = require('@stryke/path/correct-path');

function compilerPlugin(context, options) {
  return {
    name: "storm-stack:compiler",
    setup(build) {
      build.onLoad({
        filter: /\.ts$/
      }, async (args) => {
        return {
          contents: await context.compiler.compile(context, correctPath.normalizeWindowsPath(args.path), await readFile.readFile(args.path), options)
        };
      });
    }
  };
}
chunkAF3E2D32_cjs.__name(compilerPlugin, "compilerPlugin");

exports.compilerPlugin = compilerPlugin;
//# sourceMappingURL=chunk-5X442PKU.cjs.map
//# sourceMappingURL=chunk-5X442PKU.cjs.map