mirror of
https://github.com/supabase/supabase.git
synced 2026-05-07 09:20:21 -04:00
f8183479e7
Switch studio's package.json to `"type": "module"` so the package runs as native ESM. This aligns the runtime module system with what we actually write (`import`/`export`), improves tree-shaking, and reduces friction with ESM-only dependencies. **Changed:** - `next.config.js` → `next.config.ts` – ESM imports/exports, proper TS types, fixed type narrowing on redirect `has` and `basePath` fields - `csp.js` → `csp.ts` – `module.exports.getCSP` → named `export function` - `tailwind.config.js` → `tailwind.config.ts` – ESM imports - `postcss.config.js` – `module.exports` → `export default` (stays `.js` since PostCSS doesn't support TS configs) **Removed:** - Unused `path` import in next config - Deprecated Sentry `hideSourceMaps` option (default behavior in Sentry v10) **Added:** - Type declaration for `config/tailwind.config` CJS package ## To test - A general smoke test of studio should suffice <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Modernized the Studio package to ES module style and improved TypeScript typings and config declarations to reduce build/runtime issues. * Updated styling and post-processing configuration format for more consistent tooling behavior. * **Chores** * Updated code ownership entries to reflect migrated/renamed configuration files. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com>