From 46669728900c3c6575a954e6927a0a8b3d5c7195 Mon Sep 17 00:00:00 2001 From: Phoenix Eliot Date: Wed, 29 May 2024 15:55:42 -0400 Subject: [PATCH] docs: Add installation note for Next.js (#3263) This adds a note for Next.js users, who (unintuitively) must configure babel even if their project uses typescript. --- docs/installation.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/installation.md b/docs/installation.md index af1457d39..6d409d00b 100644 --- a/docs/installation.md +++ b/docs/installation.md @@ -50,6 +50,8 @@ For verification insert this piece of code at the beginning of your sources (eg. if (!new class { x }().hasOwnProperty('x')) throw new Error('Transpiler is not configured correctly'); ``` +Note that for Next.js you must [customize Babel](https://nextjs.org/docs/advanced-features/customizing-babel-config) instead of TypeScript, even if your project is set up to use TypeScript. + ## MobX on older JavaScript environments By default, MobX uses proxies for optimal performance and compatibility. However, on older JavaScript engines `Proxy` is not available (check out [Proxy support](https://kangax.github.io/compat-table/es6/#test-Proxy)). Examples of such are Internet Explorer (before Edge), Node.js < 6, iOS < 10, Android before RN 0.59, or Android on iOS.