Custom mimerendering extension for csv files

I am trying to create a custom extension for rendering .csv files following this tutorial by JupyterLab. However, there exists a default renderer for this purpose under packages named csv-viewer-extension and my extension is not overriding the default one after installation.

I tried doing the same for .xlsx files and my extension worked because no default renderer exists for .xlsx. I even tried setting rank=0 after looking at a solved issue in JupyterLab but it didn’t work as well:

const extension: IRenderMime.IExtension = {
  id: 'jupyterlab-csv:plugin',
  rank: 0,
  dataType: 'string',

How can I override the csv default extension, if possible? Any help would be highly appreciated.
Thank You!

csv-viewer in core is not a MIME renderer, but a proper document factory. If you want to get higher priority that that you may want to create a document factory too. This is how GitHub - krassowski/jupyterlab-spreadsheet-editor: JupyterLab spreadsheet editor for tabular data (e.g. csv, tsv) can have a higher priority than the built-in csv-viewer. Alternatively, you could disable the default csv-viewer. It all depends on what your end goal is. I could help with advice if you can explain what you are trying to achieve in more detail.

My usecase lies around rendering the csv files in a different way than how it is currently being rendered (in form of a table using csv-viewer), e.g., display csv file the way a text editor does. Could you tell me how to disable the default csv-viewer and if this will allow my extension to render the csv instead?
Thank you for your time.