const { resolve } = require("path");

module.exports = function (webpack) {
  webpack.Utils.addCopyRule({
    from: resolve(__dirname, "dist/libSwiftBridge.node"),
    to: "../libSwiftBridge.node",
    noErrorOnMissing: true,
  });

  webpack.Utils.addCopyRule({
    from: resolve(__dirname, "dist/libNodeAPI.dylib"),
    to: "../libNodeAPI.dylib",
    noErrorOnMissing: true,
  });
};
