How to remove Auto-generated code by Inferencer in refine project?

595 views Asked by At

As I am new for refine.dev. So, I just want to remove this section

Mark the particular code sniped what should be removed. Aslo show me the file structure and where it locates. I also can't find the layout or the sidebar to edit?

2

There are 2 answers

0
Imanuel Pundoko On

You can check on the official documentation Hiding the Code Viewer and Development Warning

If you want to hide the code viewer and the warning components, you can use the hideCodeViewerInProduction prop.

You need to know that this inferencer is not recommended to be used during production mode

Please note that the Inferencer components are not meant to be used in production. They are meant to be used in development mode to help you generate the code for your components.

0
Abdullah Numan On

You can just replace the existing code in the CRUD pages (which use Inferencer components) with the generated code available inside the browser modal. That way, you'll have some starter code which you can tailor and build up on:

The aim is to reduce the amount of time spent on creating views for resources by generating the code automatically that can be customized easily.

One aim of the Inferencer is to give us the full shape of API the response and autogenerate some markup with all fields of the resource. It's very handy!