From ad1fe50546f112e5efae55ab2957007dee29d86c Mon Sep 17 00:00:00 2001 From: Sathya Gunasekaran Date: Mon, 23 Oct 2023 15:41:01 +0100 Subject: [PATCH] [playground] Turn on Forget Runs Forget on the playground, so we can dogfood Forget and experiment with improvements to UX. Opts out of compiling the layout page because thats run on the server which doesn't seem to have access to useMemoCache. --- compiler/apps/playground/app/layout.tsx | 1 + compiler/apps/playground/babel.config.js | 16 ++++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 compiler/apps/playground/babel.config.js diff --git a/compiler/apps/playground/app/layout.tsx b/compiler/apps/playground/app/layout.tsx index 630e7d1671..204d048f9f 100644 --- a/compiler/apps/playground/app/layout.tsx +++ b/compiler/apps/playground/app/layout.tsx @@ -12,6 +12,7 @@ export default function RootLayout({ }: { children: React.ReactNode; }) { + "use no forget"; return ( diff --git a/compiler/apps/playground/babel.config.js b/compiler/apps/playground/babel.config.js new file mode 100644 index 0000000000..07c3670088 --- /dev/null +++ b/compiler/apps/playground/babel.config.js @@ -0,0 +1,16 @@ +module.exports = function (api) { + api.cache(true); + return { + presets: ["next/babel"], + plugins: [ + [ + "babel-plugin-react-forget", + { + gating: null, + compilationMode: "infer", + panicThreshold: "NONE", + }, + ], + ], + }; +};