ambitious-crowd-69774
07/22/2022, 4:03 AMSyntaxError: Named export 'GrowthBook' not found. The requested module '@growthbook/growthbook' is a CommonJS module, which may not support all module.exports as named exports.
Im testing this in a barebones sveltekit/typescript project and just by importing growthbook it throws this error at build time.
This is my import - copied from docs:
Import { GrowthBook } from “@growthbook/growthbook”
This is a barebones, fresh sveltekit app I'm testing on. Runs fine during dev but fails at build.
Does anyone have any ideas here ?fresh-football-47124
ambitious-crowd-69774
07/22/2022, 4:07 AMfresh-football-47124
ambitious-crowd-69774
07/22/2022, 4:08 AMfresh-football-47124
ambitious-crowd-69774
07/22/2022, 4:10 AMfresh-football-47124
ambitious-crowd-69774
07/22/2022, 4:21 AMvite build
on node v16.9.1
and got the same error. Any ideas what to try next ?fresh-football-47124
ambitious-crowd-69774
07/22/2022, 4:28 AMfuture-teacher-7046
ambitious-crowd-69774
07/22/2022, 4:31 AMtype: module
in my package.json ?future-teacher-7046
ambitious-crowd-69774
07/22/2022, 4:33 AMfuture-teacher-7046
ambitious-crowd-69774
07/22/2022, 4:36 AMfresh-football-47124