// vite.config.mts
import path, { resolve } from "path";
import { defineConfig } from "file:///Users/thecodrr/Sources/Repos/notesnook/packages/intl/node_modules/vite/dist/node/index.js";
import swc from "file:///Users/thecodrr/Sources/Repos/notesnook/packages/intl/node_modules/vite-plugin-swc-transform/dist/esm/index.js";
import dts from "file:///Users/thecodrr/Sources/Repos/notesnook/packages/intl/node_modules/vite-plugin-dts/dist/index.mjs";
import { fileURLToPath } from "url";
var __vite_injected_original_import_meta_url = "file:///Users/thecodrr/Sources/Repos/notesnook/packages/intl/vite.config.mts";
var __filename = fileURLToPath(__vite_injected_original_import_meta_url);
var __dirname = path.dirname(__filename);
var vite_config_default = defineConfig({
  plugins: [
    swc({
      swcOptions: {
        sourceMaps: true,
        jsc: {
          parser: {
            syntax: "typescript",
            tsx: true
          },
          baseUrl: __dirname,
          paths: {
            "$src/*": ["src/*"]
          },
          experimental: {
            plugins: [
              [
                "@lingui/swc-plugin",
                {
                  runtimeModules: {
                    i18n: ["$src/setup", "i18n"]
                  }
                }
              ]
            ]
          }
        }
      }
    }),
    dts({
      exclude: ["**/locales/*.json"],
      rollupTypes: true
    })
  ],
  build: {
    lib: {
      entry: resolve(__dirname, "src/index.ts"),
      formats: ["cjs", "es"],
      fileName(format) {
        return format === "cjs" ? "index.js" : "index.mjs";
      }
    },
    outDir: resolve(__dirname, "dist")
  }
});
export {
  vite_config_default as default
};
//# sourceMappingURL=data:application/json;base64,[encoded data, 4556 characters]
