Refactor Rslib-builder Into A Pnpm Monorepo

by Jule 44 views
Refactor Rslib-builder Into A Pnpm Monorepo

rslib-builder’s move into a pnpm monorepo isn’t just a cleaner file structure - it’s a strategic shift to real-world integration testing. By replacing symlink-heavy fixtures with actual workspace:* dependencies, we unlock precise runtime validation and break subtle DTS path bugs like the infamous double-nesting in dist/<mode>/runtime/index.d.ts. This isn’t about flashy tools; it’s about aligning development practice with how modern JS libraries actually consume and resolve dependencies. Think of the current setup as a behind-the-scenes tour - you see the end result, but not the journey. Now, every test walks the full chain: builder → plugin → modules → site. turbo orchestrates it all. The real payoff? Inspecting real build output, fixing path mismatches like the DTS double-nest, and ensuring the plugin’s runtime behaves as expected. For teams building scalable component ecosystems, this isn’t optional - it’s the future of safe, reliable integration testing.