keystonejs / keystone

The superpowered headless CMS for Node.js — built with GraphQL and React
https://keystonejs.com
MIT License
9.17k stars 1.15k forks source link

Keystone js does not support custom babel configuration #7635

Closed leobar37 closed 2 years ago

leobar37 commented 2 years ago

I want to use the schema extension from keystone js , and i want to use type-graphl to make the schema. but i came across a problem.

image

It does not allow me to add decorators, I could solve this, by adding the following preset to the configuration.

{
  "plugins": [["@babel/plugin-proposal-decorators", { "legacy": true }]]
}

But I can't figure out how to add this preset.

Achisingh commented 2 years ago

Hi @leobar37 Keystone currently does not support custom babel configs because we don't want to be coupled to babel. For e.g. we partially use SWC and we are moving in the direction of exclusively using SWC.