{"library":"remix-esbuild-override","title":"remix-esbuild-override","description":"A third-party library that allows overriding esbuild configuration in the Remix compiler. Current stable version is 3.1.0 (May 2023). It patches esbuild at runtime to let developers modify plugins, loaders, and other esbuild options. Unlike Remix's intentional restriction on exposing compiler config, this library provides a workaround via a postinstall script and a `withEsbuildOverride` function in `remix.config.js`. Requires @remix-run/dev >=1.2.0. Ships TypeScript types. Known for potential instability in production; use with caution.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install remix-esbuild-override"],"cli":null},"imports":["const { withEsbuildOverride } = require('remix-esbuild-override')","import type { EsbuildOption } from 'remix-esbuild-override'"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"// remix.config.js\nconst { withEsbuildOverride } = require('remix-esbuild-override');\n\nwithEsbuildOverride((option, { isServer, isDev }) => {\n  // Example: add a custom esbuild plugin\n  if (isServer) {\n    option.plugins = [/* your plugin */, ...(option.plugins || [])];\n  }\n  return option;\n});\n\n/** @type {import('@remix-run/dev').AppConfig} */\nmodule.exports = {\n  // your Remix config\n  appDirectory: \"app\",\n  ignoredRouteFiles: [\"*.css\"],\n};\n","lang":"javascript","description":"Shows how to use withEsbuildOverride in remix.config.js to modify esbuild options per environment.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}