Hi, I'm facing this error
Answered
Spectacled bear posted this in #help-forum
Spectacled bearOP
Syntax error: "next/font" requires SWC although Babel is being used due to a custom babel config being present.
I tried this, but still getting the issue. Could someone pls help
I tried this, but still getting the issue. Could someone pls help
6 Replies
Answer
you must remove the babel config file to use next/font. so you have to choose one here: next/font or your babel config – you cannot choose both
@joulev you must remove the babel config file to use next/font. so you have to choose one here: next/font or your babel config – you cannot choose both
Spectacled bearOP
Okay thank @joulev 😊. But some required a babel-loader so I have added that.
Can those too be handled by SWC? Or how should I go about..?
Can those too be handled by SWC? Or how should I go about..?
@Spectacled bear Okay thank <@484037068239142956> 😊. But some required a babel-loader so I have added that.
Can those too be handled by SWC? Or how should I go about..?
why do you need babel here? depends on the reason you added babel in the first place, you could migrate that to swc
Spectacled bearOP
okay, let me check, thanks for elaborating